/* ===================================================
   GrabGains Supplier Portal — Mobile-first CSS
   Colors: --primary #00B2A9 | --accent #FF6B00
   =================================================== */

:root {
  --primary: #00B2A9;
  --primary-dark: #009490;
  --primary-light: #E6F7F6;
  --accent: #FF6B00;
  --accent-light: #FFF3EB;
  --success: #10B981;
  --success-light: #D1FAE5;
  --warning: #F59E0B;
  --warning-light: #FEF3C7;
  --danger: #EF4444;
  --danger-light: #FEE2E2;
  --info: #3B82F6;
  --info-light: #DBEAFE;
  --gray-50: #F9FAFB;
  --gray-100: #F3F4F6;
  --gray-200: #E5E7EB;
  --gray-300: #D1D5DB;
  --gray-400: #9CA3AF;
  --gray-500: #6B7280;
  --gray-600: #4B5563;
  --gray-700: #374151;
  --gray-800: #1F2937;
  --gray-900: #111827;
  --white: #FFFFFF;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.08);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.10);
  --shadow-lg: 0 8px 24px rgba(0,0,0,0.12);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --sidebar-width: 240px;
  --topbar-height: 60px;
  --bottom-nav-height: 64px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 16px; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font);
  color: var(--gray-800);
  background: var(--gray-50);
  min-height: 100vh;
  line-height: 1.5;
}

a { color: inherit; text-decoration: none; }
button { cursor: pointer; font-family: var(--font); }
img { max-width: 100%; }

/* ===================================================
   AUTH PAGES (Login / Register)
   =================================================== */

.auth-body {
  background: linear-gradient(135deg, #00B2A9 0%, #009490 40%, #FF6B00 100%);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.auth-container {
  width: 100%;
  max-width: 440px;
}

.auth-card {
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: 32px 24px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.2);
}

.auth-logo {
  text-align: center;
  margin-bottom: 20px;
}

.auth-logo a {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.auth-logo-img {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  object-fit: cover;
}

.auth-logo-text {
  font-size: 22px;
  font-weight: 800;
}

.auth-logo-text .grab { color: var(--gray-900); }
.auth-logo-text .gains { color: var(--primary); }

.auth-header {
  text-align: center;
  margin-bottom: 24px;
}

.auth-badge {
  display: inline-block;
  background: var(--primary-light);
  color: var(--primary-dark);
  font-size: 12px;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 10px;
  letter-spacing: 0.5px;
}

.auth-header h1 {
  font-size: 24px;
  font-weight: 800;
  color: var(--gray-900);
  margin-bottom: 4px;
}

.auth-header p {
  color: var(--gray-500);
  font-size: 14px;
}

.auth-form .form-group {
  margin-bottom: 16px;
}

.auth-form label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--gray-700);
  margin-bottom: 6px;
}

.auth-form input[type="text"],
.auth-form input[type="email"],
.auth-form input[type="password"],
.auth-form input[type="tel"],
.auth-form select,
.auth-form textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius-sm);
  font-size: 15px;
  font-family: var(--font);
  color: var(--gray-800);
  background: var(--white);
  transition: border-color 0.2s, box-shadow 0.2s;
  min-height: 48px;
  outline: none;
}

.auth-form input:focus,
.auth-form select:focus,
.auth-form textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(0,178,169,0.12);
}

.input-password {
  position: relative;
}

.input-password input {
  padding-right: 44px;
}

.toggle-pwd {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  font-size: 16px;
  padding: 4px;
  line-height: 1;
}

.btn-primary-full {
  width: 100%;
  padding: 14px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: var(--white);
  border: none;
  border-radius: var(--radius-sm);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.3px;
  min-height: 52px;
  transition: transform 0.15s, box-shadow 0.15s;
  margin-top: 8px;
}

.btn-primary-full:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(0,178,169,0.35);
}

.btn-primary-full:active { transform: translateY(0); }

.auth-footer {
  text-align: center;
  margin-top: 20px;
}

.auth-footer p {
  font-size: 13px;
  color: var(--gray-500);
  margin-bottom: 6px;
}

.auth-footer a {
  color: var(--primary);
  font-weight: 600;
}

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

/* Register page multi-section */
.auth-section-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--gray-500);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  margin: 20px 0 12px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--gray-100);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.form-hint {
  font-size: 11px;
  color: var(--gray-400);
  margin-top: 4px;
}

/* ===================================================
   FLASH MESSAGES
   =================================================== */

.flash {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 16px;
  line-height: 1.4;
}

.flash-success {
  background: var(--success-light);
  color: #065F46;
  border: 1px solid #6EE7B7;
}

.flash-error {
  background: var(--danger-light);
  color: #991B1B;
  border: 1px solid #FCA5A5;
}

.flash-warning {
  background: var(--warning-light);
  color: #92400E;
  border: 1px solid #FCD34D;
}

/* ===================================================
   SUPPLIER PORTAL LAYOUT
   =================================================== */

.supplier-layout {
  display: flex;
  min-height: 100vh;
}

/* Sidebar */
.supplier-sidebar {
  width: var(--sidebar-width);
  background: var(--white);
  border-right: 1px solid var(--gray-200);
  display: none; /* hidden on mobile */
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  z-index: 100;
  overflow-y: auto;
  transition: transform 0.3s ease;
}

.supplier-sidebar.open {
  display: flex;
}

.sidebar-brand {
  padding: 20px 16px;
  border-bottom: 1px solid var(--gray-100);
  display: flex;
  align-items: center;
  gap: 10px;
}

.sidebar-brand-logo {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  object-fit: cover;
}

.sidebar-brand-name {
  font-size: 18px;
  font-weight: 800;
}

.sidebar-brand-name .grab { color: var(--gray-900); }
.sidebar-brand-name .gains { color: var(--primary); }

.sidebar-supplier-info {
  padding: 16px;
  background: var(--primary-light);
  margin: 12px;
  border-radius: var(--radius-md);
}

.sidebar-supplier-name {
  font-size: 13px;
  font-weight: 700;
  color: var(--primary-dark);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sidebar-supplier-role {
  font-size: 11px;
  color: var(--primary);
  font-weight: 500;
}

.sidebar-nav {
  flex: 1;
  padding: 8px 0;
}

.sidebar-section {
  margin-bottom: 4px;
}

.sidebar-section-label {
  font-size: 10px;
  font-weight: 700;
  color: var(--gray-400);
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 8px 16px 4px;
}

.sidebar-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  font-size: 14px;
  font-weight: 500;
  color: var(--gray-600);
  border-radius: 0;
  transition: background 0.15s, color 0.15s;
  min-height: 44px;
}

.sidebar-link:hover {
  background: var(--gray-50);
  color: var(--primary);
}

.sidebar-link.active {
  background: var(--primary-light);
  color: var(--primary-dark);
  font-weight: 600;
  border-right: 3px solid var(--primary);
}

.sidebar-link svg {
  flex-shrink: 0;
  opacity: 0.7;
}

.sidebar-link.active svg { opacity: 1; }

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

.sidebar-logout {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  background: var(--danger-light);
  color: var(--danger);
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  transition: background 0.15s;
}

.sidebar-logout:hover { background: #FCA5A5; }

/* Main content */
.supplier-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding-bottom: var(--bottom-nav-height); /* space for mobile bottom nav */
}

/* Top bar */
.supplier-topbar {
  height: var(--topbar-height);
  background: var(--white);
  border-bottom: 1px solid var(--gray-200);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  position: sticky;
  top: 0;
  z-index: 50;
}

.topbar-menu-btn {
  background: none;
  border: none;
  color: var(--gray-700);
  padding: 8px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
}

.topbar-title {
  font-size: 16px;
  font-weight: 700;
  color: var(--gray-900);
}

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

/* Content area */
.supplier-content {
  padding: 16px;
  flex: 1;
}

/* ===================================================
   MOBILE BOTTOM NAVIGATION
   =================================================== */

.mobile-bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--bottom-nav-height);
  background: var(--white);
  border-top: 1px solid var(--gray-200);
  display: flex;
  align-items: center;
  z-index: 200;
  box-shadow: 0 -4px 20px rgba(0,0,0,0.08);
}

.bottom-nav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 8px 4px;
  color: var(--gray-400);
  font-size: 10px;
  font-weight: 500;
  transition: color 0.15s;
  min-height: 44px;
  text-decoration: none;
}

.bottom-nav-item svg {
  width: 22px;
  height: 22px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
}

.bottom-nav-item.active {
  color: var(--primary);
}

.bottom-nav-item.active svg {
  stroke: var(--primary);
}

/* ===================================================
   FLOATING ACTION BUTTON (FAB)
   =================================================== */

.fab {
  position: fixed;
  bottom: calc(var(--bottom-nav-height) + 16px);
  right: 16px;
  width: 56px;
  height: 56px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(0,178,169,0.45);
  z-index: 150;
  transition: transform 0.2s, box-shadow 0.2s;
  text-decoration: none;
}

.fab:hover {
  transform: scale(1.08);
  box-shadow: 0 6px 20px rgba(0,178,169,0.5);
}

.fab svg {
  width: 24px;
  height: 24px;
  stroke: white;
  fill: none;
  stroke-width: 2.5;
}

/* ===================================================
   STATS GRID
   =================================================== */

.stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 20px;
}

.stat-card {
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 16px;
  box-shadow: var(--shadow-sm);
  border-left: 4px solid var(--primary);
  position: relative;
  overflow: hidden;
  transition: transform 0.15s, box-shadow 0.15s;
}

.stat-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.stat-card-primary { border-left-color: var(--primary); }
.stat-card-success { border-left-color: var(--success); }
.stat-card-accent { border-left-color: var(--accent); }
.stat-card-warning { border-left-color: var(--warning); }
.stat-card-info { border-left-color: var(--info); }

.stat-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--gray-500);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
}

.stat-value {
  font-size: 22px;
  font-weight: 800;
  color: var(--gray-900);
  line-height: 1.1;
  margin-bottom: 4px;
}

.stat-sub {
  font-size: 11px;
  color: var(--gray-400);
}

.stat-emoji {
  position: absolute;
  top: 12px;
  right: 12px;
  font-size: 24px;
  opacity: 0.15;
}

/* ===================================================
   CARDS
   =================================================== */

.supplier-card {
  background: var(--white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  margin-bottom: 16px;
}

.supplier-card-header {
  padding: 16px;
  border-bottom: 1px solid var(--gray-100);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.supplier-card-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--gray-900);
}

.supplier-card-body {
  padding: 16px;
}

/* ===================================================
   PRODUCT CARDS
   =================================================== */

.products-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.product-card {
  background: var(--white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: transform 0.15s, box-shadow 0.15s;
}

.product-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.product-card-img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  background: var(--gray-100);
}

.product-card-placeholder {
  width: 100%;
  aspect-ratio: 1 / 1;
  background: linear-gradient(135deg, var(--gray-100), var(--gray-200));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
}

.product-card-body {
  padding: 10px;
}

.product-card-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--gray-800);
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.product-card-price {
  font-size: 14px;
  font-weight: 800;
  color: var(--primary-dark);
  margin-bottom: 6px;
}

.product-card-stock {
  font-size: 11px;
  color: var(--gray-500);
  margin-bottom: 8px;
}

.product-card-actions {
  display: flex;
  gap: 6px;
}

/* ===================================================
   BUTTONS
   =================================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: all 0.15s;
  min-height: 40px;
  text-decoration: none;
  font-family: var(--font);
  white-space: nowrap;
}

.btn-sm {
  padding: 6px 12px;
  font-size: 12px;
  min-height: 32px;
}

.btn-lg {
  padding: 14px 24px;
  font-size: 16px;
  min-height: 52px;
}

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

.btn-primary:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,178,169,0.3);
}

.btn-accent {
  background: var(--accent);
  color: var(--white);
}

.btn-accent:hover {
  background: #E05A00;
  transform: translateY(-1px);
}

.btn-outline {
  background: transparent;
  border: 1.5px solid var(--gray-300);
  color: var(--gray-700);
}

.btn-outline:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-light);
}

.btn-danger {
  background: var(--danger);
  color: var(--white);
}

.btn-danger:hover {
  background: #DC2626;
}

.btn-ghost {
  background: transparent;
  color: var(--gray-600);
  padding: 8px;
}

.btn-ghost:hover {
  background: var(--gray-100);
  color: var(--gray-900);
}

.btn-success {
  background: var(--success);
  color: var(--white);
}

.btn-warning {
  background: var(--warning);
  color: var(--white);
}

.btn-full { width: 100%; }

/* ===================================================
   STATUS BADGES
   =================================================== */

.badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.3px;
  text-transform: capitalize;
}

.badge-pending {
  background: var(--warning-light);
  color: #92400E;
}

.badge-approved {
  background: var(--success-light);
  color: #065F46;
}

.badge-rejected {
  background: var(--danger-light);
  color: #991B1B;
}

.badge-suspended {
  background: var(--gray-100);
  color: var(--gray-600);
}

.badge-active {
  background: var(--success-light);
  color: #065F46;
}

.badge-inactive {
  background: var(--gray-100);
  color: var(--gray-500);
}

/* order status badges */
.badge-confirmed { background: var(--primary-light); color: var(--primary-dark); }
.badge-processing { background: var(--info-light); color: #1D4ED8; }
.badge-shipped { background: var(--warning-light); color: #92400E; }
.badge-delivered { background: var(--success-light); color: #065F46; }
.badge-cancelled { background: var(--danger-light); color: #991B1B; }

/* ===================================================
   FORMS (portal forms)
   =================================================== */

.form-group {
  margin-bottom: 16px;
}

.form-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--gray-700);
  margin-bottom: 6px;
}

.form-label .optional {
  font-weight: 400;
  color: var(--gray-400);
  font-size: 11px;
  margin-left: 4px;
}

.form-control {
  width: 100%;
  padding: 11px 13px;
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius-sm);
  font-size: 15px;
  font-family: var(--font);
  color: var(--gray-800);
  background: var(--white);
  transition: border-color 0.2s, box-shadow 0.2s;
  min-height: 46px;
  outline: none;
  appearance: none;
  -webkit-appearance: none;
}

.form-control:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(0,178,169,0.12);
}

.form-control::placeholder { color: var(--gray-300); }

textarea.form-control {
  min-height: 100px;
  resize: vertical;
}

select.form-control {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='none' viewBox='0 0 24 24'%3E%3Cpath stroke='%236B7280' stroke-width='2' d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
}

/* Checkboxes */
.checkbox-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.checkbox-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 13px;
  border: 1.5px solid var(--gray-200);
  border-radius: 20px;
  font-size: 13px;
  font-weight: 500;
  color: var(--gray-700);
  cursor: pointer;
  transition: all 0.15s;
  min-height: 36px;
}

.checkbox-chip input[type="checkbox"] {
  display: none;
}

.checkbox-chip:has(input:checked),
.checkbox-chip.selected {
  background: var(--primary-light);
  border-color: var(--primary);
  color: var(--primary-dark);
}
.variant-suggestion-title {
  font-size: 11px;
  font-weight: 700;
  color: var(--gray-500);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
}
.variant-chip-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

/* Image upload */
.image-upload-area {
  border: 2px dashed var(--gray-300);
  border-radius: var(--radius-md);
  padding: 24px;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}

.image-upload-area:hover {
  border-color: var(--primary);
  background: var(--primary-light);
}

.image-upload-area input[type="file"] {
  display: none;
}

.image-upload-icon { font-size: 32px; margin-bottom: 8px; }
.image-upload-text { font-size: 14px; color: var(--gray-500); }
.image-upload-hint { font-size: 11px; color: var(--gray-400); margin-top: 4px; }

.image-previews {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 12px;
}

.image-preview-item {
  position: relative;
  aspect-ratio: 1;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--gray-200);
}

.image-preview-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.image-preview-remove {
  position: absolute;
  top: 4px;
  right: 4px;
  background: rgba(239,68,68,0.9);
  color: white;
  border: none;
  border-radius: 50%;
  width: 22px;
  height: 22px;
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  line-height: 1;
}

/* ===================================================
   TABLE
   =================================================== */

.table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

table.supplier-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

table.supplier-table th {
  background: var(--gray-50);
  padding: 10px 12px;
  text-align: left;
  font-size: 11px;
  font-weight: 700;
  color: var(--gray-500);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 1px solid var(--gray-200);
  white-space: nowrap;
}

table.supplier-table td {
  padding: 12px;
  border-bottom: 1px solid var(--gray-100);
  vertical-align: middle;
  color: var(--gray-700);
}

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

table.supplier-table tr:hover td { background: var(--gray-50); }

/* ===================================================
   ORDER CARDS (mobile-friendly)
   =================================================== */

.order-card {
  background: var(--white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  padding: 16px;
  margin-bottom: 12px;
  border-left: 4px solid var(--primary);
}

.order-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 10px;
  gap: 8px;
}

.order-number {
  font-size: 14px;
  font-weight: 800;
  color: var(--primary);
}

.order-customer {
  font-size: 13px;
  color: var(--gray-600);
  margin-top: 2px;
}

.order-date {
  font-size: 11px;
  color: var(--gray-400);
  text-align: right;
}

.order-items-list {
  margin: 10px 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.order-item-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--gray-600);
}

.order-item-img {
  width: 36px;
  height: 36px;
  border-radius: 6px;
  object-fit: cover;
  background: var(--gray-100);
  flex-shrink: 0;
}

.order-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 10px;
  border-top: 1px solid var(--gray-100);
  gap: 8px;
}

.order-total {
  font-size: 15px;
  font-weight: 800;
  color: var(--gray-900);
}

/* ===================================================
   STATUS FILTER TABS
   =================================================== */

.status-tabs {
  display: flex;
  gap: 4px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 2px;
  margin-bottom: 16px;
  scrollbar-width: none;
}

.status-tabs::-webkit-scrollbar { display: none; }

.status-tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  border: 1.5px solid var(--gray-200);
  color: var(--gray-600);
  background: var(--white);
  text-decoration: none;
  transition: all 0.15s;
  min-height: 36px;
}

.status-tab:hover {
  border-color: var(--primary);
  color: var(--primary);
}

.status-tab.active {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--white);
}

.tab-count {
  background: rgba(255,255,255,0.3);
  border-radius: 10px;
  padding: 1px 6px;
  font-size: 11px;
}

.status-tab:not(.active) .tab-count {
  background: var(--gray-100);
  color: var(--gray-500);
}

/* ===================================================
   SEARCH BAR
   =================================================== */

.search-bar {
  position: relative;
  margin-bottom: 16px;
}

.search-bar input {
  width: 100%;
  padding: 11px 16px 11px 40px;
  border: 1.5px solid var(--gray-200);
  border-radius: 24px;
  font-size: 14px;
  font-family: var(--font);
  background: var(--white);
  outline: none;
  transition: border-color 0.2s;
  min-height: 46px;
}

.search-bar input:focus { border-color: var(--primary); }

.search-bar-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--gray-400);
  pointer-events: none;
}

/* ===================================================
   PENDING / REJECTION PAGE
   =================================================== */

.pending-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: var(--gray-50);
}

.pending-card {
  background: var(--white);
  border-radius: var(--radius-xl);
  padding: 40px 32px;
  max-width: 480px;
  width: 100%;
  text-align: center;
  box-shadow: var(--shadow-lg);
}

.pending-icon {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
  font-size: 36px;
}

.pending-icon-yellow { background: var(--warning-light); }
.pending-icon-red { background: var(--danger-light); }

.pending-card h1 {
  font-size: 22px;
  font-weight: 800;
  color: var(--gray-900);
  margin-bottom: 8px;
}

.pending-card p {
  font-size: 14px;
  color: var(--gray-500);
  line-height: 1.6;
  margin-bottom: 16px;
}

.pending-status-badge {
  display: inline-block;
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 20px;
}

.rejection-reason-box {
  background: var(--danger-light);
  border: 1px solid #FCA5A5;
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  text-align: left;
  margin-bottom: 20px;
}

.rejection-reason-box strong {
  display: block;
  font-size: 12px;
  color: #991B1B;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 4px;
}

.rejection-reason-box p {
  color: #7F1D1D;
  font-size: 14px;
  margin: 0;
}

/* ===================================================
   PROFILE PAGE
   =================================================== */

.profile-header {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  border-radius: var(--radius-lg);
  padding: 24px;
  color: var(--white);
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.profile-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: rgba(255,255,255,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  font-weight: 800;
  color: white;
  flex-shrink: 0;
}

.profile-name {
  font-size: 18px;
  font-weight: 800;
}

.profile-email {
  font-size: 13px;
  opacity: 0.8;
  margin-top: 2px;
}

.form-section-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--gray-500);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--gray-100);
  margin-bottom: 16px;
  margin-top: 4px;
}

/* ===================================================
   QUICK ACTIONS
   =================================================== */

.quick-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 20px;
}

.quick-action-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px 12px;
  background: var(--white);
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius-md);
  color: var(--gray-700);
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.15s;
  min-height: 72px;
  text-align: center;
}

.quick-action-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-light);
}

.quick-action-icon { font-size: 24px; }

/* ===================================================
   PAGINATION
   =================================================== */

.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 16px 0;
}

.page-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  border: 1.5px solid var(--gray-200);
  color: var(--gray-600);
  text-decoration: none;
  transition: all 0.15s;
}

.page-btn:hover,
.page-btn.active {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--white);
}

.page-btn.disabled {
  opacity: 0.4;
  pointer-events: none;
}

/* ===================================================
   EMPTY STATES
   =================================================== */

.empty-state {
  text-align: center;
  padding: 40px 20px;
  color: var(--gray-400);
}

.empty-state-icon { font-size: 48px; margin-bottom: 12px; }

.empty-state h3 {
  font-size: 16px;
  font-weight: 700;
  color: var(--gray-600);
  margin-bottom: 6px;
}

.empty-state p { font-size: 13px; }

/* ===================================================
   DETAIL ROWS (profile/supplier info)
   =================================================== */

.detail-row {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--gray-100);
}

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

.detail-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--gray-400);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  min-width: 100px;
  flex-shrink: 0;
  padding-top: 2px;
}

.detail-value {
  font-size: 14px;
  color: var(--gray-800);
  font-weight: 500;
}

/* ===================================================
   DESKTOP (>= 768px) — show sidebar, hide bottom nav
   =================================================== */

@media (min-width: 768px) {
  .supplier-sidebar {
    display: flex;
    position: fixed;
    height: 100vh;
  }

  .supplier-main {
    margin-left: var(--sidebar-width);
    padding-bottom: 0;
  }

  .mobile-bottom-nav {
    display: none;
  }

  .fab {
    bottom: 24px;
    right: 24px;
    width: 52px;
    height: 52px;
  }

  .supplier-content {
    padding: 24px;
  }

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

  .products-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
  }

  .quick-actions {
    grid-template-columns: repeat(4, 1fr);
  }

  .form-row {
    grid-template-columns: 1fr 1fr;
  }

  .auth-card {
    padding: 40px 40px;
  }

  .topbar-menu-btn {
    display: none;
  }
}

@media (min-width: 1024px) {
  .products-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .supplier-content {
    max-width: none;
    width: 100%;
  }
}

/* ===================================================
   UTILITY
   =================================================== */

.text-primary { color: var(--primary); }
.text-success { color: var(--success); }
.text-danger { color: var(--danger); }
.text-warning { color: var(--warning); }
.text-muted { color: var(--gray-400); }
.text-bold { font-weight: 700; }
.text-sm { font-size: 13px; }
.text-xs { font-size: 11px; }
.mt-1 { margin-top: 4px; }
.mt-2 { margin-top: 8px; }
.mt-3 { margin-top: 12px; }
.mt-4 { margin-top: 16px; }
.mb-1 { margin-bottom: 4px; }
.mb-2 { margin-bottom: 8px; }
.mb-3 { margin-bottom: 12px; }
.mb-4 { margin-bottom: 16px; }
.flex { display: flex; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-2 { gap: 8px; }
.gap-3 { gap: 12px; }
.hidden { display: none !important; }
.w-full { width: 100%; }
