/* ProzPart - Professional Dark Theme */

:root {
  /* Dark Theme Colors */
  --bg-primary: #0f1419;
  --bg-secondary: #1a1f2e;
  --bg-tertiary: #252b3b;
  --bg-card: #1e2530;
  --bg-card-hover: #252b3b;

  /* Accent Colors */
  --accent-primary: #c2410c;
  --accent-secondary: #ea580c;
  --accent-gradient: #c2410c;
  --accent-gradient-2: #c2410c;

  /* Text Colors */
  --text-primary: #e5e7eb;
  --text-secondary: #9ca3af;
  --text-muted: #6b7280;

  /* Status Colors */
  --success: #10b981;
  --warning: #f59e0b;
  --error: #ef4444;
  --info: #c2410c;

  /* Shadows & Effects */
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.2);
  --shadow-md: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 4px 16px rgba(0, 0, 0, 0.4);
  --shadow-glow: 0 0 0 1px rgba(194, 65, 12, 0.3);
  --shadow-glow-purple: 0 0 0 1px rgba(194, 65, 12, 0.3);

  /* Border Radius */
  --radius-sm: 4px;
  --radius-md: 6px;
  --radius-lg: 8px;
  --radius-xl: 12px;

  /* Transitions */
  --transition-fast: 0.15s ease;
  --transition-normal: 0.2s ease;
  --transition-slow: 0.3s ease;
}

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  padding: 20px;
  min-height: 100vh;
  background-image:
    radial-gradient(circle at 20% 50%, rgba(194, 65, 12, 0.08) 0%, transparent 50%),
    radial-gradient(circle at 80% 50%, rgba(234, 88, 12, 0.08) 0%, transparent 50%);
}

.container {
  max-width: 1800px;
  margin: 0 auto;
  width: 100%;
  padding: 0 20px;
  box-sizing: border-box;
}

/* Header */
header {
  margin-bottom: 48px;
  animation: fadeInDown var(--transition-slow);
}

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

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
}

.header-content > div:first-child {
  text-align: left;
  flex: 1;
}

.cart-selector-container {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 0 auto 16px;
  max-width: 350px;
}

.vendor-selector-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin: 0 auto 32px;
  max-width: 800px;
}

.vendor-checkboxes {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}

.vendor-checkbox-label {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  padding: 8px 16px;
  background: var(--bg-secondary);
  border: 2px solid rgba(194, 65, 12, 0.3);
  border-radius: var(--radius-md);
  transition: all var(--transition-normal);
  user-select: none;
}

.vendor-checkbox-label:hover {
  border-color: var(--accent-primary);
  background: var(--bg-tertiary);
}

.vendor-checkbox-label input[type="checkbox"] {
  width: 18px;
  height: 18px;
  cursor: pointer;
  accent-color: var(--accent-primary);
}

.vendor-checkbox-label span {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
}

/* Cart Selector in Header */
.cart-selector-container-header {
  display: flex;
  align-items: center;
  gap: 6px;
}

.cart-selector-header {
  flex: 1;
  padding: 11px 16px;
  font-size: 0.9rem;
  font-weight: 600;
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 2px solid rgba(194, 65, 12, 0.3);
  border-radius: var(--radius-md);
  outline: none;
  cursor: pointer;
  transition: all var(--transition-normal);
  box-shadow: var(--shadow-sm);
  min-width: 250px;
}

.cart-selector-header:hover {
  border-color: var(--accent-primary);
  box-shadow: var(--shadow-glow);
}

.cart-selector-header:focus {
  border-color: var(--accent-primary);
  box-shadow: var(--shadow-glow);
}

.cart-selector-header option[value="__new__"] {
  color: var(--accent-primary);
  font-weight: 700;
}

/* Cart Action Buttons (New/Edit/Delete) */
.cart-action-btn {
  padding: 8px;
  width: 32px;
  height: 32px;
  background: var(--bg-secondary);
  color: var(--text-secondary);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
}

.cart-action-btn:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.cart-action-btn-new {
  background: var(--accent-primary);
  color: white;
  border-color: var(--accent-primary);
}

.cart-action-btn-new:hover {
  background: var(--accent-secondary);
  color: white;
  border-color: var(--accent-secondary);
}

.cart-action-btn-danger {
  color: #ef4444;
  border-color: rgba(239, 68, 68, 0.2);
}

.cart-action-btn-danger:hover {
  background: rgba(239, 68, 68, 0.1);
  color: #ef4444;
  border-color: rgba(239, 68, 68, 0.4);
}

.cart-selector {
  padding: 10px 16px;
  font-size: 0.95rem;
  font-weight: 600;
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 2px solid rgba(194, 65, 12, 0.3);
  border-radius: var(--radius-md);
  outline: none;
  cursor: pointer;
  transition: all var(--transition-normal);
  width: 300px !important;
  max-width: 300px !important;
  flex-shrink: 0;
}

.cart-selector:hover {
  border-color: var(--accent-primary);
  box-shadow: var(--shadow-glow);
}

.cart-selector:focus {
  border-color: var(--accent-primary);
  box-shadow: var(--shadow-glow);
}

.new-cart-btn {
  padding: 10px 16px;
  font-size: 1.1rem;
  font-weight: 600;
  background: var(--accent-primary);
  color: white;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  box-shadow: var(--shadow-sm);
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.new-cart-btn:hover {
  background: var(--accent-secondary);
  box-shadow: var(--shadow-md);
}

header h1 {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}

header p {
  color: var(--text-secondary);
  font-size: 1.2rem;
  font-weight: 500;
}

/* Professional Header Action Buttons */
.header-action-btn {
  position: relative;
  padding: 11px 20px;
  font-size: 0.9rem;
  font-weight: 600;
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: var(--shadow-sm);
}

.header-action-btn:hover {
  background: var(--bg-tertiary);
  border-color: var(--accent-primary);
  color: var(--accent-primary);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.header-action-btn:active {
  transform: translateY(0);
}

.header-action-btn svg {
  flex-shrink: 0;
}

/* Small Header Action Buttons (Profile) */
.header-action-btn-small {
  position: relative;
  padding: 8px 14px;
  font-size: 0.8rem;
  font-weight: 600;
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  display: flex;
  align-items: center;
  gap: 6px;
  box-shadow: var(--shadow-sm);
}

.header-action-btn-small:hover {
  background: var(--bg-tertiary);
  border-color: var(--accent-primary);
  color: var(--accent-primary);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.header-action-btn-small:active {
  transform: translateY(0);
}

.header-action-btn-small svg {
  flex-shrink: 0;
}

/* Profile Button */
.btn-profile {
  position: relative;
  padding: 8px;
  width: 36px;
  height: 36px;
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
}

.btn-profile:hover {
  background: var(--bg-tertiary);
  border-color: var(--accent-primary);
  color: var(--accent-primary);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.btn-profile.incomplete {
  border-color: rgba(194, 65, 12, 0.5);
}

/* Warning Badge Notification */
.warning-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  background: #c2410c;
  color: white;
  font-size: 10px;
  font-weight: 700;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
  animation: pulse-badge 2s infinite;
}

@keyframes pulse-badge {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
  }
  50% {
    transform: scale(1.1);
    box-shadow: 0 2px 8px rgba(194, 65, 12, 0.5);
  }
}

/* Small Power Button (Logout) */
.header-power-btn-small {
  padding: 8px;
  width: 36px;
  height: 36px;
  font-size: 0.8rem;
  font-weight: 600;
  background: rgba(239, 68, 68, 0.1);
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.3);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
}

.header-power-btn-small:hover {
  background: rgba(239, 68, 68, 0.2);
  border-color: #ef4444;
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.header-power-btn-small:active {
  transform: translateY(0);
}

.header-power-btn-small svg {
  flex-shrink: 0;
}

/* Small Login Button */
.header-login-btn-small {
  padding: 8px 14px;
  font-size: 0.8rem;
  font-weight: 600;
  background: var(--accent-primary);
  color: white;
  border: 1px solid var(--accent-secondary);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  display: flex;
  align-items: center;
  gap: 6px;
  box-shadow: var(--shadow-sm);
}

.header-login-btn-small:hover {
  background: var(--accent-secondary);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.header-login-btn-small:active {
  transform: translateY(0);
}

.header-login-btn-small svg {
  flex-shrink: 0;
}

/* Power Button (Logout) - Legacy */
.header-power-btn {
  padding: 11px;
  width: 44px;
  height: 44px;
  font-size: 0.9rem;
  font-weight: 600;
  background: rgba(239, 68, 68, 0.1);
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.3);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
}

.header-power-btn:hover {
  background: rgba(239, 68, 68, 0.2);
  border-color: #ef4444;
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.header-power-btn:active {
  transform: translateY(0);
}

.header-power-btn svg {
  flex-shrink: 0;
}

/* Legacy Logout Button - keep for compatibility */
.header-logout-btn {
  padding: 11px 18px;
  font-size: 0.9rem;
  font-weight: 600;
  background: rgba(239, 68, 68, 0.1);
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.3);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: var(--shadow-sm);
}

.header-logout-btn:hover {
  background: rgba(239, 68, 68, 0.2);
  border-color: #ef4444;
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.header-logout-btn:active {
  transform: translateY(0);
}

.header-logout-btn svg {
  flex-shrink: 0;
}

/* Login Button */
.header-login-btn {
  padding: 11px 18px;
  font-size: 0.9rem;
  font-weight: 600;
  background: var(--accent-primary);
  color: white;
  border: 1px solid var(--accent-secondary);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: var(--shadow-sm);
}

.header-login-btn:hover {
  background: var(--accent-secondary);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.header-login-btn:active {
  transform: translateY(0);
}

.header-login-btn svg {
  flex-shrink: 0;
}

/* Legacy support - keep for other pages */
.cart-header-btn {
  position: relative;
  padding: 10px 20px;
  font-size: 0.95rem;
  font-weight: 600;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.15) 0%, rgba(194, 65, 12, 0.15) 100%);
  backdrop-filter: blur(15px) saturate(180%);
  -webkit-backdrop-filter: blur(15px) saturate(180%);
  color: var(--accent-primary);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-top: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2),
              inset 0 1px 0 rgba(255, 255, 255, 0.3),
              0 4px 8px rgba(194, 65, 12, 0.15);
}

.cart-header-btn:hover {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.2) 0%, rgba(194, 65, 12, 0.25) 100%);
  border-color: rgba(255, 255, 255, 0.4);
  border-top-color: rgba(255, 255, 255, 0.6);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.25),
              inset 0 1px 0 rgba(255, 255, 255, 0.4),
              0 6px 12px rgba(194, 65, 12, 0.25);
  transform: translateY(-2px);
}

.cart-header-btn:active {
  transform: scale(0.98);
}

.btn-icon {
  display: inline-flex;
  align-items: center;
}

.cart-badge {
  background: var(--error);
  color: white;
  border-radius: 50%;
  padding: 2px 8px;
  font-size: 0.85rem;
  font-weight: 700;
  min-width: 24px;
  text-align: center;
}

.cart-badge-small {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--error);
  color: white;
  border-radius: 50%;
  padding: 1px 5px;
  font-size: 0.65rem;
  font-weight: 700;
  min-width: 16px;
  text-align: center;
}

#cart-btn {
  position: relative;
}

.cart-btn-icon {
  padding: 10px;
  width: 42px;
  height: 42px;
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 2px solid rgba(194, 65, 12, 0.3);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
  position: relative;
}

.cart-btn-icon:hover {
  background: var(--bg-tertiary);
  border-color: var(--accent-primary);
  color: var(--accent-primary);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

/* Search Section */
.search-section {
  display: flex;
  gap: 16px;
  max-width: 600px;
  margin: 0 auto 48px;
  animation: fadeIn var(--transition-slow) 0.2s;
}

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

#sku {
  flex: 1;
  padding: 16px 20px;
  font-size: 1.1rem;
  font-weight: 500;
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 2px solid transparent;
  border-radius: var(--radius-md);
  outline: none;
  transition: all var(--transition-normal);
  box-shadow: var(--shadow-sm);
}

#sku:focus {
  border-color: var(--accent-primary);
  box-shadow: var(--shadow-glow);
  transform: translateY(-2px);
}

#sku::placeholder {
  color: var(--text-muted);
}

#compare-btn {
  padding: 14px 28px;
  font-size: 1rem;
  font-weight: 600;
  background: var(--accent-primary);
  color: white;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  box-shadow: var(--shadow-sm);
}

#compare-btn:hover:not(:disabled) {
  background: var(--accent-secondary);
  box-shadow: var(--shadow-md);
}

#compare-btn:disabled {
  background: var(--bg-tertiary);
  color: var(--text-muted);
  cursor: not-allowed;
  opacity: 0.5;
}

/* Results Grid */
.results-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 48px;
  animation: fadeIn var(--transition-slow) 0.3s;
  align-items: start;
  width: 100%;
}

.vendor-card {
  background: var(--bg-secondary);
  border-radius: 12px;
  padding: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  transition: all 0.2s ease;
  border: 1px solid rgba(255, 255, 255, 0.08);
  position: relative;
  min-width: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.vendor-card:hover {
  border-color: rgba(194, 65, 12, 0.3);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.vendor-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
  padding-bottom: 8px;
  border-bottom: 2px solid rgba(194, 65, 12, 0.3);
  min-height: 40px;
}

.vendor-header h2 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: -0.01em;
}

.vendor-header .status-container {
  display: flex;
  align-items: center;
}

.vendor-header .status-text {
  font-size: 0.75rem;
  padding: 4px 10px;
  margin: 0;
  border-radius: 4px;
  font-weight: 600;
  background: rgba(16, 185, 129, 0.15);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.vendor-header .status-btn {
  font-size: 0.75rem;
  padding: 4px 12px;
  margin: 0;
  border-radius: 4px;
  font-weight: 600;
  background: var(--accent-primary);
  color: white;
  border: none;
  cursor: pointer;
  transition: all var(--transition-fast);
  box-shadow: var(--shadow-sm);
}

.vendor-header .status-btn:hover {
  background: var(--accent-secondary);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.vendor-card-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 8px;
  min-width: 0;
  overflow: hidden;
  flex: 1;
  align-content: start;
}

.vendor-card-left {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
}

.vendor-card-right {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
  overflow: hidden;
  justify-content: space-between;
  min-height: 160px;
}

.stock-add-row {
  grid-column: 1 / -1;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 80px;
  width: 100%;
  min-height: 36px;
}

.price-qty-row {
  display: flex;
  align-items: center;
  gap: 16px;
  justify-content: space-between;
}

.stock-cart-row {
  display: flex;
  align-items: center;
  gap: 16px;
  justify-content: space-between;
}

.connection-badge {
  font-size: 1.3rem;
  cursor: help;
  transition: all var(--transition-fast);
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.connection-badge:hover {
  transform: scale(1.2);
}

.btn-connect {
  width: 100%;
  padding: 8px 16px;
  margin-bottom: 8px;
  font-size: 1rem;
  font-weight: 700;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  min-height: 40px;
  box-shadow: var(--shadow-sm);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.btn-connect.red {
  background: #dc2626;
  color: #fff;
}

.btn-connect.red:hover {
  background: #b91c1c;
}

.btn-connect.green {
  background: #10b981;
  color: #fff;
}

.btn-connect.green:hover:not(:disabled) {
  background: #059669;
}

.btn-connect.green:disabled {
  background: #10b981;
  opacity: 0.7;
  cursor: default;
}

.btn-connect.loading {
  opacity: 0.7;
  cursor: wait;
  background: var(--bg-tertiary);
  color: var(--text-secondary);
}

.status {
  font-size: 0.9rem;
  padding: 6px 12px;
  margin-bottom: 8px;
  border-radius: var(--radius-sm);
  background: var(--bg-secondary);
  color: var(--text-secondary);
  font-weight: 500;
  min-height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.status-ok {
  background: rgba(16, 185, 129, 0.15);
  color: var(--success);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.status-warning {
  background: rgba(245, 158, 11, 0.15);
  color: var(--warning);
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.status-error {
  background: rgba(239, 68, 68, 0.15);
  color: var(--error);
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.product-image-link {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  text-align: center;
  transition: transform var(--transition-normal);
  border-radius: var(--radius-md);
  overflow: hidden;
  width: 160px;
  height: 160px;
  min-width: 160px;
  min-height: 160px;
  max-width: 160px;
  max-height: 160px;
}

.product-image-link:hover {
  transform: scale(1.05);
}

.product-image {
  width: 160px;
  height: 160px;
  min-width: 160px;
  min-height: 160px;
  max-width: 160px;
  max-height: 160px;
  object-fit: contain;
  border-radius: var(--radius-md);
  background: white;
  padding: 12px;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-normal);
  display: block;
  margin: auto;
}

.product-image:hover {
  box-shadow: var(--shadow-md);
}

.product-title {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-primary);
  margin: 0;
  padding: 0;
  text-align: left;
  line-height: 1.3;
  height: 2.6em;
  min-height: 2.6em;
  max-height: 2.6em;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  word-wrap: break-word;
  word-break: break-word;
  overflow-wrap: break-word;
}

.product-sku {
  font-size: 0.7rem;
  color: var(--text-muted);
  margin: 0;
  padding: 0;
  text-align: left;
  font-weight: 500;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  display: block;
  word-wrap: break-word;
  word-break: break-word;
  overflow-wrap: break-word;
  height: 1.2em;
  min-height: 1.2em;
  max-height: 1.2em;
  line-height: 1.2;
}

.price-display {
  font-size: 1.5rem;
  font-weight: 700;
  color: #10b981;
  margin: 24px 0 0 0;
  height: 40px;
  min-height: 40px;
  max-height: 40px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
}

.availability-display {
  font-size: 0.7rem;
  color: var(--text-primary);
  margin: 0;
  padding: 4px 10px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 4px;
  text-align: center;
  font-weight: 600;
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  height: 28px;
  min-height: 28px;
  max-height: 28px;
  white-space: nowrap;
}

.availability-display.in-stock {
  background: rgba(16, 185, 129, 0.1);
  color: #10b981;
  border-color: rgba(16, 185, 129, 0.2);
}

.availability-display.low-stock {
  background: rgba(245, 158, 11, 0.1);
  color: #f59e0b;
  border-color: rgba(245, 158, 11, 0.2);
}

.availability-display.out-of-stock {
  background: rgba(239, 68, 68, 0.1);
  color: #ef4444;
  border-color: rgba(239, 68, 68, 0.2);
}

.quantity-selector {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  margin: 4px 0 0 0;
  width: 100%;
  height: 22px;
  min-height: 22px;
  max-height: 22px;
}

.qty-input {
  width: 28px;
  padding: 1px 2px;
  font-size: 0.65rem;
  font-weight: 600;
  text-align: center;
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 3px;
  outline: none;
  transition: border-color 0.2s ease;
}

.qty-input:focus {
  border-color: var(--accent-primary);
}

.qty-btn {
  width: 18px;
  height: 18px;
  font-size: 0.65rem;
  font-weight: 600;
  background: rgba(194, 65, 12, 0.15);
  color: #888;
  border: 1px solid rgba(136, 136, 136, 0.5);
  border-radius: 3px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.qty-btn:hover {
  background: rgba(194, 65, 12, 0.25);
  border-color: rgba(136, 136, 136, 0.8);
}

.qty-btn:active {
  transform: scale(0.95);
}

.product-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-top: 16px;
}

.cart-add-btn, .cart-remove-btn {
  font-size: 0.9rem;
  padding: 8px 16px;
  border: 2px solid;
  background: rgba(16, 185, 129, 0.1);
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s ease;
  width: auto;
  font-weight: 600;
  height: 36px;
  min-height: 36px;
  max-height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cart-add-btn {
  border-color: rgba(16, 185, 129, 0.5);
  color: #10b981;
}

.cart-add-btn:not(:disabled):hover {
  background: rgba(16, 185, 129, 0.25);
  border-color: #10b981;
  border-color: rgba(16, 185, 129, 0.5);
}

.cart-add-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.cart-remove-btn {
  border-color: rgba(239, 68, 68, 0.3);
  color: #ef4444;
}

.cart-remove-btn:not(:disabled):hover {
  background: rgba(239, 68, 68, 0.15);
  border-color: rgba(239, 68, 68, 0.5);
}

.cart-remove-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

/* Loading Spinner */
.loading {
  text-align: center;
  padding: 60px;
}

.spinner {
  width: 60px;
  height: 60px;
  margin: 0 auto 24px;
  border: 4px solid var(--bg-tertiary);
  border-top: 4px solid var(--accent-primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  box-shadow: var(--shadow-glow);
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.loading p {
  color: var(--text-secondary);
  font-size: 1.2rem;
  font-weight: 600;
}

/* Modal */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(8px);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
  animation: fadeIn var(--transition-fast);
}

.modal-content {
  background: var(--bg-secondary);
  border-radius: var(--radius-xl);
  width: 90%;
  max-width: 900px;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-lg);
  border: 1px solid rgba(255, 255, 255, 0.1);
  animation: slideUp var(--transition-normal);
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.modal-content-wide {
  max-width: 1400px;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 24px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: var(--bg-secondary);
}



.modal-header h2 {
  margin: 0;
  color: var(--text-primary);
  font-size: 1.4rem;
  font-weight: 700;
}

#cart-client-name {
  color: #fbbf24;
  font-weight: 700;
}

.modal-close {
  background: transparent;
  border: none;
  font-size: 1.8rem;
  color: var(--text-muted);
  cursor: pointer;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
}

.modal-close:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-primary);
}

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

.modal-footer {
  padding: 24px 28px;
  border-top: 2px solid rgba(255, 255, 255, 0.05);
  background: var(--bg-tertiary);
  display: flex;
  justify-content: flex-end;
  gap: 12px;
}

/* Modal Form Buttons */
.btn-primary {
  padding: 12px 24px;
  font-size: 0.95rem;
  font-weight: 600;
  background: var(--accent-primary);
  color: white;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  box-shadow: var(--shadow-sm);
}

.btn-primary:hover {
  background: var(--accent-secondary);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn-secondary {
  padding: 12px 24px;
  font-size: 0.95rem;
  font-weight: 600;
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  box-shadow: var(--shadow-sm);
}

.btn-secondary:hover {
  background: var(--bg-tertiary);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

/* Form Group Styles for Modal */
.modal-body .form-group {
  margin-bottom: 20px;
}

.modal-body .form-group label {
  display: block;
  margin-bottom: 8px;
  color: var(--text-primary);
  font-weight: 600;
  font-size: 0.9rem;
}

.modal-body .form-group input,
.modal-body .form-group textarea {
  width: 100%;
  padding: 12px 16px;
  background: var(--bg-tertiary);
  color: var(--text-primary);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  font-size: 0.95rem;
  font-family: inherit;
  transition: all var(--transition-normal);
}

.modal-body .form-group input:focus,
.modal-body .form-group textarea:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 1px rgba(194, 65, 12, 0.3);
}

.modal-body .form-group textarea {
  resize: vertical;
  min-height: 80px;
}

.cart-summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
}

.cart-total-info {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.cart-total-items {
  font-size: 1.1rem;
  color: var(--text-secondary);
  font-weight: 600;
}

.cart-total-global {
  font-size: 2rem;
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 900;
}

.cart-actions-bottom {
  display: flex;
  gap: 16px;
}

.btn-export, .btn-checkout {
  padding: 14px 28px;
  font-size: 1.1rem;
  font-weight: 700;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  box-shadow: var(--shadow-sm);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

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

.btn-export:hover {
  background: var(--accent-secondary);
}

.btn-checkout {
  background: #10b981;
  color: white;
}

.btn-checkout:hover {
  background: #059669;
}

/* Refresh Prices Button */
.btn-refresh-prices {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 24px;
  font-size: 1rem;
  font-weight: 600;
  background: var(--bg-tertiary);
  color: var(--text-primary);
  border: 2px solid rgba(194, 65, 12, 0.3);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  box-shadow: var(--shadow-sm);
}

.btn-refresh-prices:hover {
  background: var(--bg-secondary);
  border-color: var(--accent-primary);
  color: var(--accent-primary);
  box-shadow: var(--shadow-md);
}

.btn-refresh-prices:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn-refresh-prices.loading svg {
  animation: spin 1s linear infinite;
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* Cart Grid */
#cart-items-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 28px;
}

.vendor-cart-column {
  background: var(--bg-card);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-lg);
  padding: 20px;
  backdrop-filter: blur(10px);
}

.vendor-cart-header {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 2px solid rgba(255, 255, 255, 0.05);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.vendor-cart-count {
  font-size: 1rem;
  color: var(--text-muted);
  font-weight: 600;
}

.vendor-cart-items {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 20px;
}

.vendor-cart-footer {
  padding-top: 20px;
  border-top: 2px solid rgba(255, 255, 255, 0.05);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.vendor-subtotal {
  font-size: 1.5rem;
  font-weight: 800;
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-align: right;
}

.btn-vendor-checkout {
  width: 100%;
  padding: 12px 20px;
  font-size: 1rem;
  font-weight: 700;
  background: var(--accent-gradient-2);
  color: white;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  box-shadow: var(--shadow-sm);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.btn-vendor-checkout:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md), var(--shadow-glow);
}

/* Cart Items */
.cart-item {
  display: flex;
  gap: 20px;
  padding: 20px;
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  align-items: center;
  transition: all var(--transition-fast);
  border: 1px solid rgba(255, 255, 255, 0.03);
}

.cart-item:hover {
  background: var(--bg-tertiary);
  border-color: rgba(0, 217, 255, 0.2);
  transform: translateX(4px);
}

.cart-item-clickable {
  display: flex;
  gap: 20px;
  flex: 1;
  text-decoration: none;
  color: inherit;
  align-items: center;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.cart-item-clickable:hover {
  opacity: 0.9;
}

.cart-item-image {
  width: 90px;
  height: 90px;
  object-fit: contain;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.03);
  padding: 8px;
  box-shadow: var(--shadow-sm);
}

.cart-item-info {
  flex: 1;
}

.cart-item-vendor {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 700;
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.cart-item-sku {
  font-size: 1.1rem;
  color: var(--text-primary);
  font-weight: 700;
  margin-bottom: 8px;
}

.cart-item-qty-controls {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.cart-item-qty {
  background: var(--accent-gradient-2);
  color: white;
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  font-size: 1rem;
  font-weight: 800;
  min-width: 48px;
  text-align: center;
  box-shadow: var(--shadow-sm);
}

.cart-qty-btn {
  width: 28px;
  height: 28px;
  font-size: 1.1rem;
  font-weight: 800;
  background: var(--accent-gradient-2);
  color: white;
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--transition-fast);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
}

.cart-qty-btn:hover {
  transform: scale(1.2);
  box-shadow: var(--shadow-glow);
}

.cart-qty-btn:active {
  transform: scale(0.9);
}

.cart-item-price {
  font-size: 1.4rem;
  color: var(--success);
  font-weight: 800;
  margin-bottom: 6px;
}

.cart-item-availability {
  font-size: 0.9rem;
  color: var(--text-primary);
  padding: 6px 12px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-sm);
  display: inline-block;
  margin-top: 6px;
  font-weight: 700;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.cart-item-availability.in-stock {
  background: rgba(16, 185, 129, 0.15);
  color: var(--success);
  border-color: rgba(16, 185, 129, 0.3);
}

.cart-item-availability.low-stock {
  background: rgba(245, 158, 11, 0.15);
  color: var(--warning);
  border-color: rgba(245, 158, 11, 0.3);
}

.cart-item-availability.out-of-stock {
  background: rgba(239, 68, 68, 0.15);
  color: var(--error);
  border-color: rgba(239, 68, 68, 0.3);
}

.cart-item-actions {
  display: flex;
  gap: 12px;
  flex-shrink: 0;
}

.cart-item-link {
  padding: 10px 20px;
  background: var(--accent-gradient);
  color: white;
  text-decoration: none;
  border-radius: var(--radius-sm);
  font-size: 1rem;
  font-weight: 700;
  transition: all var(--transition-fast);
  box-shadow: var(--shadow-sm);
}

.cart-item-link:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md), var(--shadow-glow-purple);
}

.cart-item-remove {
  padding: 10px 20px;
  background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
  color: white;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 1.3rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  box-shadow: var(--shadow-sm);
}

.cart-item-remove:hover {
  transform: scale(1.1);
  box-shadow: var(--shadow-md), 0 0 20px rgba(239, 68, 68, 0.4);
}

/* Cart Preview Tooltip */
.cart-preview-tooltip {
  position: fixed;
  background: var(--bg-secondary);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  min-width: 300px;
  max-width: 400px;
  max-height: 500px;
  z-index: 1000;
  animation: fadeIn 0.15s ease;
}

.cart-preview-header {
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--text-primary);
}

.cart-preview-header span {
  color: #fbbf24;
}

.cart-preview-items {
  padding: 8px;
  max-height: 350px;
  overflow-y: auto;
}

.cart-preview-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px;
  background: var(--bg-tertiary);
  border-radius: var(--radius-md);
  margin-bottom: 8px;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.cart-preview-item:last-child {
  margin-bottom: 0;
}

.cart-preview-image {
  width: 40px;
  height: 40px;
  object-fit: contain;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.03);
  padding: 4px;
}

.cart-preview-info {
  flex: 1;
  min-width: 0;
}

.cart-preview-vendor {
  font-size: 0.65rem;
  color: var(--text-muted);
  text-transform: uppercase;
  font-weight: 600;
  margin-bottom: 2px;
}

.cart-preview-sku {
  font-size: 0.8rem;
  color: var(--text-primary);
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cart-preview-qty {
  font-size: 0.75rem;
  color: var(--text-secondary);
  font-weight: 600;
}

.cart-preview-price {
  font-size: 0.9rem;
  color: var(--success);
  font-weight: 700;
  white-space: nowrap;
}

.cart-preview-footer {
  padding: 12px 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 700;
  background: rgba(194, 65, 12, 0.05);
}

.cart-preview-footer span:first-child {
  color: var(--text-primary);
}

.cart-preview-footer span:last-child {
  color: var(--success);
  font-size: 1.1rem;
}

.cart-preview-empty {
  padding: 20px;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.9rem;
}

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

/* Multiple Product Results */
.product-item-wrapper {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 16px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.02);
  align-items: start;
  margin-bottom: 12px;
  width: 100%;
  box-sizing: border-box;
}

.product-item-wrapper:last-child {
  margin-bottom: 0;
}

.product-item-wrapper .vendor-card-left {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
  width: 160px;
  min-width: 160px;
}

.product-item-wrapper .product-image-link {
  height: 160px;
  min-height: 160px;
  max-height: 160px;
  width: 160px;
  min-width: 160px;
  max-width: 160px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-item-wrapper .product-image {
  width: 160px;
  height: 160px;
  min-width: 160px;
  min-height: 160px;
  max-width: 160px;
  max-height: 160px;
  object-fit: contain;
  background: white;
  border-radius: var(--radius-md);
  padding: 12px;
  box-shadow: var(--shadow-sm);
}

.product-item-wrapper .availability-display {
  font-size: 0.65rem;
  padding: 0;
  width: auto;
  height: auto;
  min-height: 20px;
  max-height: none;
  white-space: nowrap;
  text-align: left;
  background: transparent;
  border: none;
  font-weight: 600;
  display: block;
  justify-content: flex-start;
  align-items: flex-start;
}

.product-item-wrapper .availability-display.in-stock {
  color: #10b981;
}

.product-item-wrapper .availability-display.low-stock {
  color: #f59e0b;
}

.product-item-wrapper .availability-display.out-of-stock {
  color: #ef4444;
}

.product-item-right {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: stretch;
  justify-content: flex-start;
}

.product-item-wrapper .product-title {
  height: auto;
  min-height: 2.6em;
  max-height: none;
  -webkit-line-clamp: 2;
  line-height: 1.3;
  font-size: 0.85rem;
}

.product-item-wrapper .product-sku {
  height: auto;
  min-height: auto;
  max-height: none;
}

.product-item-wrapper .price-display {
  font-size: 1.2rem;
  margin: 4px 0;
  height: auto;
  min-height: 32px;
  max-height: none;
  justify-content: flex-end;
}

.product-item-wrapper .quantity-selector {
  margin: 2px 0;
  justify-content: flex-end;
  height: 22px;
  min-height: 22px;
  max-height: 22px;
  gap: 4px;
}

.product-item-wrapper .qty-input {
  width: 28px;
  padding: 1px 2px;
  font-size: 0.65rem;
}

.product-item-wrapper .qty-btn {
  width: 18px;
  height: 18px;
  font-size: 0.65rem;
}

.product-item-wrapper .cart-add-btn {
  font-size: 0.75rem;
  padding: 6px 12px;
  height: 28px;
  min-height: 28px;
  max-height: 28px;
  width: auto;
  min-width: 100px;
  max-width: 140px;
  align-self: flex-end;
  margin-top: 4px;
}

.product-result-block {
  background: var(--bg-tertiary);
  border-radius: var(--radius-md);
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  transition: all var(--transition-fast);
}

.product-result-block:hover {
  background: rgba(194, 65, 12, 0.05);
  border-color: rgba(194, 65, 12, 0.2);
}

.product-block-content {
  display: grid;
  grid-template-columns: 120px 1fr auto;
  gap: 16px;
  align-items: center;
}

.product-block-left {
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-block-left .product-image-link {
  display: block;
  width: 100%;
  height: auto;
}

.product-block-left .product-image {
  width: 100%;
  height: auto;
  max-height: 100px;
  object-fit: contain;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.03);
  padding: 8px;
}

.product-block-right {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.product-block-right .product-title {
  font-size: 0.95rem;
  color: var(--text-primary);
  font-weight: 600;
  line-height: 1.4;
}

.product-block-right .price-display {
  font-size: 1.3rem;
  color: var(--success);
  font-weight: 700;
}

.product-block-right .availability-display {
  font-size: 0.85rem;
  color: var(--text-secondary);
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  display: inline-block;
  width: fit-content;
}

.product-block-right .availability-display.in-stock {
  background: rgba(16, 185, 129, 0.1);
  color: #10b981;
  border-color: rgba(16, 185, 129, 0.2);
}

.product-block-right .availability-display.low-stock {
  background: rgba(245, 158, 11, 0.1);
  color: #f59e0b;
  border-color: rgba(245, 158, 11, 0.2);
}

.product-block-right .availability-display.out-of-stock {
  background: rgba(239, 68, 68, 0.1);
  color: #ef4444;
  border-color: rgba(239, 68, 68, 0.2);
}

.product-block-right .quantity-selector {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
}

.product-block-right .qty-btn {
  width: 32px;
  height: 32px;
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-sm);
  font-size: 1.2rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-block-right .qty-btn:hover {
  background: var(--bg-tertiary);
  border-color: var(--accent-primary);
}

.product-block-right .qty-input {
  width: 60px;
  height: 32px;
  text-align: center;
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  font-weight: 600;
}

.product-block-actions {
  display: flex;
  align-items: center;
}

.product-block-actions .cart-add-btn {
  padding: 10px 20px;
  background: var(--accent-primary);
  color: white;
  border: none;
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
  box-shadow: var(--shadow-sm);
  white-space: nowrap;
}

.product-block-actions .cart-add-btn:hover {
  background: var(--accent-secondary);
  box-shadow: var(--shadow-md);
}

/* Responsive */
@media (max-width: 1600px) {
  .results-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (max-width: 1400px) {
  .results-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

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

@media (max-width: 750px) {
  .results-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .header-content {
    flex-direction: column;
    gap: 20px;
  }

  header h1 {
    font-size: 2.5rem;
  }

  .search-section {
    flex-direction: column;
  }

  #cart-items-grid {
    grid-template-columns: 1fr;
  }

  .cart-item {
    flex-direction: column;
    text-align: center;
  }

  .cart-item-actions {
    width: 100%;
    justify-content: center;
  }

  .cart-summary {
    flex-direction: column;
    gap: 16px;
  }

  .cart-actions-bottom {
    width: 100%;
    flex-direction: column;
  }

  /* Multiple product blocks responsive */
  .product-block-content {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .product-block-left {
    justify-content: flex-start;
  }

  .product-block-left .product-image {
    max-height: 80px;
  }

  .product-block-actions {
    width: 100%;
  }

  .product-block-actions .cart-add-btn {
    width: 100%;
  }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: var(--bg-secondary);
}

::-webkit-scrollbar-thumb {
  background: var(--accent-gradient);
  border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(135deg, #00d9ff 0%, #667eea 100%);
}
/* Profile Dropdown Menu */
.profile-dropdown {
  position: relative;
  display: inline-block;
}

.profile-dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  right: 0;
  margin-top: 8px;
  background: var(--bg-secondary);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  min-width: 180px;
  z-index: 1000;
  overflow: hidden;
}

.profile-dropdown-menu.show {
  display: block;
  animation: dropdownFadeIn 0.2s ease;
}

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

.profile-dropdown-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  color: var(--text-primary);
  text-decoration: none;
  background: transparent;
  border: none;
  width: 100%;
  text-align: left;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.profile-dropdown-item:last-child {
  border-bottom: none;
}

.profile-dropdown-item:hover {
  background: rgba(194, 65, 12, 0.1);
  color: var(--accent-primary);
}

.profile-dropdown-item svg {
  flex-shrink: 0;
}

.profile-dropdown-item span {
  flex: 1;
}

/* Header Two Rows Layout */
.header-two-rows {
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 100%;
}

.header-row-1 {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: 100%;
}

.header-logo {
  flex-shrink: 0;
}

.header-search {
  display: flex;
  gap: 8px;
  max-width: 400px;
}

.header-search #sku {
  flex: 1;
  padding: 12px 16px;
  font-size: 1rem;
  font-weight: 500;
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 2px solid transparent;
  border-radius: var(--radius-md);
  outline: none;
  transition: all var(--transition-normal);
  box-shadow: var(--shadow-sm);
}

.header-search #sku:focus {
  border-color: var(--accent-primary);
  box-shadow: var(--shadow-glow);
}

.header-search #sku::placeholder {
  color: var(--text-muted);
}

.header-search #compare-btn {
  padding: 12px 20px;
  font-size: 1rem;
  font-weight: 600;
  background: var(--accent-primary);
  color: white;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  box-shadow: var(--shadow-sm);
}

.header-search #compare-btn:hover:not(:disabled) {
  background: var(--accent-secondary);
  box-shadow: var(--shadow-md);
}

.header-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-shrink: 0;
}

.header-right-group {
  display: flex;
  align-items: center;
  gap: 12px;
}

.header-row-2 {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.header-row-2 .header-search {
  max-width: 600px;
  width: 100%;
}

.header-row-3 {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.header-row-3 .vendor-checkboxes {
  margin: 0;
}

/* Custom Cart Dropdown */
.cart-dropdown {
  position: relative;
  display: inline-block;
}

.cart-dropdown-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  min-width: 180px;
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 2px solid rgba(194, 65, 12, 0.3);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  font-size: 0.9rem;
  font-weight: 600;
}

.cart-dropdown-btn:hover {
  border-color: var(--accent-primary);
  box-shadow: var(--shadow-glow);
}

.cart-dropdown-btn .dropdown-arrow {
  margin-left: auto;
  transition: transform var(--transition-fast);
}

.cart-dropdown.open .cart-dropdown-btn .dropdown-arrow {
  transform: rotate(180deg);
}

.cart-dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  margin-top: 8px;
  background: var(--bg-secondary);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  min-width: 220px;
  max-height: 350px;
  z-index: 1000;
  overflow: hidden;
}

.cart-dropdown-menu.show {
  display: block;
  animation: dropdownFadeIn 0.2s ease;
}

.cart-dropdown-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  background: var(--bg-tertiary);
}

.cart-dropdown-header span {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.cart-dropdown-actions {
  display: flex;
  gap: 4px;
}

.cart-dropdown-action {
  padding: 6px;
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--transition-fast);
  display: flex;
  align-items: center;
  justify-content: center;
}

.cart-dropdown-action:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-primary);
  border-color: rgba(255, 255, 255, 0.2);
}

.cart-dropdown-action-danger {
  color: #ef4444;
  border-color: rgba(239, 68, 68, 0.3);
}

.cart-dropdown-action-danger:hover {
  background: rgba(239, 68, 68, 0.2);
  color: #ef4444;
  border-color: rgba(239, 68, 68, 0.5);
}

.cart-dropdown-list {
  max-height: 280px;
  overflow-y: auto;
}

.cart-dropdown-item {
  display: block;
  width: 100%;
  padding: 10px 12px;
  background: transparent;
  color: var(--text-primary);
  border: none;
  text-align: left;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.cart-dropdown-item:last-child {
  border-bottom: none;
}

.cart-dropdown-item:hover {
  background: rgba(194, 65, 12, 0.1);
  color: var(--accent-primary);
}

.cart-dropdown-item.active {
  background: rgba(194, 65, 12, 0.15);
  color: var(--accent-primary);
  font-weight: 700;
}

/* Cart Split Button (same style as Devis) */
.cart-split-btn {
  display: flex;
  align-items: stretch;
}

.cart-btn-main {
  padding: 10px 14px;
  height: 42px;
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 2px solid rgba(194, 65, 12, 0.3);
  border-right: 1px solid rgba(194, 65, 12, 0.3);
  border-radius: var(--radius-md) 0 0 var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: var(--shadow-sm);
  font-size: 0.9rem;
  font-weight: 600;
}

.cart-btn-main:hover {
  background: var(--bg-tertiary);
  border-color: var(--accent-primary);
  color: var(--accent-primary);
  box-shadow: var(--shadow-md);
}

.cart-btn-arrow {
  padding: 0 10px;
  height: 42px;
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 2px solid rgba(194, 65, 12, 0.3);
  border-left: none;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  cursor: pointer;
  transition: all var(--transition-normal);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
}

.cart-btn-arrow:hover {
  background: var(--bg-tertiary);
  border-color: var(--accent-primary);
  color: var(--accent-primary);
  box-shadow: var(--shadow-md);
}

.cart-btn-arrow .dropdown-arrow {
  transition: transform 0.2s ease;
}

.cart-dropdown.open .cart-btn-arrow .dropdown-arrow {
  transform: rotate(180deg);
}

.cart-badge-inline {
  background: var(--accent-primary);
  color: white;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 10px;
  min-width: 18px;
  text-align: center;
}

/* Devis Split Button */
.devis-split-btn {
  display: flex;
  align-items: stretch;
}

.devis-btn-main {
  padding: 10px 14px;
  height: 42px;
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 2px solid rgba(194, 65, 12, 0.3);
  border-right: 1px solid rgba(194, 65, 12, 0.3);
  border-radius: var(--radius-md) 0 0 var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-normal);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: var(--shadow-sm);
  font-size: 0.9rem;
  font-weight: 600;
}

.devis-btn-main:hover {
  background: var(--bg-tertiary);
  border-color: var(--accent-primary);
  color: var(--accent-primary);
  box-shadow: var(--shadow-md);
}

.devis-btn-arrow {
  padding: 0 10px;
  height: 42px;
  background: var(--bg-secondary);
  color: var(--text-primary);
  border: 2px solid rgba(194, 65, 12, 0.3);
  border-left: none;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  cursor: pointer;
  transition: all var(--transition-normal);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
}

.devis-btn-arrow:hover {
  background: var(--bg-tertiary);
  border-color: var(--accent-primary);
  color: var(--accent-primary);
  box-shadow: var(--shadow-md);
}

.devis-btn-arrow .dropdown-arrow {
  transition: transform 0.2s ease;
}

.devis-dropdown.open .devis-btn-arrow .dropdown-arrow {
  transform: rotate(180deg);
}

/* Devis Dropdown */
.devis-dropdown {
  position: relative;
  display: inline-block;
}

.devis-dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  right: 0;
  margin-top: 8px;
  background: var(--bg-secondary);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  min-width: 180px;
  z-index: 1000;
  overflow: visible;
}

/* Pont invisible pour maintenir le hover entre le bouton et le menu */
.devis-dropdown-menu::before {
  content: '';
  position: absolute;
  top: -8px;
  left: 0;
  right: 0;
  height: 8px;
}

.devis-dropdown-menu.show {
  display: block;
  animation: dropdownFadeIn 0.2s ease;
}

.devis-dropdown-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  color: var(--text-primary);
  text-decoration: none;
  background: transparent;
  border: none;
  width: 100%;
  text-align: left;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.devis-dropdown-item:last-child {
  border-bottom: none;
}

.devis-dropdown-item:hover {
  background: rgba(194, 65, 12, 0.1);
  color: var(--accent-primary);
}

.devis-dropdown-item svg {
  flex-shrink: 0;
}

.devis-dropdown-item span {
  flex: 1;
}

/* Dropdown Arrow */
.dropdown-arrow {
  transition: transform var(--transition-fast);
  margin-left: 4px;
}

.devis-dropdown.open .dropdown-arrow {
  transform: rotate(180deg);
}
