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

body { font-family: 'Tajawal', sans-serif; direction: rtl; }

:root {
  --primary: #0a5f5f;
  --primary-light: #0d7a7a;
  --gold: #c9922a;
  --gold-light: #e0a83a;
  --bg: #fafaf8;
  --card: #ffffff;
  --shadow: 0 4px 24px rgba(10,95,95,0.08);
  --shadow-lg: 0 8px 48px rgba(10,95,95,0.15);
}

/* Animations */
@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-12px); }
}
@keyframes floatSlow {
  0%, 100% { transform: translateY(0px) rotate(0deg); }
  50% { transform: translateY(-18px) rotate(5deg); }
}
@keyframes pulse-ring {
  0% { box-shadow: 0 0 0 0 rgba(10,95,95,0.4); }
  100% { box-shadow: 0 0 0 20px rgba(10,95,95,0); }
}
@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}
@keyframes countUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }

.float-1 { animation: float 3s ease-in-out infinite; }
.float-2 { animation: float 4s ease-in-out infinite 0.5s; }
.float-3 { animation: floatSlow 5s ease-in-out infinite 1s; }
.float-4 { animation: float 3.5s ease-in-out infinite 1.5s; }
.float-5 { animation: floatSlow 4.5s ease-in-out infinite 0.8s; }

/* Cards */
.card {
  background: var(--card);
  border-radius: 1.25rem;
  box-shadow: var(--shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}

/* Product Card */
.product-card {
  background: white;
  border-radius: 1.25rem;
  overflow: hidden;
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
  transition: all 0.3s ease;
  position: relative;
}
.product-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 40px rgba(10,95,95,0.15);
}
.product-card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.product-card:hover img { transform: scale(1.05); }

/* Gradient text */
.gradient-text {
  background: linear-gradient(135deg, var(--primary) 0%, var(--gold) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Hero */
.hero-gradient {
  background: linear-gradient(135deg, #e8f5f5 0%, #fdf9f3 50%, #e8f5f5 100%);
}
.hero-img-wrapper {
  border-radius: 2rem;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  position: relative;
}
.hero-img-wrapper::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(45deg, rgba(10,95,95,0.3) 0%, transparent 60%);
  z-index: 1;
}

/* Stats */
.stat-card {
  background: white;
  border-radius: 1.25rem;
  padding: 1.5rem;
  text-align: center;
  box-shadow: var(--shadow);
  border-top: 4px solid var(--primary);
}
.stat-number {
  font-size: 2.5rem;
  font-weight: 900;
  color: var(--primary);
  line-height: 1;
}

/* Category pills */
.cat-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1.25rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  border: 2px solid transparent;
  transition: all 0.25s ease;
  white-space: nowrap;
}
.cat-pill:hover { transform: translateY(-2px); }
.cat-pill.active {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}
.cat-pill.inactive {
  background: white;
  color: #374151;
  border-color: #e5e7eb;
}
.cat-pill.inactive:hover {
  border-color: var(--primary);
  color: var(--primary);
}

/* Btn */
.btn-primary {
  background: var(--primary);
  color: white;
  padding: 0.75rem 1.75rem;
  border-radius: 0.875rem;
  font-weight: 700;
  font-size: 0.95rem;
  border: none;
  cursor: pointer;
  transition: all 0.25s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}
.btn-primary:hover { background: var(--primary-light); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(10,95,95,0.3); }
.btn-primary:active { transform: scale(0.97); }

.btn-gold {
  background: var(--gold);
  color: white;
  padding: 0.75rem 1.75rem;
  border-radius: 0.875rem;
  font-weight: 700;
  font-size: 0.95rem;
  border: none;
  cursor: pointer;
  transition: all 0.25s ease;
}
.btn-gold:hover { background: var(--gold-light); transform: translateY(-2px); }

.btn-outline {
  background: transparent;
  color: var(--primary);
  padding: 0.75rem 1.75rem;
  border-radius: 0.875rem;
  font-weight: 700;
  font-size: 0.95rem;
  border: 2px solid var(--primary);
  cursor: pointer;
  transition: all 0.25s ease;
}
.btn-outline:hover { background: var(--primary); color: white; transform: translateY(-2px); }

/* Input */
.form-input {
  width: 100%;
  padding: 0.875rem 1rem;
  border: 2px solid #e5e7eb;
  border-radius: 0.875rem;
  font-family: 'Tajawal', sans-serif;
  font-size: 1rem;
  direction: rtl;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  outline: none;
  background: white;
}
.form-input:focus { border-color: var(--primary); box-shadow: 0 0 0 4px rgba(10,95,95,0.1); }

/* Status badges */
.badge { padding: 0.35rem 0.875rem; border-radius: 999px; font-size: 0.8rem; font-weight: 700; }
.badge-pending { background: #fef3c7; color: #92400e; }
.badge-confirmed { background: #dbeafe; color: #1e40af; }
.badge-preparing { background: #ffedd5; color: #9a3412; }
.badge-out_for_delivery { background: #ccfbf1; color: #0f766e; }
.badge-delivered { background: #dcfce7; color: #166534; }
.badge-cancelled { background: #fee2e2; color: #991b1b; }

/* Admin sidebar */
.admin-sidebar {
  background: var(--primary);
  min-height: 100vh;
  width: 260px;
  position: fixed;
  top: 0;
  right: 0;
  z-index: 40;
}

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

/* Float elements in hero */
.floating-pill {
  position: absolute;
  border-radius: 999px;
  opacity: 0.15;
  background: var(--primary);
}

/* Mobile nav */
.mobile-nav {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: white;
  border-top: 1px solid #e5e7eb;
  z-index: 50;
  padding: 0.5rem 0;
}
@media (max-width: 768px) {
  .mobile-nav { display: flex; }
  body { padding-bottom: 70px; }
  .cart-sticky { position: fixed; bottom: 70px; left: 1rem; right: 1rem; z-index: 40; }
}

/* Qty stepper */
.qty-btn {
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  border: 2px solid var(--primary);
  color: var(--primary);
  background: transparent;
  cursor: pointer;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}
.qty-btn:hover { background: var(--primary); color: white; }

/* Steps */
.step-line {
  height: 2px;
  background: linear-gradient(90deg, var(--primary), var(--gold));
  flex: 1;
  margin: 0 -1px;
}

/* Order timeline */
.timeline-dot { width: 1rem; height: 1rem; border-radius: 50%; border: 3px solid var(--primary); background: white; }
.timeline-dot.done { background: var(--primary); }
.timeline-line { width: 2px; height: 2rem; background: #e5e7eb; margin: 0 auto; }
.timeline-line.done { background: var(--primary); }

/* Glass morphism */
.glass { background: rgba(255,255,255,0.85); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }

/* Scroll categories */
.cats-scroll { overflow-x: auto; display: flex; gap: 0.75rem; padding-bottom: 0.5rem; scrollbar-width: none; }
.cats-scroll::-webkit-scrollbar { display: none; }

/* Feature icons */
.feature-icon {
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 1rem;
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: white;
  box-shadow: 0 4px 16px rgba(10,95,95,0.3);
}
