@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&family=Space+Grotesk:wght@600;700&display=swap');

:root {
  --primary: #10b981;
  --primary-dark: #059669;
  --primary-light: #d1fae5;
  --accent: #f59e0b;
  --accent-pink: #ec4899;
  --accent-purple: #8b5cf6;
  --dark-bg: #090d16;
  --dark-surface: #111827;
  --dark-card: #1f2937;
  --dark-border: rgba(255, 255, 255, 0.08);
  --text-primary: #f9fafb;
  --text-secondary: #9ca3af;
  --text-muted: #6b7280;
  --radius-lg: 1.25rem;
  --radius-md: 0.875rem;
  --radius-sm: 0.5rem;
  --shadow-glow: 0 10px 30px -10px rgba(16, 185, 129, 0.35);
  --shadow-card: 0 4px 20px rgba(0, 0, 0, 0.3);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
}

body {
  background: #06090e;
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
}

/* Glassmorphism & Modern effects */
.glass {
  background: rgba(17, 24, 39, 0.75);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--dark-border);
}

.glass-card {
  background: rgba(31, 41, 55, 0.6);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.2s ease;
}

.glass-card:hover {
  border-color: rgba(16, 185, 129, 0.3);
}

/* Responsive Mobile Simulator Frame for Desktop viewers */
.mobile-device-wrapper {
  max-width: 440px;
  margin: 0 auto;
  min-height: 100vh;
  background: #0a0f18;
  position: relative;
  box-shadow: 0 0 60px rgba(0, 0, 0, 0.8), 0 0 2px rgba(255, 255, 255, 0.1);
  display: flex;
  flex-direction: column;
}

/* App Header */
.app-header {
  position: sticky;
  top: 0;
  z-index: 50;
  padding: 12px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(10, 15, 24, 0.92);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--dark-border);
}

.logo-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: -0.5px;
  background: linear-gradient(135deg, #34d399 0%, #10b981 50%, #06b6d4 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand-badge {
  background: rgba(16, 185, 129, 0.15);
  color: #10b981;
  font-size: 0.65rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 9999px;
  border: 1px solid rgba(16, 185, 129, 0.3);
  text-transform: uppercase;
}

/* Bottom Navigation Bar */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 440px;
  height: 68px;
  background: rgba(13, 19, 31, 0.95);
  backdrop-filter: blur(20px);
  border-top: 1px solid var(--dark-border);
  display: flex;
  justify-content: space-around;
  align-items: center;
  z-index: 100;
  padding: 0 8px;
}

.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  flex: 1;
  height: 100%;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.68rem;
  font-weight: 600;
  gap: 4px;
  transition: all 0.2s ease;
  position: relative;
  cursor: pointer;
}

.nav-item.active {
  color: #10b981;
}

.nav-item.active i {
  transform: translateY(-2px);
  filter: drop-shadow(0 2px 8px rgba(16, 185, 129, 0.5));
}

.nav-item i {
  font-size: 1.25rem;
  transition: transform 0.2s;
}

.cart-bubble {
  position: absolute;
  top: 8px;
  right: 18px;
  background: #ef4444;
  color: white;
  font-size: 0.65rem;
  font-weight: 800;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid #0d131f;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.15); }
  100% { transform: scale(1); }
}

/* Main Content Area */
.main-viewport {
  flex: 1;
  padding-bottom: 90px;
  overflow-y: auto;
}

/* Category Pills & Badges */
.category-scroll {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding: 4px 16px 12px 16px;
  scrollbar-width: none;
}
.category-scroll::-webkit-scrollbar {
  display: none;
}

.cat-chip {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  min-width: 72px;
  cursor: pointer;
  text-decoration: none;
}

.cat-chip-icon {
  width: 58px;
  height: 58px;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  background: rgba(31, 41, 55, 0.8);
  border: 1px solid var(--dark-border);
  transition: all 0.2s ease;
}

.cat-chip.active .cat-chip-icon {
  border-color: #10b981;
  box-shadow: 0 0 15px rgba(16, 185, 129, 0.35);
  background: rgba(16, 185, 129, 0.15);
}

.cat-chip-name {
  font-size: 0.72rem;
  color: var(--text-secondary);
  text-align: center;
  font-weight: 500;
  line-height: 1.2;
}

/* Product Cards */
.product-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  padding: 0 16px;
}

.product-card {
  background: rgba(19, 26, 40, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 18px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.product-card:hover {
  border-color: rgba(16, 185, 129, 0.4);
  transform: translateY(-2px);
}

.product-img-box {
  width: 100%;
  height: 135px;
  position: relative;
  overflow: hidden;
  background: #111827;
}

.product-img-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.product-card:hover .product-img-box img {
  transform: scale(1.06);
}

.product-badge-tag {
  position: absolute;
  top: 8px;
  left: 8px;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(4px);
  color: #34d399;
  font-size: 0.6rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 6px;
  letter-spacing: 0.5px;
  border: 1px solid rgba(52, 211, 153, 0.3);
}

.product-details {
  padding: 10px 12px 14px 12px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.product-title {
  font-size: 0.82rem;
  font-weight: 600;
  color: #f3f4f6;
  line-height: 1.35;
  margin-bottom: 4px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  height: 2.3em;
}

.product-unit {
  font-size: 0.7rem;
  color: #9ca3af;
  margin-bottom: 8px;
}

.product-price-row {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

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

.current-price {
  font-size: 0.95rem;
  font-weight: 700;
  color: #10b981;
}

.mrp-price {
  font-size: 0.68rem;
  color: #6b7280;
  text-decoration: line-through;
}

.add-btn {
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid rgba(16, 185, 129, 0.4);
  color: #10b981;
  font-weight: 700;
  font-size: 0.75rem;
  padding: 6px 14px;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.add-btn:hover, .add-btn:active {
  background: #10b981;
  color: #052e16;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
}

.qty-counter {
  display: inline-flex;
  align-items: center;
  background: #10b981;
  border-radius: 10px;
  color: #052e16;
  font-weight: 800;
  font-size: 0.8rem;
  overflow: hidden;
}

.qty-btn {
  background: transparent;
  border: none;
  padding: 5px 10px;
  font-weight: 800;
  font-size: 0.85rem;
  cursor: pointer;
  color: #052e16;
}

/* Universal Buttons & Inputs */
.btn-primary {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  color: #ffffff;
  font-weight: 700;
  font-size: 0.9rem;
  padding: 12px 20px;
  border-radius: 14px;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 4px 18px rgba(16, 185, 129, 0.35);
  transition: all 0.2s ease;
  width: 100%;
}

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

.btn-secondary {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #e5e7eb;
  font-weight: 600;
  font-size: 0.85rem;
  padding: 10px 16px;
  border-radius: 12px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: background 0.2s;
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.14);
}

.input-dark {
  background: rgba(17, 24, 39, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  padding: 12px 14px;
  color: #f9fafb;
  font-size: 0.88rem;
  width: 100%;
  outline: none;
  transition: border-color 0.2s ease;
}

.input-dark:focus {
  border-color: #10b981;
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.15);
}

/* Modal Popup & Overlay - Centered Dialog */
.modal-overlay {
  position: fixed !important;
  inset: 0 !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
  background: rgba(0, 0, 0, 0.82) !important;
  backdrop-filter: blur(8px) !important;
  -webkit-backdrop-filter: blur(8px) !important;
  z-index: 9999 !important;
  display: none;
  align-items: center !important;
  justify-content: center !important;
  padding: 20px !important;
  box-sizing: border-box !important;
}

.modal-sheet {
  background: #111827 !important;
  border-radius: 20px !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.85), 0 0 0 1px rgba(16, 185, 129, 0.15) !important;
  width: 100% !important;
  max-width: 480px !important;
  max-height: 88vh !important;
  overflow-y: auto !important;
  padding: 24px !important;
  margin: auto !important;
  position: relative !important;
  animation: modalScaleIn 0.25s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

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

@keyframes slideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

/* Live Order Tracker Banner */
.tracker-banner {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.15), rgba(6, 182, 212, 0.1));
  border: 1px solid rgba(16, 185, 129, 0.35);
  border-radius: 16px;
  padding: 12px 16px;
  margin: 12px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.pulse-dot {
  width: 10px;
  height: 10px;
  background: #10b981;
  border-radius: 50%;
  box-shadow: 0 0 0 rgba(16, 185, 129, 0.7);
  animation: ringPulse 1.8s infinite;
}

@keyframes ringPulse {
  0% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
  70% { box-shadow: 0 0 0 10px rgba(16, 185, 129, 0); }
  100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

/* Portal Switcher Topbar */
.portal-switch-bar {
  background: #04070c;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding: 8px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 0.75rem;
  overflow-x: auto;
  position: sticky;
  top: 0;
  z-index: 100;
}

.portal-tab-btn {
  padding: 5px 12px;
  border-radius: 9px;
  text-decoration: none;
  font-weight: 600;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  color: #9ca3af;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid transparent;
}

.portal-tab-btn:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.15);
}

.portal-tab-btn.active {
  background: #10b981;
  color: #064e3b;
  font-weight: 800;
  box-shadow: 0 2px 10px rgba(16, 185, 129, 0.3);
}

/* Smooth Tab Transitions & Scrollbars */
.tab-content {
  animation: fadeInTab 0.22s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

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

/* Custom Sleek Scrollbar */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: rgba(11, 15, 25, 0.5);
}
::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.14);
  border-radius: 9999px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(16, 185, 129, 0.4);
}

