/* ==========================================================================
   ADMIN DARK CYBER UI THEME - PRODUCTION STYLESHEET
   Style: Dark Cyber / Cinematic Netflix, Glassmorphism, Ambient Red Glow
   Design Tokens aligned with theme-package/theme.css
   ========================================================================== */

/* 1. Design Tokens */
:root {
  /* Color Palette - Backgrounds */
  --bg-main: #060405;
  --bg-card: rgba(20, 14, 18, 0.78);
  --bg-card-hover: rgba(30, 20, 26, 0.90);
  --bg-card-solid: #120e14;
  --bg-input: rgba(0, 0, 0, 0.45);
  --bg-modal: linear-gradient(180deg, rgba(22, 14, 18, 0.98) 0%, rgba(13, 11, 15, 0.99) 100%);

  /* Color Palette - Borders */
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-hover: rgba(255, 255, 255, 0.16);
  --border-card: rgba(229, 9, 20, 0.22);
  --border-focus: #E50914;

  /* Color Palette - Netflix Brand Red */
  --primary-red: #E50914;
  --primary-red-hover: #f40612;
  --primary-red-glow: rgba(229, 9, 20, 0.45);

  /* Color Palette - Tech Accents */
  --accent-cyan: #38bdf8;
  --accent-cyan-dark: #0284c7;
  --accent-cyan-glow: rgba(56, 189, 248, 0.35);
  --accent-green: #10B981;
  --accent-green-glow: rgba(16, 185, 129, 0.35);
  --accent-purple: #c084fc;
  --accent-purple-glow: rgba(192, 132, 252, 0.3);
  --accent-amber: #f59e0b;
  --accent-rose: #f87171;

  /* Typography */
  --text-main: #FFFFFF;
  --text-muted: #8a99ad;
  --text-dim: #64748b;

  --font-main: 'Inter', 'Be Vietnam Pro', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  /* Shapes & Effects */
  --radius-xs: 4px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-pill: 9999px;

  --blur-glass: blur(16px);
  --blur-modal: blur(20px);

  /* Legacy variable mappings for backward compatibility */
  --bg: var(--bg-main);
  --bg2: var(--bg-card-solid);
  --bg3: #181216;
  --bg4: #221820;
  --surface: var(--bg-card);
  --text: var(--text-main);
  --text2: var(--text-muted);
  --text3: var(--text-dim);
  --accent: var(--primary-red);
  --accent2: var(--accent-cyan);
  --accent-soft: rgba(229, 9, 20, 0.15);
  --accent-gradient: linear-gradient(135deg, #E50914 0%, #b80710 100%);
  --green: var(--accent-green);
  --green-soft: rgba(16, 185, 129, 0.12);
  --red: var(--primary-red);
  --red-soft: rgba(229, 9, 20, 0.15);
  --orange: var(--accent-amber);
  --orange-soft: rgba(245, 158, 11, 0.12);
  --blue: var(--accent-cyan);
  --border: 1px solid var(--border-subtle);
  --border-strong: 1px solid var(--border-hover);
  --radius: var(--radius-md);
  --shadow: 0 15px 35px -5px rgba(0, 0, 0, 0.7);
  --shadow-md: 0 18px 40px -5px rgba(0, 0, 0, 0.85);
  --shadow-lg: 0 25px 60px -10px rgba(0, 0, 0, 0.9);
  --font-title: var(--font-main);
  --font-body: var(--font-main);
  --sidebar-w: 260px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* 3. Base & Ambient Glow Background */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-main);
  background-color: var(--bg-main);
  background-image:
    radial-gradient(circle at 50% 0%, rgba(229, 9, 20, 0.22) 0%, transparent 60%),
    radial-gradient(circle at 15% 50%, rgba(229, 9, 20, 0.08) 0%, transparent 45%),
    radial-gradient(circle at 85% 85%, rgba(229, 9, 20, 0.06) 0%, transparent 45%);
  background-attachment: fixed;
  color: var(--text-main);
  min-height: 100vh;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-main);
  font-weight: 700;
  color: var(--text-main);
  letter-spacing: -0.02em;
}

a {
  color: var(--accent-cyan);
  text-decoration: none;
  transition: color 0.15s ease;
}
a:hover {
  color: #7dd3fc;
  text-decoration: underline;
}

.hidden { display: none !important; }
.error { color: var(--accent-rose); margin-top: 8px; font-size: 13px; font-weight: 600; font-family: var(--font-mono); }

/* 4. Typography Helpers & Monospace Enforcement */
.font-mono,
code, kbd, pre,
.stat-card .value,
.card-num, .kpi-num, .stat-value,
.price, .amount,
.order-code,
.date-cell,
.table-id,
td:first-child,
.admin-clock,
.topbar-clock,
.badge,
input[type="date"],
input[type="number"],
.stock-area,
.cell-primary[title*="copy"],
.user-rank-stat-top b,
.user-rank-stat-percent,
.user-rank-stat-meta {
  font-family: var(--font-mono) !important;
}

.text-red { color: var(--primary-red) !important; }
.text-cyan { color: var(--accent-cyan) !important; }
.text-green { color: var(--accent-green) !important; }
.text-purple { color: var(--accent-purple) !important; }
.text-muted { color: var(--text-muted) !important; }
.text-dim { color: var(--text-dim) !important; }


/* 5. Glassmorphism Cards */
.glass-card,
.card,
.stat-card,
.kpi-panel,
.chart-section,
.settings-card,
.panel,
.products-table-card,
.user-rank-stats-block,
.table-container,
.support-page-hero {
  background: var(--bg-card);
  backdrop-filter: var(--blur-glass);
  -webkit-backdrop-filter: var(--blur-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 20px 24px;
  box-shadow: 0 15px 35px -5px rgba(0, 0, 0, 0.7);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.glass-card:hover,
.card:hover,
.stat-card:hover,
.user-rank-stats-block:hover {
  border-color: var(--border-hover);
  box-shadow: 0 18px 40px -5px rgba(0, 0, 0, 0.85);
}

.glass-card-interactive {
  cursor: pointer;
}
.glass-card-interactive:hover {
  transform: translateY(-2px);
}

.glass-card-accent,
.stat-card-accent,
.kpi-panel {
  border-top: 2px solid var(--primary-red) !important;
}

/* 6. Form Inputs & Steppers */
.admin-input,
.admin-select,
.admin-textarea,
.form-group input,
.form-group select,
.form-group textarea,
.search-box,
.stock-area,
input:not([type="checkbox"]):not([type="radio"]):not([type="submit"]):not([type="button"]) {
  width: 100%;
  height: 42px;
  padding: 0 14px;
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: #ffffff;
  font-family: var(--font-main);
  font-size: 14px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.admin-input:focus,
.admin-select:focus,
.admin-textarea:focus,
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus,
.search-box:focus,
.stock-area:focus,
input:focus {
  border-color: var(--accent-cyan) !important;
  box-shadow: 0 0 0 3px var(--accent-cyan-glow) !important;
  background: rgba(0, 0, 0, 0.65) !important;
}

.admin-input::placeholder,
.form-group input::placeholder,
.form-group textarea::placeholder,
.search-box::placeholder {
  color: #555f6d;
}

.admin-textarea,
.form-group textarea,
.stock-area {
  height: auto;
  min-height: 90px;
  padding: 12px 14px;
  resize: vertical;
}

input[type="date"],
input[type="datetime-local"] {
  color-scheme: dark;
  cursor: pointer;
  font-family: var(--font-mono) !important;
}

select option,
.form-group select option {
  background: #120e14;
  color: #ffffff;
}

.form-group {
  margin-bottom: 16px;
}
.form-group label {
  display: block;
  font-size: 12.5px;
  color: var(--text-muted);
  font-weight: 600;
  margin-bottom: 6px;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}


/* 7. Buttons & Action Chips */
.btn,
.btn-primary,
.btn-submit,
.btn-login-submit,
.btn-secondary,
.btn-outline,
.btn-cyan {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 9px 18px;
  font-size: 13.5px;
  font-weight: 700;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.05);
  color: #cbd5e1;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  user-select: none;
  line-height: 1.2;
  white-space: nowrap;
  box-sizing: border-box;
}

.btn:active,
.btn-primary:active {
  transform: scale(0.98);
}

.btn svg,
.btn i,
.btn [data-lucide],
.btn-primary svg,
.btn-primary i,
.btn-primary [data-lucide],
.btn-outline svg,
.btn-outline i,
.btn-outline [data-lucide] {
  width: 15px;
  height: 15px;
  flex-shrink: 0;
  display: inline-block;
  vertical-align: middle;
}

.btn-primary,
.btn-submit,
.btn-login-submit {
  background: linear-gradient(135deg, #E50914 0%, #b80710 100%) !important;
  color: #FFFFFF !important;
  border-color: rgba(229, 9, 20, 0.4) !important;
  box-shadow: 0 4px 16px var(--primary-red-glow) !important;
}

.btn-primary:hover,
.btn-submit:hover,
.btn-login-submit:hover {
  background: linear-gradient(135deg, #f40612 0%, #c90812 100%) !important;
  box-shadow: 0 6px 22px rgba(229, 9, 20, 0.6) !important;
  transform: translateY(-1px);
}

.btn-cyan,
.btn-info {
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%) !important;
  color: #FFFFFF !important;
  border-color: rgba(56, 189, 248, 0.4) !important;
  box-shadow: 0 4px 14px rgba(2, 132, 199, 0.35) !important;
}

.btn-cyan:hover,
.btn-info:hover {
  background: linear-gradient(135deg, #0369a1 0%, #075985 100%) !important;
  box-shadow: 0 6px 20px rgba(2, 132, 199, 0.5) !important;
  transform: translateY(-1px);
}

.btn-secondary,
.btn-outline {
  background: rgba(255, 255, 255, 0.05) !important;
  border-color: rgba(255, 255, 255, 0.12) !important;
  color: #cbd5e1 !important;
}

.btn-secondary:hover,
.btn-outline:hover {
  background: rgba(255, 255, 255, 0.1) !important;
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.22) !important;
}

.btn-danger {
  background: linear-gradient(135deg, #dc2626 0%, #991b1b 100%) !important;
  color: #FFFFFF !important;
  border-color: rgba(239, 68, 68, 0.4) !important;
  box-shadow: 0 4px 14px rgba(220, 38, 38, 0.35) !important;
}

.btn-danger:hover {
  background: linear-gradient(135deg, #ef4444 0%, #b91c1c 100%) !important;
  box-shadow: 0 6px 20px rgba(220, 38, 38, 0.5) !important;
  transform: translateY(-1px);
}

.btn-success {
  background: linear-gradient(135deg, #059669 0%, #047857 100%) !important;
  color: #FFFFFF !important;
  border-color: rgba(16, 185, 129, 0.4) !important;
  box-shadow: 0 4px 14px rgba(5, 150, 105, 0.35) !important;
}

.btn-success:hover {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
  box-shadow: 0 6px 20px rgba(16, 185, 129, 0.5) !important;
  transform: translateY(-1px);
}

.btn-sm {
  padding: 6px 12px;
  font-size: 12px;
}
.btn-sm svg,
.btn-sm i,
.btn-sm [data-lucide] {
  width: 13px;
  height: 13px;
  flex-shrink: 0;
}

.btn-xs {
  padding: 3px 8px;
  font-size: 11.5px;
  font-weight: 600;
  border-radius: var(--radius-xs);
  gap: 4px;
  line-height: 1.2;
}
.btn-xs svg,
.btn-xs i,
.btn-xs [data-lucide] {
  width: 11px;
  height: 11px;
  flex-shrink: 0;
}

.btn-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.btn-chip {
  padding: 4px 8px;
  font-size: 11px;
  font-weight: 700;
  border-radius: 6px;
}

.btn-chip-red {
  color: var(--accent-rose) !important;
  border-color: rgba(239, 68, 68, 0.22) !important;
  background: rgba(239, 68, 68, 0.06) !important;
}
.btn-chip-red:hover {
  background: rgba(239, 68, 68, 0.15) !important;
  border-color: rgba(239, 68, 68, 0.4) !important;
}

.btn-chip-green {
  color: #34d399 !important;
  border-color: rgba(16, 185, 129, 0.22) !important;
  background: rgba(16, 185, 129, 0.06) !important;
}
.btn-chip-green:hover {
  background: rgba(16, 185, 129, 0.15) !important;
  border-color: rgba(16, 185, 129, 0.4) !important;
}

/* 8. Status Badges & Pills */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 9px;
  border-radius: var(--radius-pill);
  font-family: var(--font-mono) !important;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
}

.badge svg,
.badge i,
.badge [data-lucide] {
  width: 12px;
  height: 12px;
  flex-shrink: 0;
}

.badge-green, .badge-active, .badge-success {
  background: rgba(16, 185, 129, 0.12) !important;
  color: var(--accent-green) !important;
  border: 1px solid rgba(16, 185, 129, 0.3) !important;
}

.badge-cyan, .badge-ready, .badge-info, .badge-accent, .badge-blue {
  background: rgba(56, 189, 248, 0.12) !important;
  color: var(--accent-cyan) !important;
  border: 1px solid rgba(56, 189, 248, 0.3) !important;
}

.badge-red, .badge-expired, .badge-danger {
  background: rgba(239, 68, 68, 0.12) !important;
  color: #f87171 !important;
  border: 1px solid rgba(239, 68, 68, 0.3) !important;
}

.badge-purple, .badge-lifetime {
  background: rgba(192, 132, 252, 0.12) !important;
  color: var(--accent-purple) !important;
  border: 1px solid rgba(192, 132, 252, 0.3) !important;
}

.badge-orange, .badge-warning {
  background: rgba(245, 158, 11, 0.12) !important;
  color: var(--accent-amber) !important;
  border: 1px solid rgba(245, 158, 11, 0.3) !important;
}

.badge-gray {
  background: rgba(148, 163, 184, 0.12) !important;
  color: var(--text-muted) !important;
  border: 1px solid rgba(148, 163, 184, 0.2) !important;
}

.dot-online {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #10B981;
  box-shadow: 0 0 8px #10B981;
  display: inline-block;
  animation: pulseGreen 1.8s infinite;
}

@keyframes pulseGreen {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.6; transform: scale(0.85); }
}


/* 9. Glass Table */
.glass-table-wrap,
.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  background: var(--bg-card);
  backdrop-filter: var(--blur-glass);
  -webkit-backdrop-filter: var(--blur-glass);
  box-shadow: 0 15px 35px -5px rgba(0, 0, 0, 0.7);
}

.glass-table,
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  text-align: left;
}

.glass-table thead tr,
table thead tr {
  background: rgba(0, 0, 0, 0.45);
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-muted);
  font-family: var(--font-mono) !important;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.glass-table th, .glass-table td,
table th, table td {
  padding: 13px 18px;
  vertical-align: middle;
}

.glass-table tbody tr,
table tbody tr {
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  transition: background 0.15s ease;
}

.glass-table tbody tr:hover,
table tbody tr:hover {
  background: rgba(255, 255, 255, 0.03);
}

.cell-primary {
  font-weight: 700;
  color: #fff;
  font-family: var(--font-mono);
}
.cell-secondary {
  font-size: 11.5px;
  color: var(--text-muted);
  margin-top: 2px;
}

/* 10. Modal Dialog */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(4, 4, 7, 0.85);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 99999;
  padding: 16px;
  animation: modalFadeIn 0.15s ease-out;
  will-change: opacity;
}

.modal,
.modal-dialog {
  background: var(--bg-modal);
  border: 1px solid var(--border-subtle);
  border-top: 2px solid var(--primary-red) !important;
  border-radius: var(--radius-lg);
  padding: 24px;
  width: 100%;
  max-width: 520px;
  box-shadow: 0 25px 60px -10px rgba(0, 0, 0, 0.9), 0 0 35px rgba(229, 9, 20, 0.15);
  animation: modalSlideUp 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  max-height: 92vh;
  overflow-y: auto;
  transform: translateZ(0);
  will-change: transform, opacity;
}

.modal.modal-wide,
.modal-dialog.modal-wide {
  width: min(880px, 95vw) !important;
  max-width: 880px !important;
}

.modal.modal-landscape,
.modal-dialog.modal-landscape {
  width: min(1120px, 95vw) !important;
  max-width: 1120px !important;
  max-height: 90vh;
}

/* User History Modals (Horizontal Landscape View) */
.user-history-modal {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.user-history-stats-bar {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

@media (max-width: 640px) {
  .user-history-stats-bar {
    grid-template-columns: 1fr;
  }
}

.user-history-stat-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 10px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.user-history-stat-card:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.15);
}

.user-history-stat-icon {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  flex-shrink: 0;
}

.user-history-stat-icon.icon-green {
  background: rgba(34, 197, 94, 0.12);
  color: #22c55e;
}

.user-history-stat-icon.icon-red {
  background: rgba(239, 68, 68, 0.12);
  color: #ef4444;
}

.user-history-stat-icon.icon-accent {
  background: rgba(229, 9, 20, 0.12);
  color: var(--primary-red);
}

.user-history-stat-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.user-history-stat-label {
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: 0.5px;
}

.user-history-stat-val {
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  font-family: var(--font-mono);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.user-history-table-container {
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  background: rgba(0, 0, 0, 0.28);
  overflow-x: auto;
  max-height: 54vh;
  overflow-y: auto;
}

.user-history-table-container table {
  margin: 0;
  width: 100%;
  border-collapse: collapse;
}

.user-history-table-container thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: #10131c;
  box-shadow: 0 1px 0 var(--border-subtle);
}

.user-history-table-container table th,
.user-history-table-container table td {
  padding: 10px 14px;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border-subtle);
}

.modal-header h3 {
  font-size: 17px;
  font-weight: 700;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 8px;
}

.modal-close {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  color: var(--text-muted);
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 18px;
  transition: all 0.2s ease;
}

.modal-close:hover {
  background: rgba(229, 9, 20, 0.2);
  color: #fff;
  border-color: var(--primary-red);
}

.modal-body {
  overflow-y: auto;
}
.modal-body .btn { margin-top: 8px; }

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

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

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

.app-spinner {
  width: 28px;
  height: 28px;
  border: 3px solid rgba(255, 255, 255, 0.12);
  border-top-color: var(--accent-cyan);
  border-radius: 50%;
  animation: app-spin 0.6s linear infinite;
  display: inline-block;
}

.modal-loading-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 44px 20px;
  gap: 14px;
  color: var(--text-muted);
}
.modal-loading-state span {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-main, #fff);
}

/* 11. Custom Dark Scrollbar */
::-webkit-scrollbar {
  width: 7px;
  height: 7px;
}
::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.2);
}
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.15);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--primary-red);
}


/* 12. Login Screen */
.login-screen {
  display: flex;
  min-height: 100vh;
  width: 100%;
  background: var(--bg-main);
  overflow: hidden;
}

.login-left {
  width: 44%;
  position: relative;
  background:
    linear-gradient(160deg, rgba(229, 9, 20, 0.3) 0%, rgba(18, 14, 18, 0.9) 50%, #060405 100%),
    url('/login_banner.png') center/cover no-repeat;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 48px;
  z-index: 1;
}

.login-left-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(6, 4, 5, 0.95) 0%, rgba(6, 4, 5, 0.4) 60%, rgba(6, 4, 5, 0.2) 100%);
  z-index: -1;
}

.login-left-logo {
  display: flex;
  align-items: center;
  gap: 10px;
}

.login-left-quote {
  max-width: 460px;
}

.quote-text {
  font-size: 21px;
  line-height: 1.45;
  font-weight: 700;
  margin-bottom: 16px;
  color: #fff;
  letter-spacing: -0.02em;
}

.quote-author {
  font-weight: 800;
  font-size: 14px;
  margin-bottom: 2px;
}

.quote-title {
  font-size: 12.5px;
}

.login-right {
  width: 56%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 24px;
}

.login-form-container {
  width: 100%;
  max-width: 420px;
}

.form-logo-box {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  background: rgba(229, 9, 20, 0.12);
  border: 1px solid rgba(229, 9, 20, 0.3);
  border-radius: var(--radius-md);
  margin-bottom: 18px;
  box-shadow: 0 0 24px var(--primary-red-glow);
}

.login-form-header h2 {
  font-size: 26px;
  font-weight: 800;
  margin-bottom: 6px;
}

.login-remember-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
}

.switch {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
}
.switch input { opacity: 0; width: 0; height: 0; }
.slider {
  position: absolute; cursor: pointer; inset: 0;
  background: rgba(255, 255, 255, 0.08);
  transition: .25s; border: 1px solid var(--border-subtle);
}
.slider:before {
  position: absolute; content: "";
  height: 16px; width: 16px; left: 3px; bottom: 3px;
  background: #fff; transition: .25s;
  border-radius: 50%;
  box-shadow: 0 1px 3px rgba(0,0,0,0.35);
}
input:checked + .slider { background: var(--primary-red); border-color: var(--primary-red); box-shadow: 0 0 10px var(--primary-red-glow); }
input:checked + .slider:before { transform: translateX(20px); }
.slider.round { border-radius: 24px; }
.slider.round:before { border-radius: 50%; }

/* 13. Application Layout */
.app {
  display: flex;
  min-height: 100vh;
  padding-top: 56px;
}

/* Desktop Viewport Rules (> 768px): Hide mobile-only elements */
@media (min-width: 769px) {
  .mobile-header,
  .sidebar-overlay,
  .sidebar-close,
  .sidebar-close-btn {
    display: none !important;
  }
}

.sidebar {
  width: var(--sidebar-w);
  background: rgba(14, 10, 13, 0.88);
  backdrop-filter: var(--blur-glass);
  -webkit-backdrop-filter: var(--blur-glass);
  border-right: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  height: 100vh;
  z-index: 40;
  transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1);
  box-shadow: 10px 0 35px rgba(0, 0, 0, 0.5);
}

.sidebar-header {
  padding: 16px 18px;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: flex-start;
}

.sidebar-header h2 {
  font-size: 17px;
  font-weight: 800;
  letter-spacing: 0.5px;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
}

.brand-title {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 800;
  letter-spacing: 0.6px;
}

.sidebar-operator {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 12px 10px;
  padding: 10px 12px;
}

.operator-avatar {
  width: 34px;
  height: 34px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, var(--primary-red) 0%, #800000 100%);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 13px;
  box-shadow: 0 0 12px var(--primary-red-glow);
}

.operator-copy strong {
  display: block;
  font-size: 13px;
  color: #fff;
  font-weight: 700;
}

.operator-more {
  margin-left: auto;
  background: transparent;
  border: none;
  color: var(--text-dim);
  cursor: pointer;
}

.nav-menu {
  list-style: none;
  padding: 10px 10px 20px;
  flex: 1;
  overflow-y: auto;
}

.nav-section {
  padding: 14px 12px 6px;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  color: var(--text-dim);
  font-weight: 800;
  font-family: var(--font-mono);
}

.nav-menu li {
  padding: 9px 12px;
  cursor: pointer;
  color: var(--text-muted);
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 10px;
  border-radius: var(--radius-xs);
  margin-bottom: 2px;
  transition: all 0.18s ease;
  font-weight: 600;
  user-select: none;
}

.nav-menu li svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  opacity: 0.85;
}

.nav-menu li:hover {
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
}

.nav-menu li.active {
  background: linear-gradient(90deg, rgba(229, 9, 20, 0.18) 0%, rgba(229, 9, 20, 0.04) 100%);
  color: #ffffff;
  border-left: 3px solid var(--primary-red);
  font-weight: 700;
  box-shadow: 0 0 20px rgba(229, 9, 20, 0.15);
}

.nav-menu li.active svg {
  opacity: 1;
  color: var(--primary-red);
}

.sidebar-footer {
  padding: 14px 16px;
  border-top: 1px solid var(--border-subtle);
}

.btn-logout {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}
.btn-logout:hover {
  background: rgba(239, 68, 68, 0.18) !important;
  color: var(--accent-rose) !important;
  border-color: rgba(239, 68, 68, 0.4) !important;
}


/* 14. Desktop Topbar */
.desktop-topbar {
  position: fixed;
  top: 0;
  left: var(--sidebar-w);
  right: 0;
  height: 56px;
  background: rgba(14, 10, 13, 0.85);
  backdrop-filter: var(--blur-glass);
  -webkit-backdrop-filter: var(--blur-glass);
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
  z-index: 30;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}

.topbar-context {
  display: flex;
  align-items: center;
  gap: 12px;
}

.topbar-separator {
  width: 1px;
  height: 16px;
  background: var(--border-subtle);
}

.topbar-clock {
  font-size: 12.5px;
  font-weight: 700;
}

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

.topbar-icon {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  position: relative;
  transition: all 0.2s ease;
}

.topbar-icon:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  border-color: var(--border-hover);
}

.notification-dot {
  position: absolute;
  top: 7px;
  right: 7px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--primary-red);
  box-shadow: 0 0 8px var(--primary-red);
}

.admin-profile {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-left: 14px;
  border-left: 1px solid var(--border-subtle);
}

.admin-avatar {
  width: 34px;
  height: 34px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, #22151e 0%, #120e14 100%);
  border: 1px solid rgba(229, 9, 20, 0.4);
  color: var(--primary-red);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 12px;
  box-shadow: 0 0 10px rgba(229, 9, 20, 0.2);
}

.admin-profile-copy strong {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
}
.admin-profile-copy span {
  font-size: 11px;
}

/* 15. Content & Command Strip */
.content {
  flex: 1;
  margin-left: var(--sidebar-w);
  padding: 24px 28px 48px;
  min-height: calc(100vh - 56px);
  max-width: 1680px;
  width: calc(100% - var(--sidebar-w));
}

.command-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 24px;
}

.command-card {
  padding: 14px 16px;
  display: grid;
  grid-template-columns: 38px 1fr 16px;
  align-items: center;
  gap: 12px;
  color: #fff;
  border-radius: var(--radius-md);
  text-align: left;
  background: var(--bg-card);
  backdrop-filter: var(--blur-glass);
  -webkit-backdrop-filter: var(--blur-glass);
  border: 1px solid var(--border-subtle);
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.6);
  cursor: pointer;
  transition: all 0.22s cubic-bezier(0.4, 0, 0.2, 1);
}

.command-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-hover);
  transform: translateY(-2px);
  box-shadow: 0 14px 30px -5px rgba(0, 0, 0, 0.85);
}

/* UNIFIED COMMAND ICON - Dark Cyber styling across all cards */
.command-icon {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  color: #fff;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.command-card:hover .command-icon {
  background: rgba(229, 9, 20, 0.16);
  border-color: rgba(229, 9, 20, 0.4);
  color: var(--primary-red);
  box-shadow: 0 0 14px var(--primary-red-glow);
}

.command-card svg {
  transition: transform 0.2s ease, color 0.2s ease;
}

.command-card:hover svg:last-child {
  transform: translateX(3px);
  color: var(--primary-red);
}

.command-card strong {
  display: block;
  font-size: 13.5px;
  font-weight: 700;
  color: #fff;
}

.command-card small {
  font-size: 11.5px;
  color: var(--text-muted);
}


/* 16. Dashboard Layout & KPIs */
.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
  flex-wrap: wrap;
}

.page-header h2 {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.page-header .page-sub {
  display: block;
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 400;
  margin-top: 4px;
  letter-spacing: 0;
}

.dashboard-overview-grid {
  display: grid;
  grid-template-columns: 1.65fr 1fr;
  gap: 18px;
  margin-bottom: 22px;
}

.panel-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.panel-heading h3 {
  font-size: 15px;
  font-weight: 700;
}

.eyebrow {
  display: block;
  font-size: 10px;
  text-transform: uppercase;
  font-family: var(--font-mono);
  font-weight: 800;
  color: var(--text-dim);
  letter-spacing: 1px;
}

.live-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 8px;
  border-radius: var(--radius-pill);
  font-size: 10.5px;
  font-weight: 800;
  font-family: var(--font-mono);
  color: var(--accent-green);
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.3);
}
.live-pill i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-green);
  box-shadow: 0 0 6px var(--accent-green);
}

.panel-link {
  background: none;
  border: none;
  color: var(--accent-cyan);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}
.panel-link:hover {
  text-decoration: underline;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}

.stat-card {
  position: relative;
  overflow: hidden;
}

.stat-card .label {
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-muted);
  letter-spacing: 0.5px;
  margin-bottom: 8px;
}

.stat-card .value {
  font-size: 26px;
  font-weight: 800;
  line-height: 1.2;
}

.stat-card.green .value { color: var(--accent-green) !important; }
.stat-card.accent .value { color: var(--accent-cyan) !important; }
.stat-card.orange .value { color: var(--accent-amber) !important; }
.stat-card.purple .value { color: var(--accent-purple) !important; }
.stat-card.red .value { color: var(--primary-red) !important; }

.stat-card .sub {
  margin-top: 6px;
  font-size: 12px;
  color: var(--text-dim);
}

.sparkline-container {
  position: absolute;
  right: 12px;
  bottom: 10px;
  width: 76px;
  height: 26px;
  opacity: 0.45;
  pointer-events: none;
}
.sparkline-svg { width: 100%; height: 100%; }

/* Chart Bars */
.chart-bars {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 10px;
  height: 160px;
  padding-top: 20px;
}
.chart-bar {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  height: 100%;
  justify-content: flex-end;
  gap: 6px;
}
.chart-bar .bar {
  width: 100%;
  max-width: 38px;
  border-radius: 6px 6px 4px 4px;
  background: linear-gradient(180deg, var(--primary-red) 0%, #75050c 100%);
  box-shadow: 0 4px 14px var(--primary-red-glow);
  min-height: 4px;
  transition: height 0.4s var(--ease);
}
.chart-bar:hover .bar {
  background: linear-gradient(180deg, #f40612 0%, var(--primary-red) 100%);
  box-shadow: 0 6px 20px rgba(229, 9, 20, 0.7);
}
.chart-bar .bar-label {
  font-size: 10px;
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-weight: 600;
}
.chart-bar .bar-value {
  font-size: 10px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-weight: 700;
  white-space: nowrap;
}

/* Dashboard Lower Grid */
.dashboard-lower-grid {
  display: grid;
  grid-template-columns: 1.65fr 1fr;
  gap: 18px;
}
.dashboard-main-col, .dashboard-side-col { min-width: 0; }
.dashboard-side-col { display: flex; flex-direction: column; gap: 18px; }

/* Warnings */
.warning-container {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.warning-card {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 13px 15px;
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
}
.warning-card.warn {
  border-color: rgba(245, 158, 11, 0.35);
  background: rgba(245, 158, 11, 0.08);
}
.warning-card.danger {
  border-color: rgba(239, 68, 68, 0.35);
  background: rgba(239, 68, 68, 0.08);
}
.warning-card.success {
  border-color: rgba(16, 185, 129, 0.35);
  background: rgba(16, 185, 129, 0.08);
}
.warning-icon { width: 18px; height: 18px; flex-shrink: 0; margin-top: 2px; }
.warning-card.warn .warning-icon { color: var(--accent-amber); }
.warning-card.danger .warning-icon { color: var(--primary-red); }
.warning-card.success .warning-icon { color: var(--accent-green); }
.warning-title { font-weight: 700; font-size: 13.5px; margin-bottom: 2px; }
.warning-desc { font-size: 12px; color: var(--text-muted); line-height: 1.4; }


/* 17. User Rank Statistics */
.user-rank-stats-block {
  margin: 0 0 22px;
}
.user-rank-stats-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}
.user-rank-stats-head b {
  font-size: 15px;
  font-weight: 800;
  color: #fff;
}
.user-rank-stats-head span {
  font-size: 12px;
  color: var(--text-muted);
}
.user-rank-stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(175px, 1fr));
  gap: 12px;
}
.user-rank-stat {
  padding: 14px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  background: rgba(0, 0, 0, 0.4);
  color: #fff;
  cursor: pointer;
  text-align: left;
  transition: all 0.2s ease;
}
.user-rank-stat:hover {
  border-color: var(--accent-cyan);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px var(--accent-cyan-glow);
}
.user-rank-stat.is-active {
  border-color: var(--accent-cyan);
  background: rgba(56, 189, 248, 0.08);
  box-shadow: 0 0 0 2px var(--accent-cyan-glow);
}
.user-rank-stat-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}
.user-rank-stat-top span {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
}
.user-rank-stat-top b {
  font-size: 22px;
  color: var(--accent-cyan);
}
.user-rank-stat-percent {
  margin: 4px 0 8px;
  font-size: 11px;
  color: var(--text-dim);
}
.user-rank-progress {
  height: 5px;
  overflow: hidden;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.08);
}
.user-rank-progress i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--accent-cyan), var(--primary-red));
}
.user-rank-stat-meta {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-top: 10px;
  color: var(--text-dim);
  font-size: 10.5px;
}

/* 18. Rank Management Matrix */
#page-ranks { --rank-blue: var(--accent-cyan); }
.rank-page-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.rank-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(190px, 1fr));
  gap: 14px;
  margin-bottom: 20px;
}
.rank-summary-card {
  position: relative;
  overflow: hidden;
  padding: 18px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  background: var(--bg-card);
  backdrop-filter: var(--blur-glass);
  -webkit-backdrop-filter: var(--blur-glass);
}
.rank-summary-card::before {
  content: '';
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: var(--primary-red);
}
.rank-summary-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4px;
}
.rank-summary-top .label {
  font-size: 14px;
  font-weight: 700;
  color: #fff;
}
.rank-level {
  font-family: var(--font-mono) !important;
  font-size: 11px;
  font-weight: 700;
  color: var(--accent-cyan);
  background: rgba(56, 189, 248, 0.12);
  border: 1px solid rgba(56, 189, 248, 0.3);
  padding: 2px 7px;
  border-radius: var(--radius-xs);
}
.rank-summary-card .value {
  font-size: 22px;
  font-weight: 800;
  color: #fff;
  margin: 6px 0 2px;
}
.rank-summary-card .sub {
  font-size: 12px;
  color: var(--text-dim);
  margin-bottom: 12px;
}
.rank-summary-card.is-disabled {
  opacity: 0.55;
  filter: grayscale(0.5);
}
.rank-summary-card .btn {
  width: 100%;
  height: 34px;
  justify-content: center;
  font-size: 12.5px;
  font-weight: 600;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #cbd5e1;
  transition: all 0.2s ease;
}
.rank-summary-card .btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.25);
  color: #ffffff;
}
.rank-filter-bar {
  display: grid;
  grid-template-columns: minmax(210px, 1.5fr) repeat(3, minmax(145px, .65fr)) auto auto;
  gap: 10px;
  align-items: center;
  margin-bottom: 18px;
  padding: 14px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  background: var(--bg-card);
}
.rank-filter-bar select {
  height: 38px;
  padding: 0 12px;
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: #ffffff;
  font-family: var(--font-main);
  font-size: 13px;
  outline: none;
  cursor: pointer;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.rank-filter-bar select:focus {
  border-color: rgba(229, 9, 20, 0.6);
  box-shadow: 0 0 0 2px rgba(229, 9, 20, 0.15);
}
.rank-filter-bar select option {
  background: #18181b;
  color: #ffffff;
}
.rank-filter-bar input {
  height: 38px;
  font-size: 13px;
}
.rank-filter-bar .btn {
  height: 38px;
  padding: 0 14px;
  font-size: 13px;
  gap: 6px;
  white-space: nowrap;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.06);
  color: #cbd5e1;
  border-radius: var(--radius-sm);
}
.rank-filter-bar .btn:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.28);
  color: #ffffff;
}
.rank-page-actions .btn {
  height: 40px;
  padding: 0 18px;
  font-size: 13.5px;
  gap: 8px;
}
.rank-search {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
}
.rank-search .search-icon {
  position: absolute;
  left: 12px;
  width: 16px;
  height: 16px;
  color: var(--text-dim);
  pointer-events: none;
}
.rank-search input {
  padding-left: 36px !important;
}
.rank-filter-count {
  font-family: var(--font-mono) !important;
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 600;
  white-space: nowrap;
}
.rank-category {
  overflow: hidden;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  background: var(--bg-card);
  margin-bottom: 14px;
}
.rank-category-head {
  display: flex;
  width: 100%;
  justify-content: space-between;
  align-items: center;
  padding: 14px 18px;
  background: rgba(0, 0, 0, 0.4);
  border: none;
  border-bottom: 1px solid var(--border-subtle);
  color: #fff;
  cursor: pointer;
  text-align: left;
}
.rank-category-head b {
  display: inline-flex;
  align-items: center;
  font-size: 14px;
}
.rank-category-head small {
  font-size: 12px;
  color: var(--text-dim);
  font-weight: 400;
  margin-left: 10px;
}
.rank-category-chevron {
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease;
}
.rank-category-chevron svg {
  width: 16px;
  height: 16px;
  color: var(--text-dim);
}
.rank-category.is-collapsed .rank-category-body {
  display: none;
}
.rank-category.is-collapsed .rank-category-chevron {
  transform: rotate(-90deg);
}
.rank-price-table {
  width: 100%;
  border-collapse: collapse;
}
.rank-price-table th {
  background: rgba(0, 0, 0, 0.5);
  color: var(--text-muted);
  padding: 12px 14px;
  font-family: var(--font-mono);
  font-size: 11px;
}
.rank-price-table td {
  padding: 12px 14px;
  border-top: 1px solid var(--border-subtle);
  vertical-align: middle;
}
.rank-price-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 6px;
  cursor: pointer;
  user-select: none;
}
.rank-price-toggle input {
  width: 14px !important;
  height: 14px !important;
  cursor: pointer;
}
.rank-price-cell.is-enabled {
  background: rgba(229, 9, 20, 0.03);
}
.rank-price-input-wrap {
  display: flex;
  align-items: center;
  width: 155px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xs);
  background: var(--bg-input);
}
.rank-price-input-wrap input {
  width: 100%;
  padding: 6px 8px;
  background: transparent;
  border: none;
  color: #fff;
  font-family: var(--font-mono) !important;
  font-weight: 700;
  outline: none;
  height: 32px !important;
}
.rank-price-input-wrap span {
  padding-right: 8px;
  color: var(--text-dim);
  font-size: 11px;
  font-family: var(--font-mono) !important;
}
.rank-filter-hidden,
.rank-column-hidden {
  display: none !important;
}
.is-rank-disabled {
  opacity: 0.4;
  pointer-events: none;
}

/* 20. Support Requests */
.support-page-hero {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 22px;
  flex-wrap: wrap;
}
.support-page-hero h2 {
  font-size: 24px;
  font-weight: 800;
  margin: 4px 0 6px;
}
.support-page-hero p {
  font-size: 13px;
  color: var(--text-muted);
}
.support-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 24px;
}
.support-metric {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  background: var(--bg-card);
  backdrop-filter: var(--blur-glass);
  -webkit-backdrop-filter: var(--blur-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.6);
  cursor: pointer;
  text-align: left;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  user-select: none;
  color: #fff;
  width: 100%;
}
.support-metric:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-hover);
  transform: translateY(-2px);
  box-shadow: 0 14px 30px -5px rgba(0, 0, 0, 0.8);
}
.support-metric.selected {
  border-color: var(--primary-red);
  background: linear-gradient(135deg, rgba(229, 9, 20, 0.12) 0%, rgba(20, 14, 18, 0.85) 100%);
  box-shadow: 0 0 0 1px var(--primary-red), 0 10px 28px -4px var(--primary-red-glow);
}
.support-metric .metric-body {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
  flex: 1;
}
.support-metric small {
  display: block;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: var(--text-muted);
}
.support-metric strong {
  display: block;
  font-family: var(--font-mono) !important;
  font-size: 22px;
  font-weight: 800;
  line-height: 1.15;
  color: #fff;
}
.support-filter-bar {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 16px;
  flex-wrap: wrap;
  gap: 12px;
}
.support-filter-bar h3 {
  font-size: 16px;
  font-weight: 700;
  color: #fff;
}
.support-filter-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.support-order-card {
  padding: 10px 12px;
  background: rgba(16, 185, 129, 0.06);
  border: 1px solid rgba(16, 185, 129, 0.2);
  border-left: 3px solid var(--accent-green);
  border-radius: var(--radius-xs);
  margin-top: 8px;
}
.support-order-missing {
  padding: 8px 10px;
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.25);
  border-left: 3px solid var(--accent-rose);
  border-radius: var(--radius-xs);
  font-size: 12px;
  color: var(--accent-rose);
  margin-top: 6px;
}
.support-admin-reply {
  padding: 10px 12px;
  background: rgba(56, 189, 248, 0.06);
  border: 1px solid rgba(56, 189, 248, 0.2);
  border-left: 3px solid var(--accent-cyan);
  border-radius: var(--radius-xs);
  margin-top: 8px;
}
.support-reply-modal {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.support-reply-intro {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background: rgba(56, 189, 248, 0.08);
  border: 1px solid rgba(56, 189, 248, 0.25);
  border-radius: var(--radius-sm);
}
.support-reply-intro span {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-xs);
  background: rgba(56, 189, 248, 0.15);
  color: var(--accent-cyan);
  flex-shrink: 0;
}
.support-reply-intro h4 {
  font-size: 14px;
  font-weight: 700;
  color: #fff;
}
.support-reply-intro p {
  font-size: 12px;
  color: var(--text-muted);
}
.support-reply-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 8px;
}


/* 21. Warranty Account Selector Modal */
.wr-modal-grid {
  display: grid;
  grid-template-columns: 1fr 1.25fr;
  gap: 20px;
  align-items: start;
}
.wr-modal-col {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
}
.wr-modal-panel {
  padding: 14px 16px;
  background: var(--bg-card);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-subtle);
  line-height: 1.7;
  font-size: 13.5px;
}
.wr-modal-footer {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  align-items: center;
  margin-top: 10px;
  padding-top: 14px;
  border-top: 1px solid var(--border-subtle);
  grid-column: 1 / -1;
}
.wr-accounts-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: 320px;
  overflow-y: auto;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 10px;
  background: rgba(0, 0, 0, 0.4);
}
.wr-account-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-left: 4px solid transparent;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
}
.wr-account-item:hover {
  border-color: var(--accent-cyan);
  transform: translateY(-1px);
}
.wr-account-item.is-selected,
.wr-account-item:has(.wr-account-check:checked) {
  background: rgba(56, 189, 248, 0.08);
  border-color: var(--accent-cyan);
  border-left: 4px solid var(--accent-cyan);
  box-shadow: 0 4px 16px var(--accent-cyan-glow);
}
.wr-account-code {
  display: block;
  font-family: var(--font-mono) !important;
  font-size: 12.5px;
  color: #fff;
  word-break: break-all;
  white-space: pre-wrap;
  background: rgba(0, 0, 0, 0.5);
  padding: 8px 12px;
  border-radius: var(--radius-xs);
  border: 1px solid var(--border-subtle);
  line-height: 1.5;
}
.wr-source-option {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  cursor: pointer;
  transition: all 0.2s ease;
}
.wr-source-option:hover {
  border-color: var(--accent-cyan);
}
.wr-source-option.is-active {
  border-color: var(--accent-cyan);
  background: rgba(56, 189, 248, 0.08);
}
.wr-info-box {
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 1px dashed rgba(56, 189, 248, 0.35);
  background: rgba(56, 189, 248, 0.06);
  font-size: 12px;
  line-height: 1.55;
  color: var(--text-muted);
}
.wr-info-box b { color: #fff; }

/* 22. Multi-Select Product Dropdown */
.multi-select-dropdown {
  position: relative;
  display: inline-block;
  min-width: 220px;
}
.multi-select-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 12px;
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: #fff;
  font-size: 13px;
  cursor: pointer;
  user-select: none;
  transition: all 0.2s ease;
  min-height: 36px;
  box-sizing: border-box;
}
.multi-select-toggle:hover {
  border-color: var(--border-hover);
  background: rgba(255, 255, 255, 0.05);
}
.multi-select-dropdown.open .multi-select-toggle {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 3px var(--accent-cyan-glow);
}
.multi-select-toggle-text {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1;
  text-align: left;
}
.multi-select-menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  z-index: 1050;
  width: 330px;
  max-width: min(400px, 92vw);
  background: var(--bg-modal, #120e11);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.75), 0 0 1px rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  display: none;
  flex-direction: column;
  padding: 10px;
  gap: 8px;
  box-sizing: border-box;
  overflow: hidden;
}
.multi-select-dropdown.open .multi-select-menu {
  display: flex;
}
.multi-select-search {
  width: 100%;
  padding: 7px 10px;
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xs);
  color: #fff;
  font-size: 12.5px;
  outline: none;
  box-sizing: border-box;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.multi-select-search:focus {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 2px var(--accent-cyan-glow);
}
.multi-select-search::placeholder {
  color: var(--text-dim, #71717a);
}
.multi-select-actions {
  display: flex;
  gap: 6px;
  align-items: center;
}
.multi-select-btn {
  flex: 1;
  padding: 5px 8px;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text-muted, #94a3b8);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xs);
  cursor: pointer;
  text-align: center;
  white-space: nowrap;
  transition: all 0.15s ease;
  user-select: none;
}
.multi-select-btn:hover {
  background: rgba(0, 242, 254, 0.12);
  border-color: var(--accent-cyan);
  color: #fff;
}
.multi-select-btn:active {
  transform: translateY(1px);
}
.multi-select-options {
  flex: 1;
  max-height: 260px;
  overflow-y: auto;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-right: 4px;
}
.multi-select-options::-webkit-scrollbar {
  width: 5px;
}
.multi-select-options::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.2);
  border-radius: 4px;
}
.multi-select-options::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.15);
  border-radius: 4px;
}
.multi-select-options::-webkit-scrollbar-thumb:hover {
  background: var(--accent-cyan);
}
.multi-select-option {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  border-radius: var(--radius-xs);
  cursor: pointer;
  font-size: 12.5px;
  line-height: 1.35;
  color: var(--text-muted);
  user-select: none;
  transition: background 0.15s ease, color 0.15s ease;
}
.multi-select-option:hover {
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
}
.multi-select-option:has(input:checked) {
  background: rgba(0, 242, 254, 0.08);
  color: #fff;
}
.multi-select-option input[type="checkbox"] {
  accent-color: var(--accent-cyan);
  width: 15px;
  height: 15px;
  cursor: pointer;
  flex-shrink: 0;
  margin: 0;
}
.multi-select-option span {
  flex: 1;
  word-break: break-word;
}


/* 23. Toasts */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 999999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}
.toast {
  pointer-events: auto;
  position: relative;
  background: rgba(18, 14, 17, 0.96);
  color: #fff;
  border: 1px solid var(--accent-green);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.8), 0 0 15px rgba(16, 185, 129, 0.3);
  border-radius: var(--radius-sm);
  padding: 12px 20px;
  font-size: 13.5px;
  font-weight: 600;
  backdrop-filter: var(--blur-glass);
  animation: modalSlideUp 0.25s ease;
  max-width: 420px;
  transition: opacity 0.3s;
}
.toast-error {
  border-color: var(--primary-red) !important;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.8), 0 0 15px var(--primary-red-glow) !important;
}
.toast-info {
  border-color: var(--accent-cyan) !important;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.8), 0 0 15px var(--accent-cyan-glow) !important;
}

/* 24. Responsive Styles */
@media (max-width: 1200px) {
  .dashboard-overview-grid,
  .dashboard-lower-grid {
    grid-template-columns: 1fr;
  }
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .command-strip {
    grid-template-columns: repeat(2, 1fr);
  }
  .user-rank-stats-grid {
    grid-template-columns: repeat(2, minmax(175px, 1fr));
  }
}

@media (max-width: 992px) {
  .login-left { display: none; }
  .login-right { width: 100%; }
}

@media (max-width: 768px) {
  .app {
    flex-direction: column;
    padding-top: 0;
  }

  .desktop-topbar {
    display: none !important;
  }

  .mobile-header {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    padding: max(12px, env(safe-area-inset-top, 0px)) 16px 12px;
    background: rgba(14, 10, 13, 0.96);
    border-bottom: 1px solid var(--border-subtle);
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: var(--blur-glass);
    -webkit-backdrop-filter: var(--blur-glass);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    width: 100%;
    box-sizing: border-box;
  }

  .hamburger {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--border-subtle);
    cursor: pointer;
    color: #fff;
    padding: 8px;
    border-radius: var(--radius-xs);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    transition: all 0.2s ease;
  }
  .hamburger:active {
    background: rgba(229, 9, 20, 0.2);
    border-color: var(--primary-red);
  }

  .mobile-header-btn {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--border-subtle);
    color: var(--text-muted);
    width: 38px;
    height: 38px;
    border-radius: var(--radius-xs);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    cursor: pointer;
    transition: all 0.2s ease;
  }
  .mobile-header-btn:active {
    background: rgba(229, 9, 20, 0.2);
    color: #fff;
  }

  .sidebar {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    height: 100vh;
    height: 100dvh;
    max-height: 100dvh;
    width: min(300px, 84vw);
    z-index: 1000;
    transform: translateX(-100%);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: none;
    background: rgba(13, 9, 12, 0.98);
    border-right: 1px solid var(--border-card);
    display: flex;
    flex-direction: column;
    overflow-y: hidden;
  }
  .sidebar.open {
    transform: translateX(0);
    box-shadow: 15px 0 50px rgba(0, 0, 0, 0.92);
  }

  .sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: max(14px, env(safe-area-inset-top, 0px)) 16px 14px;
    border-bottom: 1px solid var(--border-subtle);
  }

  .sidebar-close-btn {
    display: flex !important;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xs);
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s ease;
  }
  .sidebar-close-btn:hover,
  .sidebar-close-btn:active {
    background: rgba(229, 9, 20, 0.2);
    border-color: var(--primary-red);
    color: #fff;
  }

  .sidebar-close {
    display: none !important;
  }

  .sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    z-index: 999;
    opacity: 0;
    transition: opacity 0.25s ease;
    pointer-events: none;
  }
  .sidebar-overlay.open {
    display: block !important;
    opacity: 1 !important;
    pointer-events: auto;
  }

  .content {
    margin-left: 0;
    width: 100%;
    max-width: 100vw;
    box-sizing: border-box;
    padding: 14px 12px 64px;
    overflow-x: hidden;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }

  .command-strip {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }

  .wr-modal-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .command-strip {
    gap: 8px;
  }
  .stats-grid {
    gap: 8px;
  }
  .user-rank-stats-grid {
    grid-template-columns: 1fr;
  }
  .glass-table th, .glass-table td,
  table th, table td {
    padding: 9px 10px;
    font-size: 12px;
  }
}

/* 25. Product Management & Metrics */
.products-hero {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 22px;
  flex-wrap: wrap;
}

.products-hero-copy h2 {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin: 4px 0 6px;
}

.products-hero-copy p {
  font-size: 13px;
  color: var(--text-muted);
}

.products-hero-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.products-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 24px;
}

.product-metric {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  background: var(--bg-card);
  backdrop-filter: var(--blur-glass);
  -webkit-backdrop-filter: var(--blur-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.6);
  cursor: pointer;
  text-align: left;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  user-select: none;
  color: #fff;
  width: 100%;
}

.product-metric:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-hover);
  transform: translateY(-2px);
  box-shadow: 0 14px 30px -5px rgba(0, 0, 0, 0.8);
}

.product-metric.selected {
  border-color: var(--primary-red);
  background: linear-gradient(135deg, rgba(229, 9, 20, 0.12) 0%, rgba(20, 14, 18, 0.85) 100%);
  box-shadow: 0 0 0 1px var(--primary-red), 0 10px 28px -4px var(--primary-red-glow);
}

/* UNIFIED METRIC ICON - synchronized dark cyber theme */
.metric-icon {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-subtle);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.2s ease;
}

.product-metric:hover .metric-icon,
.product-metric.selected .metric-icon {
  background: rgba(229, 9, 20, 0.18);
  border-color: rgba(229, 9, 20, 0.4);
  color: var(--primary-red);
  box-shadow: 0 0 14px var(--primary-red-glow);
}

.metric-icon svg,
.metric-icon i {
  width: 19px;
  height: 19px;
}

.product-metric .metric-body {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
  flex: 1;
}

.product-metric small {
  display: block;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: var(--text-muted);
}

.product-metric strong {
  display: block;
  font-family: var(--font-mono) !important;
  font-size: 22px;
  font-weight: 800;
  line-height: 1.15;
  color: #fff;
}

.product-metric em {
  display: block;
  font-style: normal;
  font-size: 11px;
  color: var(--text-dim);
  margin-top: 1px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.badge-live {
  display: inline-flex;
  align-items: center;
  padding: 2px 7px;
  border-radius: var(--radius-xs);
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.35);
  color: var(--accent-green);
  font-family: var(--font-mono) !important;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.badge-cached {
  display: inline-flex;
  align-items: center;
  padding: 2px 7px;
  border-radius: var(--radius-xs);
  background: rgba(148, 163, 184, 0.12);
  border: 1px solid rgba(148, 163, 184, 0.25);
  color: var(--text-muted);
  font-family: var(--font-mono) !important;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.products-workspace {
  margin-bottom: 24px;
}

.products-filter-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
  flex-wrap: wrap;
  gap: 12px;
}

.products-filter-head h3 {
  font-size: 16px;
  font-weight: 700;
  color: #fff;
  margin-top: 2px;
}

.products-head-right {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

.products-result-count {
  font-family: var(--font-mono) !important;
  font-size: 12.5px;
  color: var(--text-muted);
}
.products-result-count strong {
  color: var(--primary-red);
}

.prod-view-switcher {
  display: inline-flex;
  align-items: center;
  background: rgba(0, 0, 0, 0.45);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 3px;
  gap: 3px;
}

.view-switch-btn {
  height: 30px;
  padding: 0 10px;
  border-radius: var(--radius-xs);
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  user-select: none;
}

.view-switch-btn svg,
.view-switch-btn i {
  width: 14px;
  height: 14px;
}

.view-switch-btn:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.05);
}

.view-switch-btn.active {
  background: rgba(229, 9, 20, 0.18);
  border: 1px solid rgba(229, 9, 20, 0.4);
  color: #fff;
  font-weight: 700;
  box-shadow: 0 0 12px rgba(229, 9, 20, 0.25);
}

.products-filter-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.prod-search-box {
  position: relative;
  flex: 1;
  min-width: 260px;
}

.prod-search-box input {
  width: 100%;
  height: 38px;
  padding: 0 34px 0 36px;
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: #fff;
  font-size: 13px;
  outline: none;
  transition: all 0.2s ease;
}

.prod-search-box input:focus {
  border-color: var(--primary-red);
  background: rgba(14, 10, 13, 0.9);
  box-shadow: 0 0 0 1px var(--primary-red), 0 0 14px var(--primary-red-glow);
}

.prod-search-icon {
  position: absolute;
  left: 11px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-dim);
  width: 15px;
  height: 15px;
  pointer-events: none;
}

.prod-search-clear {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  color: var(--text-dim);
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.15s ease;
}

.prod-search-clear:hover {
  color: #fff;
}

.prod-search-clear svg {
  width: 14px;
  height: 14px;
}

.products-filter-tabs-row {
  margin-bottom: 16px;
}

.products-filter-tabs {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.products-selectors {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.products-selectors select {
  height: 38px;
  min-width: 160px;
  padding: 0 12px;
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: #fff;
  font-size: 13px;
  outline: none;
  cursor: pointer;
}

.product-orphan-btn {
  width: 38px;
  height: 38px;
  padding: 0 !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* Redesigned Floating Row Cards Table */
.products-table-wrap {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 6px;
}

.products-modern-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0 8px;
  font-size: 13px;
  text-align: left;
  margin: 0;
}

.products-modern-table thead tr {
  background: transparent;
  border: none;
}

.products-modern-table thead th {
  background: rgba(18, 12, 16, 0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: var(--text-muted);
  font-family: var(--font-mono) !important;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  padding: 11px 16px;
  border: none;
  white-space: nowrap;
}

.products-modern-table thead th:first-child {
  border-radius: var(--radius-sm) 0 0 var(--radius-sm);
}

.products-modern-table thead th:last-child {
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.prod-modern-row {
  transition: transform 0.15s cubic-bezier(0.4, 0, 0.2, 1);
}

.prod-modern-row td {
  background: var(--bg-card);
  backdrop-filter: var(--blur-glass);
  -webkit-backdrop-filter: var(--blur-glass);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
  padding: 13px 16px;
  vertical-align: middle;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.prod-modern-row td:first-child {
  border-left: 1px solid var(--border-subtle);
  border-radius: var(--radius-md) 0 0 var(--radius-md);
}

.prod-modern-row td:last-child {
  border-right: 1px solid var(--border-subtle);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
}

.prod-modern-row:hover td {
  background: var(--bg-card-hover);
  border-color: rgba(229, 9, 20, 0.32);
  box-shadow: 0 4px 18px -2px rgba(0, 0, 0, 0.7);
}

/* Cells Styling */
.prod-id-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono) !important;
  font-size: 11px;
  font-weight: 700;
  color: #f1f5f9;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 2px 7px;
  border-radius: var(--radius-xs);
  letter-spacing: 0.5px;
  white-space: nowrap;
}

.prod-cell-main {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 220px;
}

.prod-avatar-icon {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, rgba(229, 9, 20, 0.12) 0%, rgba(255, 255, 255, 0.03) 100%);
  border: 1px solid rgba(229, 9, 20, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary-red);
  flex-shrink: 0;
}

.prod-avatar-icon svg,
.prod-avatar-icon i {
  width: 17px;
  height: 17px;
}

.prod-title-wrap {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.prod-title {
  font-size: 13.5px;
  font-weight: 700;
  color: #fff;
  line-height: 1.35;
}

.prod-badge-tag {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 4px;
  font-family: var(--font-mono) !important;
  margin: 0 2px;
  vertical-align: middle;
  letter-spacing: 0.3px;
}

.prod-tag-slot {
  background: rgba(229, 9, 20, 0.14);
  border: 1px solid rgba(229, 9, 20, 0.35);
  color: #ff6b70;
}

.prod-tag-code {
  background: rgba(56, 189, 248, 0.14);
  border: 1px solid rgba(56, 189, 248, 0.35);
  color: #38bdf8;
}

.prod-tag-type {
  background: rgba(168, 85, 247, 0.14);
  border: 1px solid rgba(168, 85, 247, 0.35);
  color: #c084fc;
}

.prod-tag-default {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #cbd5e1;
}

.prod-meta-badges {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 2px;
}

.prod-sub-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 600;
  padding: 1px 7px;
  border-radius: 4px;
  line-height: 1.3;
}

.prod-sub-badge svg,
.prod-sub-badge i {
  width: 11px;
  height: 11px;
}

.prod-sub-badge.link {
  background: rgba(168, 85, 247, 0.1);
  border: 1px solid rgba(168, 85, 247, 0.25);
  color: #d8b4fe;
}

.prod-sub-badge.source {
  background: rgba(56, 189, 248, 0.1);
  border: 1px solid rgba(56, 189, 248, 0.25);
  color: #7dd3fc;
}

.prod-sub-badge.warranty {
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.25);
  color: #6ee7b7;
}

.prod-cat-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  font-weight: 600;
  color: #e2e8f0;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 4px 10px;
  border-radius: 20px;
  white-space: nowrap;
}

.prod-price-cell {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.prod-price-main {
  font-family: var(--font-mono) !important;
  font-size: 13.5px;
  font-weight: 800;
  color: #ffffff;
  white-space: nowrap;
}

.prod-price-flags {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}

.prod-flag-pill {
  font-size: 9.5px;
  font-weight: 700;
  font-family: var(--font-mono) !important;
  padding: 1px 5px;
  border-radius: 3px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.prod-flag-pill.no-bonus {
  background: rgba(239, 68, 68, 0.12);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.25);
}

.prod-flag-pill.no-ctv {
  background: rgba(245, 158, 11, 0.12);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.25);
}

.prod-stock-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 30px;
  font-family: var(--font-mono) !important;
  font-size: 12.5px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: var(--radius-xs);
}

.prod-stock-num.pos {
  color: #4ade80;
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.25);
}

.prod-stock-num.zero {
  color: var(--text-dim);
  background: rgba(255, 255, 255, 0.03);
}

.prod-stock-source {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-family: var(--font-mono) !important;
  font-size: 12px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: var(--radius-xs);
}

.prod-stock-source.pos {
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.1);
  border: 1px solid rgba(56, 189, 248, 0.25);
}

.prod-stock-source.zero {
  color: #64748b;
  background: rgba(255, 255, 255, 0.03);
}

.prod-stock-source svg,
.prod-stock-source i {
  width: 12px;
  height: 12px;
}

.prod-dash {
  color: var(--text-dim);
  font-size: 13px;
}

.prod-total-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px;
  border-radius: 100px;
  font-family: var(--font-mono) !important;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.prod-total-pill.available {
  color: #34d399;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.prod-total-pill.empty {
  color: #f87171;
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.25);
}

.stock-pulse-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  display: inline-block;
}

.prod-total-pill.available .stock-pulse-dot {
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
  animation: pulseGlow 2s infinite;
}

.prod-total-pill.empty .stock-pulse-dot {
  background: #ef4444;
}

.prod-status-group {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-wrap: wrap;
}

.prod-status-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 600;
}

.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  display: inline-block;
}

.status-dot.green {
  background: #10b981;
  box-shadow: 0 0 6px #10b981;
}

.status-dot.red {
  background: #ef4444;
}

.status-dot.orange {
  background: #f59e0b;
}

/* Action Buttons - Always 1 row */
.prod-row-actions {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  white-space: nowrap;
  flex-wrap: nowrap;
}

.prod-btn-action {
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-subtle);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  padding: 0;
}

.prod-btn-action svg,
.prod-btn-action i {
  width: 14px;
  height: 14px;
}

.prod-btn-action.edit:hover {
  background: rgba(59, 130, 246, 0.18);
  border-color: rgba(59, 130, 246, 0.5);
  color: #60a5fa;
  transform: translateY(-1px);
  box-shadow: 0 0 10px rgba(59, 130, 246, 0.3);
}

.prod-btn-action.stock:hover {
  background: rgba(168, 85, 247, 0.18);
  border-color: rgba(168, 85, 247, 0.5);
  color: #c084fc;
  transform: translateY(-1px);
  box-shadow: 0 0 10px rgba(168, 85, 247, 0.3);
}

.prod-btn-action.delete:hover {
  background: rgba(229, 9, 20, 0.22);
  border-color: rgba(229, 9, 20, 0.5);
  color: var(--primary-red);
  transform: translateY(-1px);
  box-shadow: 0 0 10px var(--primary-red-glow);
}

/* Grid Cards Layout */
.products-grid-layout {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 16px;
  margin-top: 6px;
}

.prod-card-item {
  background: var(--bg-card);
  backdrop-filter: var(--blur-glass);
  -webkit-backdrop-filter: var(--blur-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 8px 24px -6px rgba(0, 0, 0, 0.6);
  position: relative;
}

.prod-card-item:hover {
  background: var(--bg-card-hover);
  border-color: rgba(229, 9, 20, 0.35);
  transform: translateY(-2px);
  box-shadow: 0 12px 30px -4px rgba(0, 0, 0, 0.8), 0 0 14px rgba(229, 9, 20, 0.15);
}

.prod-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  padding-bottom: 10px;
}

.prod-card-id-cat {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.prod-card-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}

.prod-card-icon-title {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.prod-card-name {
  font-size: 14px;
  font-weight: 700;
  color: #fff;
  line-height: 1.35;
  flex: 1;
}

.prod-card-price-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 8px 12px;
  background: rgba(0, 0, 0, 0.3);
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.04);
}

.prod-card-price-label {
  font-size: 11px;
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.prod-card-price-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
}

.prod-card-price-val {
  font-family: var(--font-mono) !important;
  font-size: 15px;
  font-weight: 800;
  color: #fff;
}

.prod-card-stock-box {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-sm);
  padding: 9px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.prod-card-stock-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.prod-card-stock-lbl {
  font-size: 11.5px;
  color: var(--text-muted);
  font-weight: 600;
}

.prod-card-stock-details {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 11px;
  font-family: var(--font-mono);
  color: var(--text-dim);
}

.prod-card-stock-detail {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.prod-card-stock-detail svg,
.prod-card-stock-detail i {
  width: 11px;
  height: 11px;
}

.prod-card-stock-detail.local {
  color: #4ade80;
}

.prod-card-stock-detail.source {
  color: #38bdf8;
}

.prod-card-stock-detail.dim {
  color: var(--text-dim);
}

.prod-card-extra-badges {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.prod-card-footer {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.04);
  margin-top: auto;
}

.prod-card-btn {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  height: 32px;
  font-size: 12px;
}

.prod-card-btn.delete {
  flex: 0 0 34px;
  padding: 0 !important;
}

/* Empty Card State */
.products-empty-card {
  background: var(--bg-card);
  backdrop-filter: var(--blur-glass);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
}

.products-empty-state {
  text-align: center;
  padding: 50px 20px;
  color: var(--text-muted);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.products-empty-state svg,
.products-empty-state i {
  width: 42px;
  height: 42px;
  color: var(--text-dim);
  opacity: 0.7;
}

.products-empty-state p {
  font-size: 14px;
  margin: 0;
}

.products-empty {
  text-align: center;
  color: var(--text-muted);
  padding: 36px 16px;
  font-size: 13.5px;
}

@media (max-width: 768px) {
  .products-grid-layout {
    grid-template-columns: 1fr;
  }
  .products-filter-head {
    flex-direction: column;
    align-items: flex-start;
  }
  .products-head-right {
    width: 100%;
    justify-content: space-between;
  }
}

/* 26. Modal Balanced Forms & Two-Column Grid */
.add-product-layout,
.edit-product-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
  align-items: start;
}

.add-product-column,
.edit-product-left,
.edit-product-right {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.add-product-section-head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 20px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border-subtle);
}

.add-product-step {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: var(--radius-sm);
  background: rgba(229, 9, 20, 0.14);
  border: 1px solid rgba(229, 9, 20, 0.35);
  color: var(--primary-red);
  font-family: var(--font-mono) !important;
  font-weight: 800;
  font-size: 13px;
  flex-shrink: 0;
  box-shadow: 0 0 12px var(--primary-red-glow);
}

.add-product-section-head h4 {
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  margin-bottom: 2px;
}

.add-product-section-head p {
  font-size: 12px;
  color: var(--text-muted);
}

.add-product-description textarea {
  min-height: 110px;
}

/* Option Cards (Combo, etc.) */
.add-product-option {
  padding: 14px 16px;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  margin-bottom: 14px;
  transition: border-color 0.2s ease;
}

.add-product-option:hover {
  border-color: var(--border-hover);
}

.add-product-option .form-group:last-child {
  margin-bottom: 0;
}

.add-product-option label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
}

.add-product-option small {
  display: block;
  margin-top: 6px;
  font-size: 11.5px;
  color: var(--text-dim);
  line-height: 1.4;
}

/* Balanced Toggles */
.add-product-toggles {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 8px;
}

.add-product-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 16px;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  user-select: none;
}

.add-product-toggle:hover {
  background: rgba(255, 255, 255, 0.03);
  border-color: var(--border-hover);
}

.add-product-toggle:has(input:checked) {
  border-color: rgba(229, 9, 20, 0.45);
  background: rgba(229, 9, 20, 0.06);
  box-shadow: 0 0 16px rgba(229, 9, 20, 0.12);
}

.add-product-toggle .toggle-content {
  display: flex;
  flex-direction: column;
  gap: 3px;
  flex: 1;
  min-width: 0;
}

.add-product-toggle .toggle-title {
  font-size: 13.5px;
  font-weight: 700;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 8px;
}

.add-product-toggle .toggle-title svg {
  width: 15px;
  height: 15px;
  flex-shrink: 0;
}

.add-product-toggle .toggle-desc {
  font-size: 11.5px;
  color: var(--text-muted);
  line-height: 1.45;
}

/* Modal Footers */
.add-product-footer,
.edit-product-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 24px;
  padding-top: 18px;
  border-top: 1px solid var(--border-subtle);
}

.add-product-footer span,
.edit-product-footer span {
  font-size: 12.5px;
  color: var(--text-dim);
}

/* 27. Stock Management Modal */
.stock-landscape-layout {
  display: grid;
  grid-template-columns: 1fr 1.35fr;
  gap: 24px;
  align-items: start;
}

.stock-import-panel {
  display: flex;
  flex-direction: column;
}

.stock-summary-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 16px;
}

.stock-stat-box {
  padding: 12px 14px;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
}

.stock-stat-box small {
  display: block;
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  font-weight: 700;
}

.stock-stat-box strong {
  display: block;
  font-family: var(--font-mono) !important;
  font-size: 20px;
  font-weight: 800;
  color: #fff;
  margin-top: 2px;
}

.stock-import-area {
  min-height: 160px;
  margin-bottom: 14px;
}

.stock-list-panel {
  display: flex;
  flex-direction: column;
}

.stock-list-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}

.stock-list-head h4 {
  font-size: 16px;
  font-weight: 700;
}

.stock-table-scroll {
  max-height: 380px;
  overflow-y: auto;
}

.stock-delete-history {
  margin-top: 24px;
  padding-top: 18px;
  border-top: 1px solid var(--border-subtle);
}

.stock-delete-history .section-title {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-muted);
  margin-bottom: 10px;
}

/* Stock duplicate management */
.stock-dup-alert {
  background: rgba(245, 158, 11, 0.09);
  border: 1px solid rgba(245, 158, 11, 0.35);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.stock-dup-alert-info {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  color: #fbbf24;
}

.stock-row-redundant {
  background: rgba(245, 158, 11, 0.08) !important;
}

.stock-row-redundant:hover {
  background: rgba(245, 158, 11, 0.16) !important;
}

.stock-row-sold-dup {
  background: rgba(239, 68, 68, 0.12) !important;
}

.stock-row-sold-dup:hover {
  background: rgba(239, 68, 68, 0.22) !important;
}

.stock-row-dup-original {
  background: rgba(59, 130, 246, 0.05);
}

.stock-dup-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 10px;
  padding: 1px 6px;
  border-radius: 4px;
  background: rgba(245, 158, 11, 0.2);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.35);
  margin-left: 6px;
  vertical-align: middle;
}

.stock-sold-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-size: 10px;
  padding: 1px 6px;
  border-radius: 4px;
  background: rgba(239, 68, 68, 0.2);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.35);
  margin-left: 6px;
  vertical-align: middle;
}

.stock-import-stats {
  font-size: 11.5px;
  line-height: 1.4;
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--border-subtle);
  margin-top: 8px;
}

.stock-import-stats.has-dups {
  background: rgba(245, 158, 11, 0.09);
  border-color: rgba(245, 158, 11, 0.35);
  color: #fbbf24;
}

.stock-import-stats.clean {
  background: rgba(16, 185, 129, 0.09);
  border-color: rgba(16, 185, 129, 0.35);
  color: #34d399;
}

.btn-warning {
  background: linear-gradient(135deg, #d97706 0%, #b45309 100%) !important;
  color: #FFFFFF !important;
  border: 1px solid rgba(245, 158, 11, 0.4) !important;
}

.btn-warning:hover {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%) !important;
  box-shadow: 0 6px 20px rgba(217, 119, 6, 0.4) !important;
}

/* 28. Drag and Drop Sortables */
.sortable-item {
  user-select: none;
  transition: background 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}

.sortable-item:hover {
  border-color: var(--accent-cyan) !important;
}

.sortable-ghost {
  opacity: 0.4;
  background: rgba(229, 9, 20, 0.15) !important;
  border: 1px dashed var(--primary-red) !important;
}

/* 29. Search Input Wrappers & Chips */
.search-input-wrapper {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-width: 260px;
}
.search-input-wrapper .search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  width: 15px;
  height: 15px;
  color: var(--text-dim, #94a3b8);
  pointer-events: none;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
}
.search-input-wrapper .search-box {
  width: 100%;
  padding-left: 36px !important;
  padding-right: 32px !important;
  height: 38px;
  font-size: 13px;
  background: var(--bg-input);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: #ffffff;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.search-input-wrapper .search-box:focus {
  border-color: rgba(229, 9, 20, 0.6);
  box-shadow: 0 0 0 2px rgba(229, 9, 20, 0.15);
}
.search-input-wrapper .search-clear-btn {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.1);
  border: none;
  border-radius: 50%;
  width: 18px;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-dim, #94a3b8);
  cursor: pointer;
  font-size: 10px;
  padding: 0;
  transition: all 0.15s ease;
  z-index: 2;
}
.search-input-wrapper .search-clear-btn:hover {
  background: rgba(255, 255, 255, 0.25);
  color: #ffffff;
}

.search-active-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(56, 189, 248, 0.08);
  border: 1px solid rgba(56, 189, 248, 0.25);
  border-radius: var(--radius-sm);
  padding: 6px 12px;
  font-size: 12.5px;
  color: var(--text-main, #e2e8f0);
  margin-bottom: 10px;
}
.search-active-chip .chip-query {
  color: var(--accent-cyan, #38bdf8);
  font-weight: 700;
}
.search-active-chip .chip-clear-btn {
  background: rgba(255, 255, 255, 0.1);
  border: none;
  border-radius: 50%;
  width: 18px;
  height: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  cursor: pointer;
  font-size: 10px;
  padding: 0;
  transition: all 0.15s ease;
}
.search-active-chip .chip-clear-btn:hover {
  background: rgba(239, 68, 68, 0.6);
}

/* 30. Warranty Action Buttons in Sold Orders */
.btn-action-replace,
.btn-action-refund,
.btn-action-lock,
.btn-action-unlock,
.btn-action-exception,
.btn-action-close-exception,
.btn-action-history {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 8px;
  font-size: 11.5px;
  font-weight: 600;
  border-radius: var(--radius-xs);
  border: 1px solid var(--border-subtle);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-main, #e2e8f0);
  cursor: pointer;
  transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
  white-space: nowrap;
  line-height: 1.2;
}
.btn-action-replace:hover,
.btn-action-refund:hover,
.btn-action-lock:hover,
.btn-action-unlock:hover,
.btn-action-exception:hover,
.btn-action-close-exception:hover,
.btn-action-history:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.25);
  transform: translateY(-1px);
}
.btn-action-replace {
  border-color: rgba(56, 189, 248, 0.35);
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.08);
}
.btn-action-replace:hover {
  background: rgba(56, 189, 248, 0.18);
  border-color: #38bdf8;
  color: #fff;
}
.btn-action-refund {
  border-color: rgba(245, 158, 11, 0.35);
  color: #f59e0b;
  background: rgba(245, 158, 11, 0.08);
}
.btn-action-refund:hover {
  background: rgba(245, 158, 11, 0.18);
  border-color: #f59e0b;
  color: #fff;
}
.btn-action-lock {
  border-color: rgba(239, 68, 68, 0.35);
  color: #f87171;
  background: rgba(239, 68, 68, 0.08);
}
.btn-action-lock:hover {
  background: rgba(239, 68, 68, 0.18);
  border-color: #ef4444;
  color: #fff;
}
.btn-action-unlock {
  border-color: rgba(16, 185, 129, 0.35);
  color: #34d399;
  background: rgba(16, 185, 129, 0.08);
}
.btn-action-unlock:hover {
  background: rgba(16, 185, 129, 0.18);
  border-color: #10b981;
  color: #fff;
}
.btn-action-exception {
  border-color: rgba(168, 85, 247, 0.35);
  color: #c084fc;
  background: rgba(168, 85, 247, 0.08);
}
.btn-action-exception:hover {
  background: rgba(168, 85, 247, 0.18);
  border-color: #a855f7;
  color: #fff;
}
.btn-action-close-exception {
  border-color: rgba(249, 115, 22, 0.35);
  color: #fb923c;
  background: rgba(249, 115, 22, 0.08);
}
.btn-action-close-exception:hover {
  background: rgba(249, 115, 22, 0.18);
  border-color: #f97316;
  color: #fff;
}
.btn-action-history {
  border-color: rgba(255, 255, 255, 0.15);
  color: #94a3b8;
  background: rgba(255, 255, 255, 0.04);
}
.btn-action-history:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.3);
  color: #fff;
}
.btn-action-replace svg, .btn-action-refund svg, .btn-action-lock svg,
.btn-action-unlock svg, .btn-action-exception svg, .btn-action-close-exception svg,
.btn-action-history svg {
  width: 12px;
  height: 12px;
  flex-shrink: 0;
}

@media (max-width: 900px) {
  .products-metrics {
    grid-template-columns: repeat(2, 1fr);
  }
  .add-product-layout,
  .edit-product-grid,
  .stock-landscape-layout {
    grid-template-columns: 1fr;
  }
}


/* ==========================================================================
   32. COMPREHENSIVE MOBILE RESPONSIVE ENGINE (< 768px, < 576px, < 400px)
   Ultra-polished experience for mobile phones & small screens
   ========================================================================== */

/* Touch Scrollbar Styling for Mobile Containers */
.table-wrap::-webkit-scrollbar,
.glass-table-wrap::-webkit-scrollbar,
.products-table-wrap::-webkit-scrollbar,
.user-history-table-container::-webkit-scrollbar {
  height: 5px;
  width: 5px;
}
.table-wrap::-webkit-scrollbar-track,
.glass-table-wrap::-webkit-scrollbar-track,
.products-table-wrap::-webkit-scrollbar-track,
.user-history-table-container::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.25);
  border-radius: 4px;
}
.table-wrap::-webkit-scrollbar-thumb,
.glass-table-wrap::-webkit-scrollbar-thumb,
.products-table-wrap::-webkit-scrollbar-thumb,
.user-history-table-container::-webkit-scrollbar-thumb {
  background: rgba(229, 9, 20, 0.4);
  border-radius: 4px;
}
.table-wrap::-webkit-scrollbar-thumb:hover,
.glass-table-wrap::-webkit-scrollbar-thumb:hover,
.products-table-wrap::-webkit-scrollbar-thumb:hover,
.user-history-table-container::-webkit-scrollbar-thumb:hover {
  background: var(--primary-red);
}

@media (max-width: 768px) {
  /* Prevent horizontal page swaying / wobbling */
  html, body {
    overflow-x: hidden;
    overflow-x: clip;
    width: 100% !important;
    max-width: 100vw !important;
    position: relative;
    -webkit-text-size-adjust: 100%;
  }

  .app {
    overflow-x: clip;
    max-width: 100vw !important;
    width: 100% !important;
  }

  .content {
    margin-left: 0 !important;
    width: 100% !important;
    max-width: 100vw !important;
    padding: 14px 12px 64px !important;
    box-sizing: border-box !important;
    overflow-x: hidden !important;
    min-height: auto !important;
  }

  /* Prevent iOS Safari from zooming in on input focus */
  input:not([type="checkbox"]):not([type="radio"]),
  select,
  textarea {
    font-size: 16px !important;
  }

  /* Typography on Mobile */
  .page-header {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 8px !important;
    margin-bottom: 16px !important;
  }

  .page-header h2 {
    font-size: 20px !important;
    line-height: 1.25 !important;
    letter-spacing: -0.02em !important;
  }

  .page-header .page-sub {
    font-size: 12px !important;
    margin-top: 3px !important;
  }

  /* Command Strip Quick Actions */
  .command-strip {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 8px !important;
    margin-bottom: 14px !important;
  }

  .command-card {
    padding: 10px 12px !important;
    grid-template-columns: 32px 1fr auto !important;
    gap: 8px !important;
    border-radius: var(--radius-sm) !important;
  }

  .command-icon {
    width: 32px !important;
    height: 32px !important;
    border-radius: 6px !important;
  }
  .command-icon svg,
  .command-icon i {
    width: 16px !important;
    height: 16px !important;
  }

  .command-card strong {
    font-size: 12.5px !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    display: block !important;
  }

  .command-card small {
    display: none !important;
  }

  /* KPI / Stats Grid */
  .stats-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 8px !important;
    margin-bottom: 0 !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .stat-card {
    padding: 10px 10px !important;
    border-radius: var(--radius-sm) !important;
    min-width: 0 !important;
    max-width: 100% !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
  }

  .stat-card .label {
    font-size: 10px !important;
    letter-spacing: 0.3px !important;
    margin-bottom: 4px !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  .stat-card .value {
    font-size: clamp(12.5px, 3.8vw, 16px) !important;
    line-height: 1.25 !important;
    word-break: break-word !important;
    overflow-wrap: break-word !important;
  }

  .stat-card .sub {
    font-size: 10px !important;
    margin-top: 3px !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  .sparkline-container {
    display: none !important;
  }

  /* Overview & Lower Grids */
  .dashboard-overview-grid,
  .dashboard-lower-grid {
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 12px !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  .dashboard-overview-grid > *,
  .dashboard-lower-grid > * {
    min-width: 0 !important;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .kpi-panel,
  .chart-section,
  .dashboard-main-col,
  .dashboard-side-col {
    padding: 14px 12px !important;
    border-radius: var(--radius-md) !important;
    min-width: 0 !important;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .panel-heading {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 8px !important;
    margin-bottom: 12px !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }

  .panel-heading > div:first-child {
    min-width: 0 !important;
    flex: 1 !important;
  }

  .panel-heading h3 {
    font-size: 14px !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  .panel-heading .live-pill,
  .panel-heading .panel-link {
    flex-shrink: 0 !important;
  }

  .chart-bars {
    height: 140px !important;
    gap: 4px !important;
    padding-top: 14px !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    display: flex !important;
    align-items: flex-end !important;
    justify-content: space-between !important;
    overflow: hidden !important;
  }

  .chart-bar {
    flex: 1 1 0% !important;
    min-width: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 5px !important;
    height: 100% !important;
    box-sizing: border-box !important;
  }

  .chart-bar .bar {
    width: 100% !important;
    max-width: 22px !important;
    border-radius: 4px 4px 2px 2px !important;
    box-sizing: border-box !important;
  }

  .chart-bar .bar-label {
    font-size: 9px !important;
    white-space: nowrap !important;
    text-align: center !important;
    color: var(--text-dim) !important;
  }

  .chart-bar .bar-value {
    font-size: 8.5px !important;
    white-space: nowrap !important;
    text-align: center !important;
    color: var(--text-muted) !important;
    font-family: var(--font-mono) !important;
    line-height: 1 !important;
    letter-spacing: -0.3px !important;
  }

  /* Products Hero & Actions */
  .products-hero {
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 12px !important;
    margin-bottom: 14px !important;
  }

  .products-hero-copy h2 {
    font-size: 20px !important;
  }

  .products-hero-actions {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 8px !important;
    width: 100% !important;
  }

  .products-hero-actions .btn {
    width: 100% !important;
    justify-content: center !important;
    height: 38px !important;
    font-size: 12px !important;
    padding: 0 8px !important;
  }

  /* Products Metrics */
  .products-metrics {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 8px !important;
    margin-bottom: 14px !important;
  }

  .product-metric {
    padding: 10px 12px !important;
    gap: 10px !important;
    border-radius: var(--radius-sm) !important;
  }

  .metric-icon {
    width: 34px !important;
    height: 34px !important;
    border-radius: 6px !important;
  }
  .metric-icon svg,
  .metric-icon i {
    width: 16px !important;
    height: 16px !important;
  }

  .product-metric strong {
    font-size: 17px !important;
  }

  .product-metric small {
    font-size: 10px !important;
  }

  .product-metric span {
    font-size: 10px !important;
  }

  /* Products Filter Toolbar */
  .products-filter-head {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 8px !important;
  }

  .products-head-right {
    width: 100% !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
  }

  .products-filter-row {
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 8px !important;
    width: 100% !important;
  }

  .prod-search-box {
    width: 100% !important;
    min-width: 0 !important;
  }

  .products-selectors {
    width: 100% !important;
    display: flex !important;
    gap: 8px !important;
  }

  .products-selectors select {
    flex: 1 !important;
    min-width: 0 !important;
    height: 38px !important;
  }

  .products-filter-tabs-row {
    margin-bottom: 12px !important;
  }

  .products-filter-tabs {
    display: flex !important;
    overflow-x: auto !important;
    flex-wrap: nowrap !important;
    -webkit-overflow-scrolling: touch !important;
    padding-bottom: 4px !important;
    gap: 6px !important;
    scrollbar-width: none !important;
  }

  .products-filter-tabs::-webkit-scrollbar {
    display: none !important;
  }

  .products-filter-tabs button {
    flex-shrink: 0 !important;
    white-space: nowrap !important;
    padding: 6px 12px !important;
    font-size: 12px !important;
  }

  /* Products Table & Grid Layout */
  .products-table-wrap {
    width: 100% !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
    border-radius: var(--radius-sm) !important;
    margin-bottom: 16px !important;
  }

  .products-modern-table {
    min-width: 760px !important;
    border-spacing: 0 6px !important;
  }

  .prod-modern-row td {
    padding: 10px 12px !important;
  }

  .products-grid-layout {
    grid-template-columns: 1fr !important;
    gap: 12px !important;
  }

  .prod-card {
    padding: 14px !important;
  }

  .prod-card-actions {
    display: flex !important;
    gap: 6px !important;
    width: 100% !important;
  }

  .prod-card-btn {
    flex: 1 !important;
    justify-content: center !important;
    height: 36px !important;
  }

  /* Universal Tables & Table Scrolling Across Views */
  .table-wrap,
  .glass-table-wrap {
    width: 100% !important;
    max-width: 100% !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
    border-radius: var(--radius-sm) !important;
    margin-bottom: 16px !important;
  }

  .table-wrap table,
  .glass-table-wrap table,
  .glass-table {
    min-width: 650px !important;
  }

  .glass-table th, .glass-table td,
  table th, table td {
    padding: 9px 10px !important;
    font-size: 12px !important;
  }

  table .btn-group {
    white-space: nowrap !important;
    flex-wrap: nowrap !important;
    gap: 4px !important;
  }

  /* Search Inputs & Filter Bars in Orders, Sold, Users, etc. */
  .search-input-wrapper {
    width: 100% !important;
    min-width: 0 !important;
    margin-left: 0 !important;
  }

  .search-input-wrapper .search-box {
    width: 100% !important;
    height: 40px !important;
    font-size: 14px !important;
  }

  .multi-select-dropdown {
    max-width: 100% !important;
  }

  .multi-select-toggle {
    max-width: 100% !important;
    width: 100% !important;
    height: 38px !important;
  }

  .multi-select-menu {
    left: 0 !important;
    right: 0 !important;
    width: calc(100vw - 28px) !important;
    max-width: 320px !important;
  }

  /* Modals & Popups on Mobile */
  .modal-overlay {
    padding: 10px !important;
    align-items: center !important;
    justify-content: center !important;
  }

  .modal,
  .modal-dialog,
  .modal.modal-wide,
  .modal-dialog.modal-wide,
  .modal.modal-landscape,
  .modal-dialog.modal-landscape {
    width: 100% !important;
    max-width: 100% !important;
    max-height: 92vh !important;
    padding: 16px 14px !important;
    border-radius: 14px !important;
    margin: 0 !important;
    box-sizing: border-box !important;
  }

  .modal-header {
    margin-bottom: 12px !important;
    padding-bottom: 10px !important;
  }

  .modal-header h3 {
    font-size: 15px !important;
    gap: 6px !important;
  }

  .modal-close {
    width: 36px !important;
    height: 36px !important;
    font-size: 20px !important;
    flex-shrink: 0 !important;
  }

  .form-row {
    grid-template-columns: 1fr !important;
    gap: 10px !important;
  }

  .add-product-layout,
  .edit-product-grid,
  .stock-landscape-layout,
  .stock-summary-cards,
  .wr-modal-grid,
  .bc-cat-grid,
  .user-history-stats-bar {
    grid-template-columns: 1fr !important;
    gap: 12px !important;
  }

  .user-history-table-container {
    max-height: 45vh !important;
  }

  .modal-body .btn {
    width: 100% !important;
    justify-content: center !important;
    min-height: 40px !important;
  }

  /* Dynamic Multi-Column Inline Grids Collapse to 1 Column */
  [style*="grid-template-columns:1fr 1fr"],
  [style*="grid-template-columns: 1fr 1fr"],
  [style*="grid-template-columns:repeat(2"],
  [style*="grid-template-columns: repeat(2"],
  [style*="grid-template-columns:repeat(3"],
  [style*="grid-template-columns: repeat(3"],
  [style*="grid-template-columns:3fr 1fr"],
  [style*="grid-template-columns: 3fr 1fr"] {
    grid-template-columns: 1fr !important;
    gap: 12px !important;
  }

  /* Rank Management */
  .rank-filter-bar {
    display: flex !important;
    flex-direction: column !important;
    gap: 8px !important;
  }

  .rank-filter-bar .rank-search,
  .rank-filter-bar select,
  .rank-filter-bar input,
  .rank-filter-bar .btn {
    width: 100% !important;
  }

  .rank-summary-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 8px !important;
  }

  .support-metrics {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 8px !important;
  }

  

  /* Login Screen on Mobile */
  .login-right {
    padding: 24px 16px !important;
    width: 100% !important;
  }

  .login-form-container {
    max-width: 100% !important;
    padding: 24px 18px !important;
  }

  .login-form-header h2 {
    font-size: 22px !important;
  }

  /* Toast Notifications Centered on Mobile */
  .toast-container {
    left: 12px !important;
    right: 12px !important;
    bottom: max(16px, env(safe-area-inset-bottom, 16px)) !important;
    max-width: 100% !important;
    align-items: center !important;
  }

  .toast {
    max-width: 100% !important;
    width: 100% !important;
    text-align: center !important;
    padding: 10px 14px !important;
    font-size: 13px !important;
  }
}

/* Extremely Small Screens (< 340px) */
@media (max-width: 340px) {
  .command-strip {
    grid-template-columns: 1fr !important;
  }

  .stats-grid {
    grid-template-columns: 1fr !important;
  }

  .products-hero-actions {
    grid-template-columns: 1fr !important;
  }

  .products-metrics {
    grid-template-columns: 1fr !important;
  }

  .rank-summary-grid {
    grid-template-columns: 1fr !important;
  }

  .support-metrics {
    grid-template-columns: 1fr !important;
  }
}

.provider-badge-accent {
  background: rgba(14, 165, 233, 0.15);
  color: #38bdf8;
  border: 1px solid rgba(14, 165, 233, 0.3);
}

.provider-badge-other {
  background: rgba(148, 163, 184, 0.15);
  color: #cbd5e1;
  border: 1px solid rgba(148, 163, 184, 0.3);
}







