:root {
  --chui-yellow: #F5C800;
  --chui-black: #1A1A1A;
  --font-main: 'IBM Plex Sans Arabic', sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

[x-cloak] { display: none !important; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-main);
  color: var(--chui-black);
  background: #fff;
  -webkit-font-smoothing: antialiased;
}

:target { scroll-margin-top: 80px; }

/* ── Scrollbar ─────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: #f1f1f1; }
::-webkit-scrollbar-thumb { background: var(--chui-yellow); border-radius: 3px; }

/* ── Section title ─────────────────────────────────────── */
.section-title {
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 700;
  text-align: center;
  margin-bottom: 0.75rem;
  color: var(--chui-black);
}
.section-subtitle {
  text-align: center;
  color: #6b7280;
  font-size: 0.9375rem;
  margin-bottom: 2.5rem;
  max-width: 42ch;
  margin-inline: auto;
}

/* ── Menu card ─────────────────────────────────────────── */
.menu-card {
  background: #fff;
  border-radius: 1.125rem;
  border: 1px solid #f0f0f0;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  display: flex;
  flex-direction: column;
}
.menu-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 28px rgba(0,0,0,0.09);
}
.menu-card img {
  width: 100%;
  height: 185px;
  object-fit: cover;
  display: block;
  background: #f5f5f5;
}

/* ── Subscription card ─────────────────────────────────── */
.sub-card {
  background: #fff;
  border-radius: 1.125rem;
  border: 1px solid #eaeaea;
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
  padding: 1.5rem;
  transition: box-shadow 0.2s ease;
}
.sub-card:hover { box-shadow: 0 8px 28px rgba(0,0,0,0.10); }
.sub-card.featured {
  border-color: var(--chui-yellow);
  border-width: 2px;
}

/* ── Benefit card ──────────────────────────────────────── */
.benefit-card {
  background: #fff;
  border-radius: 1.125rem;
  border: 1px solid #f0f0f0;
  padding: 1.75rem 1.25rem;
  text-align: center;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.benefit-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.08);
}
.benefit-icon {
  width: 52px;
  height: 52px;
  background: rgba(245,200,0,0.12);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
  color: #c49f00;
}
.benefit-icon svg, .benefit-icon i { width: 1.5rem; height: 1.5rem; }

/* ── Delivery badge ────────────────────────────────────── */
.delivery-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 1.4rem;
  border-radius: 9999px;
  font-weight: 600;
  font-size: 0.875rem;
  transition: all 0.2s ease;
  text-decoration: none;
  border: 2px solid currentColor;
}
.delivery-badge:hover { opacity: 0.9; transform: translateY(-2px); }
.delivery-badge.hungerstation { color: #B07C00; border-color: #F5C800; background: #FFFBEB; }
.delivery-badge.hungerstation:hover { background: #F5C800; color: #1A1A1A; border-color: #F5C800; }
.delivery-badge.jahez { color: #C0001A; border-color: #E4002B; }
.delivery-badge.jahez:hover { background: #E4002B; color: #fff; }

/* ── Calculator inputs ─────────────────────────────────── */
.calc-label {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  color: #6b7280;
  margin-bottom: 0.35rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.calc-input {
  width: 100%;
  border: 1.5px solid #e5e7eb;
  border-radius: 0.625rem;
  padding: 0.6rem 0.875rem;
  font-size: 0.9375rem;
  font-family: var(--font-main);
  outline: none;
  transition: border-color 0.2s;
  background: #fafafa;
  color: var(--chui-black);
}
.calc-input:focus { border-color: var(--chui-yellow); background: #fff; }

/* ── Macro chip ────────────────────────────────────────── */
.macro-chip {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0.875rem 0.5rem;
  border-radius: 0.875rem;
  gap: 0.2rem;
}

/* ── Tab pills ─────────────────────────────────────────── */
.tab-pill {
  padding: 0.5rem 1.125rem;
  border-radius: 9999px;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  border: none;
  transition: all 0.2s ease;
  white-space: nowrap;
  font-family: var(--font-main);
}
.tab-pill.active {
  background: var(--chui-yellow);
  color: var(--chui-black);
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(245,200,0,0.4);
}
.tab-pill:not(.active) {
  background: #f3f4f6;
  color: #6b7280;
}
.tab-pill:not(.active):hover { background: #e5e7eb; color: var(--chui-black); }

/* ── Button variants ───────────────────────────────────── */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: var(--chui-black);
  color: #fff;
  padding: 0.75rem 1.75rem;
  border-radius: 9999px;
  font-weight: 600;
  font-size: 0.9375rem;
  font-family: var(--font-main);
  border: none;
  cursor: pointer;
  transition: opacity 0.2s ease, transform 0.15s ease;
  text-decoration: none;
}
.btn-primary:hover { opacity: 0.85; transform: translateY(-1px); }

.btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: transparent;
  color: var(--chui-black);
  padding: 0.75rem 1.75rem;
  border-radius: 9999px;
  font-weight: 600;
  font-size: 0.9375rem;
  font-family: var(--font-main);
  border: 2px solid var(--chui-black);
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
}
.btn-outline:hover { background: var(--chui-black); color: #fff; transform: translateY(-1px); }

.btn-yellow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--chui-yellow);
  color: var(--chui-black);
  padding: 0.75rem 1.75rem;
  border-radius: 9999px;
  font-weight: 700;
  font-size: 0.9375rem;
  font-family: var(--font-main);
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
}
.btn-yellow:hover { filter: brightness(0.95); transform: translateY(-1px); }

.btn-whatsapp {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: #25D366;
  color: #fff;
  padding: 0.75rem 1.5rem;
  border-radius: 9999px;
  font-weight: 600;
  font-size: 0.9375rem;
  font-family: var(--font-main);
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  width: 100%;
}
.btn-whatsapp:hover { background: #1ebe59; }

/* ── Footer ────────────────────────────────────────────── */
.footer-heading {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #9ca3af;
  margin-bottom: 0.75rem;
}
.footer-link {
  display: block;
  font-size: 0.875rem;
  color: #e2e8f0;
  margin-bottom: 0.5rem;
  transition: color 0.2s;
  text-decoration: none;
  background: none;
}
a.footer-link:hover, button.footer-link:hover { color: var(--chui-yellow); }

/* ── Floating WhatsApp ─────────────────────────────────── */
.fab-whatsapp {
  position: fixed;
  bottom: 1.5rem;
  inset-inline-end: 1.5rem;
  z-index: 40;
  width: 56px;
  height: 56px;
  background: #25D366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(37,211,102,0.4);
  transition: all 0.2s ease;
  cursor: pointer;
  border: none;
  text-decoration: none;
}
.fab-whatsapp:hover { transform: scale(1.1); box-shadow: 0 6px 22px rgba(37,211,102,0.5); }

/* ── Calories badge ────────────────────────────────────── */
.cal-badge {
  position: absolute;
  top: 0.5rem;
  inset-inline-start: 0.5rem;
  background: rgba(245,200,0,0.92);
  color: var(--chui-black);
  font-size: 0.6875rem;
  font-weight: 700;
  padding: 0.2rem 0.55rem;
  border-radius: 9999px;
  backdrop-filter: blur(4px);
}

/* ── Image fallback ────────────────────────────────────── */
img.img-fallback {
  background: linear-gradient(135deg, #f5f5f5 0%, #ebebeb 100%);
}

/* ── Hero word scroll animation ───────────────────────────── */
@keyframes wordIn {
  from { opacity: 0; transform: translateY(1rem); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes wordOut {
  from { opacity: 1; transform: translateY(0); }
  to   { opacity: 0; transform: translateY(-1rem); }
}
.word-in  { animation: wordIn  0.35s cubic-bezier(0.22,1,0.36,1) both; }
.word-out { animation: wordOut 0.28s ease-in both; }
.hero-word {
  color: #F5C800 !important;
  border-color: #F5C800 !important;
}

/* ── Hero pattern overlay ──────────────────────────────── */
.hero-pattern {
  background-image: radial-gradient(circle at 20% 80%, rgba(255,255,255,0.15) 0%, transparent 50%),
                    radial-gradient(circle at 80% 20%, rgba(255,255,255,0.1) 0%, transparent 40%);
}

/* ── Subscription photo ────────────────────────────────── */
.sub-photo {
  width: 100%;
  border-radius: 1.25rem;
  object-fit: cover;
  aspect-ratio: 1;
  box-shadow: 0 12px 40px rgba(0,0,0,0.12);
}

/* ── Admin styles ──────────────────────────────────────── */
.admin-input {
  width: 100%;
  border: 1.5px solid #e5e7eb;
  border-radius: 0.5rem;
  padding: 0.5rem 0.75rem;
  font-size: 0.875rem;
  font-family: var(--font-main);
  outline: none;
  transition: border-color 0.2s;
}
.admin-input:focus { border-color: var(--chui-yellow); }

.admin-tab {
  padding: 0.5rem 1.25rem;
  border-radius: 0.5rem 0.5rem 0 0;
  font-weight: 600;
  font-size: 0.875rem;
  cursor: pointer;
  border: none;
  font-family: var(--font-main);
  transition: all 0.15s;
}
.admin-tab.active { background: var(--chui-yellow); color: var(--chui-black); }
.admin-tab:not(.active) { background: #f3f4f6; color: #6b7280; }

/* ── Cart drawer ───────────────────────────────────────── */
.cart-drawer {
  position: fixed;
  top: 0;
  inset-inline-end: 0;
  height: 100%;
  width: 320px;
  background: #fff;
  z-index: 50;
  box-shadow: -8px 0 40px rgba(0,0,0,0.12);
  display: flex;
  flex-direction: column;
}

/* ── Header hide/show ──────────────────────────────────── */
#site-header {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
#site-header.hidden { transform: translateY(-100%); }
