/* ─── Tokens ──────────────────────────────────────────────────────────────── */
:root {
  --orange:   #F5A623;
  --red:      #C0392B;
  --dark:     #0E0A00;
  --dark2:    #1A1200;
  --surface:  #1E1600;
  --surface2: #251C00;
  --cream:    #F5E6C8;
  --muted:    #A08060;
  --border:   rgba(245,166,35,0.15);
  --radius:   14px;
  --header-h: 64px;
  --bottom-h: 64px;
}

/* ─── Reset ──────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Inter', sans-serif;
  background: var(--dark);
  color: var(--cream);
  min-height: 100vh;
  padding-bottom: var(--bottom-h);
}
img { display: block; max-width: 100%; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }
mark { background: rgba(245,166,35,0.35); color: inherit; border-radius: 3px; padding: 0 2px; }

/* ─── Splash ─────────────────────────────────────────────────────────────── */
#splash {
  position: fixed; inset: 0; z-index: 9999;
  background: var(--dark);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 24px;
  transition: opacity 0.5s ease, visibility 0.5s;
}
#splash.hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.splash-ring {
  width: 120px; height: 120px;
  border-radius: 50%;
  border: 4px solid var(--border);
  border-top-color: var(--orange);
  animation: spin 0.9s linear infinite;
  position: relative;
  display: flex; align-items: center; justify-content: center;
}
.splash-logo {
  width: 88px; height: 88px;
  border-radius: 50%;
  object-fit: cover;
  position: absolute;
}
.splash-ring-img {
  width: 120px; height: 120px; border-radius: 50%;
  border: 4px solid transparent;
  border-top-color: var(--orange);
  animation: spin 0.9s linear infinite;
  position: absolute;
}
.splash-name {
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  color: var(--orange);
  text-transform: uppercase;
}
.splash-tagline { font-size: 0.85rem; color: var(--muted); letter-spacing: 0.05em; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ─── Header ─────────────────────────────────────────────────────────────── */
#site-header {
  position: sticky; top: 0; z-index: 100;
  height: var(--header-h);
  background: rgba(14,10,0,0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center; padding: 0 16px; gap: 12px;
}
.header-logo {
  width: 40px; height: 40px; border-radius: 50%; object-fit: cover; flex-shrink: 0;
}
.header-brand {
  font-size: 1.1rem; font-weight: 800; color: var(--orange); letter-spacing: 0.08em;
  text-transform: uppercase; flex: 1;
}
.search-wrap {
  flex: 2; max-width: 320px;
  position: relative;
}
.search-wrap svg {
  position: absolute; left: 10px; top: 50%; transform: translateY(-50%);
  width: 16px; height: 16px; color: var(--muted); pointer-events: none;
}
#search-input {
  width: 100%; padding: 8px 12px 8px 34px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 999px; color: var(--cream); font-size: 0.875rem;
  outline: none; transition: border-color 0.2s;
}
#search-input:focus { border-color: var(--orange); }
#search-input::placeholder { color: var(--muted); }

#cart-btn {
  position: relative; width: 40px; height: 40px;
  display: flex; align-items: center; justify-content: center;
  background: var(--surface); border-radius: 50%;
  border: 1px solid var(--border);
  flex-shrink: 0;
}
#cart-btn svg { width: 20px; height: 20px; color: var(--cream); }
.cart-badge {
  position: absolute; top: -4px; right: -4px;
  background: var(--orange); color: #000; font-size: 0.65rem;
  font-weight: 800; width: 18px; height: 18px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
}

/* ─── Hero ───────────────────────────────────────────────────────────────── */
#hero {
  padding: 40px 20px 32px;
  text-align: center;
  background: linear-gradient(180deg, #1A1000 0%, var(--dark) 100%);
  position: relative; overflow: hidden;
}
#hero::before {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at center top, rgba(245,166,35,0.1) 0%, transparent 65%);
  pointer-events: none;
}
.hero-logo-wrap {
  width: 110px; height: 110px; margin: 0 auto 20px;
  border-radius: 50%; border: 3px solid var(--orange);
  overflow: hidden; box-shadow: 0 0 30px rgba(245,166,35,0.3);
}
.hero-logo { width: 100%; height: 100%; object-fit: cover; }
#hero h1 {
  font-size: 2.4rem; font-weight: 900; color: var(--orange);
  letter-spacing: 0.08em; text-transform: uppercase; line-height: 1;
}
#hero p {
  margin-top: 8px; color: var(--muted); font-size: 0.9rem; letter-spacing: 0.04em;
}
.combo-banner {
  margin-top: 20px; display: inline-flex; align-items: center; gap: 10px;
  background: linear-gradient(135deg, var(--red), #8B0000);
  padding: 10px 20px; border-radius: 999px;
  font-size: 0.85rem; font-weight: 700; color: #fff;
  box-shadow: 0 4px 20px rgba(192,57,43,0.4);
}
.combo-banner strong { font-size: 1.1rem; }

/* ─── Category Nav ───────────────────────────────────────────────────────── */
#category-wrap {
  position: sticky; top: var(--header-h); z-index: 90;
  background: rgba(14,10,0,0.97);
  border-bottom: 1px solid var(--border);
  padding: 10px 0;
}
#category-nav {
  display: flex; gap: 8px;
  overflow-x: auto; padding: 0 16px;
  scrollbar-width: none;
}
#category-nav::-webkit-scrollbar { display: none; }
.cat-pill {
  flex-shrink: 0; padding: 7px 16px;
  border-radius: 999px; font-size: 0.82rem; font-weight: 600;
  background: var(--surface); color: var(--muted);
  border: 1px solid var(--border);
  transition: all 0.2s;
  white-space: nowrap;
}
.cat-pill:hover { color: var(--cream); border-color: var(--orange); }
.cat-pill.active { background: var(--orange); color: #000; border-color: var(--orange); }

/* ─── Menu Grid ──────────────────────────────────────────────────────────── */
#menu-grid { padding: 24px 16px 0; max-width: 1100px; margin: 0 auto; }

.cat-section { margin-bottom: 40px; }
.cat-header {
  display: flex; align-items: center; gap: 10px;
  margin-bottom: 16px;
}
.cat-emoji { font-size: 1.5rem; }
.cat-header h2 {
  font-size: 1.25rem; font-weight: 800;
  color: var(--orange); text-transform: uppercase; letter-spacing: 0.06em;
}

.items-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
@media (min-width: 640px) { .items-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 960px) { .items-grid { grid-template-columns: repeat(4, 1fr); } }

/* ─── Card ───────────────────────────────────────────────────────────────── */
.menu-card {
  background: var(--surface); border-radius: var(--radius);
  border: 1px solid var(--border);
  overflow: hidden; display: flex; flex-direction: column;
  transition: transform 0.2s, box-shadow 0.2s;
}
.menu-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 30px rgba(245,166,35,0.12);
}

.card-media { position: relative; aspect-ratio: 4/3; background: var(--surface2); }
.card-img { width: 100%; height: 100%; object-fit: cover; }
.card-img-placeholder {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  font-size: 3rem;
}
.item-badge {
  position: absolute; top: 8px; right: 8px;
  background: var(--orange); color: #000; font-size: 0.65rem;
  font-weight: 800; padding: 2px 7px; border-radius: 999px;
  text-transform: uppercase; letter-spacing: 0.05em;
}

.card-body { padding: 12px; flex: 1; display: flex; flex-direction: column; gap: 6px; }
.card-name { font-size: 0.9rem; font-weight: 700; color: var(--cream); line-height: 1.2; }
.card-desc { font-size: 0.72rem; color: var(--muted); line-height: 1.4; flex: 1; }
.card-footer {
  display: flex; align-items: center; justify-content: space-between;
  margin-top: auto; padding-top: 8px;
}
.card-price {
  font-size: 1rem; font-weight: 800; color: var(--orange);
  direction: ltr; unicode-bidi: embed;
}
.add-btn {
  width: 30px; height: 30px; border-radius: 50%;
  background: var(--orange); color: #000; font-size: 1.2rem;
  font-weight: 700; line-height: 1;
  display: flex; align-items: center; justify-content: center;
  transition: transform 0.15s, box-shadow 0.15s;
}
.add-btn:hover { transform: scale(1.1); box-shadow: 0 4px 12px rgba(245,166,35,0.4); }
.add-btn:active { transform: scale(0.95); }

.combo-btn {
  width: 100%; margin-top: 8px; padding: 8px;
  background: linear-gradient(135deg, var(--red), #8B0000);
  color: #fff; font-size: 0.75rem; font-weight: 700;
  border-radius: 8px; display: flex; align-items: center; justify-content: center; gap: 6px;
  transition: opacity 0.2s, transform 0.15s;
}
.combo-btn:hover { opacity: 0.9; }
.combo-btn:active { transform: scale(0.98); }
.combo-btn span { color: var(--orange); }

/* ─── No Results ─────────────────────────────────────────────────────────── */
#no-results {
  text-align: center; padding: 80px 20px;
  color: var(--muted);
}
#no-results span { font-size: 4rem; display: block; margin-bottom: 12px; }
#no-results p { font-size: 1rem; }

/* ─── Reveal Animation ───────────────────────────────────────────────────── */
.reveal { opacity: 0; transform: translateY(20px); transition: opacity 0.5s, transform 0.5s; }
.reveal.visible { opacity: 1; transform: none; }

/* ─── Toast ──────────────────────────────────────────────────────────────── */
#toast {
  position: fixed; top: calc(var(--header-h) + 12px); left: 50%; z-index: 500;
  transform: translateX(-50%) translateY(-200px);
  background: #1a2e1a; border: 1px solid #2d5a2d;
  color: #fff; border-radius: 999px; padding: 10px 20px;
  display: flex; align-items: center; gap: 10px;
  font-size: 0.85rem; font-weight: 600;
  box-shadow: 0 6px 24px rgba(0,0,0,0.5);
  transition: transform 0.35s cubic-bezier(0.34,1.56,0.64,1);
  max-width: calc(100vw - 40px);
}
#toast.show { transform: translateX(-50%) translateY(0); }
.toast-check { color: #4ade80; font-size: 1rem; flex-shrink: 0; }
.toast-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }

/* ─── Cart Overlay ───────────────────────────────────────────────────────── */
#cart-overlay {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(0,0,0,0.6);
  opacity: 0; visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s;
}
#cart-overlay.open { opacity: 1; visibility: visible; }

/* ─── Cart Drawer ────────────────────────────────────────────────────────── */
#cart-drawer {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 300;
  background: var(--surface);
  border-top: 2px solid var(--orange);
  border-radius: 20px 20px 0 0;
  padding: 0 0 env(safe-area-inset-bottom, 0);
  max-height: 80vh; display: flex; flex-direction: column;
  transform: translateY(110%);
  transition: transform 0.4s cubic-bezier(0.34,1.56,0.64,1);
}
#cart-drawer.open { transform: translateY(0); }

.cart-handle {
  width: 40px; height: 4px; border-radius: 2px;
  background: var(--border); margin: 12px auto 0;
}
.cart-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 20px 10px; border-bottom: 1px solid var(--border);
}
.cart-head h2 { font-size: 1.1rem; font-weight: 800; color: var(--orange); }
#cart-close {
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--surface2); color: var(--muted);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem; line-height: 1;
}
#cart-list { flex: 1; overflow-y: auto; padding: 12px 16px; }
.cart-empty {
  text-align: center; padding: 40px 20px;
  color: var(--muted);
}
.cart-empty span { font-size: 3rem; display: block; margin-bottom: 8px; }

.cart-item {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 0; border-bottom: 1px solid var(--border);
}
.ci-emoji { font-size: 1.5rem; flex-shrink: 0; }
.ci-info { flex: 1; min-width: 0; }
.ci-name { display: block; font-size: 0.85rem; font-weight: 700; color: var(--cream); }
.ci-label { display: block; font-size: 0.72rem; color: var(--muted); }
.ci-price {
  display: block; font-size: 0.8rem; color: var(--orange); font-weight: 700;
  direction: ltr; unicode-bidi: embed;
}
.ci-controls {
  display: flex; align-items: center; gap: 8px;
  font-size: 0.85rem; font-weight: 700;
}
.qty-btn {
  width: 26px; height: 26px; border-radius: 50%;
  background: var(--surface2); color: var(--cream);
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem; line-height: 1;
  border: 1px solid var(--border);
}

#cart-footer {
  padding: 12px 16px 16px;
  border-top: 1px solid var(--border);
}
.cart-total-row {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 12px;
}
.cart-total-label { font-size: 0.9rem; color: var(--muted); font-weight: 600; }
#cart-total {
  font-size: 1.3rem; font-weight: 900; color: var(--orange);
  direction: ltr; unicode-bidi: embed;
}
#whatsapp-btn {
  width: 100%; padding: 14px;
  background: linear-gradient(135deg, #25D366, #128C7E);
  color: #fff; font-size: 1rem; font-weight: 800;
  border-radius: var(--radius); letter-spacing: 0.04em;
  display: flex; align-items: center; justify-content: center; gap: 10px;
  transition: opacity 0.2s, transform 0.15s;
  box-shadow: 0 4px 20px rgba(37,211,102,0.35);
}
#whatsapp-btn:hover { opacity: 0.92; }
#whatsapp-btn:active { transform: scale(0.98); }
#whatsapp-btn svg { width: 22px; height: 22px; }

/* ─── Bottom Nav ─────────────────────────────────────────────────────────── */
#bottom-nav {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 150;
  height: var(--bottom-h);
  background: rgba(14,10,0,0.97);
  backdrop-filter: blur(12px);
  border-top: 1px solid var(--border);
  display: flex; align-items: center; justify-content: space-around;
}
.nav-btn {
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  color: var(--muted); font-size: 0.62rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.05em;
  transition: color 0.2s;
  text-decoration: none;
}
.nav-btn:hover, .nav-btn.active { color: var(--orange); }
.nav-btn svg { width: 22px; height: 22px; }
.nav-cart-wrap { position: relative; }
#cart-nav-btn { background: none; border: none; padding: 0; }

/* ─── Footer ─────────────────────────────────────────────────────────────── */
#site-footer {
  margin-top: 48px;
  padding: 32px 20px 20px;
  text-align: center;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.8rem;
}
.footer-logo { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; margin: 0 auto 12px; }
.footer-brand { font-size: 1.1rem; font-weight: 800; color: var(--orange); letter-spacing: 0.08em; text-transform: uppercase; }
.footer-tagline { margin-top: 4px; margin-bottom: 16px; }
.footer-links { display: flex; justify-content: center; gap: 16px; flex-wrap: wrap; }
.footer-links a { color: var(--muted); text-decoration: none; transition: color 0.2s; }
.footer-links a:hover { color: var(--orange); }
.footer-copy { margin-top: 20px; font-size: 0.7rem; opacity: 0.5; }
