/* FastKalori.com - Custom CSS & Mobile-First Styling */

:root {
  --font-main: 'Plus Jakarta Sans', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --color-protein: #10b981; /* Emerald */
  --color-carbs: #f59e0b;   /* Amber */
  --color-fat: #f43f5e;     /* Rose */
  --color-cal: #3b82f6;     /* Blue */
}

/* Custom smooth transitions */
* {
  transition-property: background-color, border-color, color, fill, stroke, box-shadow, transform;
  transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
  transition-duration: 150ms;
}

/* Hide scrollbar for Chrome, Safari and Opera */
.no-scrollbar::-webkit-scrollbar {
  display: none;
}

/* Hide scrollbar for IE, Edge and Firefox */
.no-scrollbar {
  -ms-overflow-style: none;  /* IE and Edge */
  scrollbar-width: none;  /* Firefox */
}

/* Smooth Drag Scroll Containers */
.scroll-drag-container {
  -webkit-user-select: none;
  user-select: none;
  cursor: grab;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
}

.scroll-drag-container.is-dragging {
  cursor: grabbing !important;
}

.scroll-drag-container.is-dragging button {
  pointer-events: none;
}

/* Desktop Scrollbar */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: rgba(15, 23, 42, 0.05);
}

.dark ::-webkit-scrollbar-track {
  background: rgba(15, 23, 42, 0.6);
}

::-webkit-scrollbar-thumb {
  background: rgba(156, 163, 175, 0.4);
  border-radius: 9999px;
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(107, 114, 128, 0.7);
}

/* Glassmorphism helpers */
.glass-panel {
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.dark .glass-panel {
  background: rgba(15, 23, 42, 0.90);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

/* iOS Safe Area Padding Support */
.safe-pb {
  padding-bottom: max(1rem, env(safe-area-inset-bottom, 1rem));
}

.safe-mb {
  margin-bottom: env(safe-area-inset-bottom, 0px);
}

/* Animations */
@keyframes pulseSubtle {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.02);
  }
}

.animate-pulse-subtle {
  animation: pulseSubtle 2.5s ease-in-out infinite;
}

/* Card hover glow effects */
.product-card {
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: transform;
}

.product-card:hover {
  transform: translateY(-2px);
}

.dark .product-card:hover {
  box-shadow: 0 10px 25px -8px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255, 255, 255, 0.1);
}

/* Custom range input styling */
input[type="range"] {
  accent-color: #f59e0b;
}

/* Mobile drawer touch-friendly */
@media (max-width: 640px) {
  #tray-drawer {
    max-height: 90vh;
    border-top-left-radius: 1.5rem;
    border-top-right-radius: 1.5rem;
  }
}
