/* Ешь, как дома! — Custom styles */

/* Smooth transitions */
* {
  -webkit-tap-highlight-color: transparent;
}

/* Toast notifications */
.toast {
  position: fixed;
  top: 1rem;
  right: 1rem;
  padding: 0.75rem 1.25rem;
  border-radius: 0.75rem;
  color: #fff;
  font-size: 0.875rem;
  font-weight: 500;
  z-index: 9999;
  transform: translateY(-100px);
  opacity: 0;
  transition: all 0.3s ease;
  max-width: 90vw;
}

.toast.show {
  transform: translateY(0);
  opacity: 1;
}

.toast.success {
  background-color: #16a34a;
}

.toast.error {
  background-color: #dc2626;
}

.toast.info {
  background-color: #E07A3A;
}

/* Status badges */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1;
}

.badge-new { background-color: #DBEAFE; color: #1E40AF; }
.badge-accepted { background-color: #D1FAE5; color: #065F46; }
.badge-kitchen { background-color: #FEF3C7; color: #92400E; }
.badge-cooking { background-color: #FFEDD5; color: #9A3412; }
.badge-ready { background-color: #D1FAE5; color: #065F46; }
.badge-delivering { background-color: #E0E7FF; color: #3730A3; }
.badge-completed { background-color: #F3F4F6; color: #374151; }
.badge-cancelled { background-color: #FEE2E2; color: #991B1B; }
.badge-rejected { background-color: #FEE2E2; color: #991B1B; }

/* Loading spinner */
.spinner {
  width: 1.25rem;
  height: 1.25rem;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}

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

/* Modal overlay */
.modal-overlay {
  position: fixed;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.4);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-content {
  background: #fff;
  border-radius: 1rem;
  padding: 1.5rem;
  width: 100%;
  max-width: 32rem;
  max-height: 90vh;
  overflow-y: auto;
  transform: scale(0.95);
  transition: transform 0.2s ease;
}

.modal-overlay.active .modal-content {
  transform: scale(1);
}

/* Skeleton loading shimmer */
.skeleton {
  background: linear-gradient(90deg, #f0eeea 25%, #e8e6e0 50%, #f0eeea 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: 0.5rem;
}

@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* Page transition */
main {
  animation: fadeIn 0.15s ease-out;
}

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

/* Lazy image */
img[loading="lazy"] {
  opacity: 0;
  transition: opacity 0.3s ease;
}
img[loading="lazy"].loaded,
img[loading="lazy"]:not([src=""]) {
  opacity: 1;
}

/* Scrollbar hide for category tabs */
.scrollbar-hide {
  -ms-overflow-style: none;
  scrollbar-width: none;
}
.scrollbar-hide::-webkit-scrollbar {
  display: none;
}
