@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Playfair+Display:ital,wght@0,600;0,700;1,400&family=Oswald:wght@500;600;700&display=swap');

/* ==========================================================================
   CSS VARIABLES & CORE SYSTEM
   ========================================================================== */
:root {
  --primary: #18181b;
  --secondary: #52525b;
  --dark: #09090b;
  --light: #fafafa;
  --muted: #71717a;
  --radius: 12px;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-heading: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

  --bg: var(--light);
  --text: var(--dark);
  --card-bg: #ffffff;
  --border: #e4e4e7;
  --shadow: 0 4px 16px rgba(0,0,0,0.06);
}

[data-theme="dark"] {
  --bg: #09090b;
  --text: #f4f4f5;
  --card-bg: #141417;
  --border: #27272a;
  --muted: #a1a1aa;
  --shadow: 0 4px 16px rgba(0,0,0,0.4);
}

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

body {
  margin: 0;
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  transition: background .25s ease, color .25s ease;
}

/* Header */
.topbar {
  background: var(--card-bg);
  border-bottom: 1px solid var(--border);
  padding: 16px 20px;
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(10px);
}
.topbar-inner {
  max-width: 720px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 14px;
}
.logo {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  object-fit: cover;
  border: 1px solid var(--border);
  background: #fff;
}
.brand { flex: 1; }
.brand h1 {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  margin: 0;
  letter-spacing: -0.02em;
}
.brand p { margin: 2px 0 0; font-size: 0.8rem; color: var(--muted); }

.topbar-actions { display: flex; gap: 8px; }
.icon-btn {
  background: var(--bg);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all .2s ease;
}
.icon-btn:hover { background: var(--border); }

/* Search Bar */
.search-wrap { max-width: 720px; margin: 16px auto 0; padding: 0 20px; }
.search-input {
  width: 100%;
  padding: 11px 16px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--card-bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 0.9rem;
  outline: none;
  transition: border-color .2s ease;
}
.search-input:focus { border-color: var(--primary); }

/* Category Navigation */
.categories {
  max-width: 720px;
  margin: 14px auto 0;
  padding: 0 20px;
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
}
.categories::-webkit-scrollbar { display: none; }
.cat-btn {
  flex: none;
  padding: 8px 18px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--card-bg);
  color: var(--muted);
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  transition: all .2s ease;
}
.cat-btn:hover { color: var(--text); border-color: var(--text); }
.cat-btn.active {
  background: var(--primary);
  color: #ffffff;
  border-color: var(--primary);
  font-weight: 600;
}

/* Menu Container */
.menu-container { max-width: 720px; margin: 0 auto; padding: 24px 20px; }

/* Allergens */
.allergens { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.allergen-tag {
  font-size: 0.68rem;
  padding: 2px 6px;
  border-radius: 4px;
  background: rgba(113,113,122,0.12);
  color: var(--muted);
  font-weight: 500;
}
.no-results { text-align: center; color: var(--muted); padding: 48px 0; font-size: 0.95rem; }

/* WhatsApp Floating Button */
.whatsapp-fab {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: #25D366;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(37,211,102,0.4);
  z-index: 90;
  text-decoration: none;
  transition: transform .2s ease;
}
.whatsapp-fab:hover { transform: scale(1.06); }

/* Footer */
.site-footer {
  background: var(--card-bg);
  border-top: 1px solid var(--border);
  padding: 32px 20px;
  text-align: center;
  margin-top: 40px;
}
.footer-links {
  max-width: 720px;
  margin: 0 auto 16px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
  font-size: 0.85rem;
}
.footer-links a { color: var(--text); text-decoration: none; font-weight: 500; opacity: 0.8; }
.footer-links a:hover { opacity: 1; }
.cta-note { font-size: 0.8rem; color: var(--muted); margin: 8px 0; }
.powered { font-size: 0.72rem; color: var(--muted); opacity: 0.7; }


/* ==========================================================================
   LAYOUT TEMPLATE 1: MINIMAL (Ultra-clean, Minimalist List View)
   ========================================================================== */
html[data-layout="minimal"] .category-block,
body[data-layout="minimal"] .category-block { margin-bottom: 32px; }

html[data-layout="minimal"] .category-title,
body[data-layout="minimal"] .category-title {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  padding-bottom: 8px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

html[data-layout="minimal"] .product-card,
body[data-layout="minimal"] .product-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px dashed var(--border);
  background: transparent !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  border-top: none; border-left: none; border-right: none;
}

html[data-layout="minimal"] .product-img,
body[data-layout="minimal"] .product-img {
  width: 60px;
  height: 60px;
  border-radius: 8px;
  object-fit: cover;
  flex: none;
}

html[data-layout="minimal"] .product-info,
body[data-layout="minimal"] .product-info { flex: 1; min-width: 0; }

html[data-layout="minimal"] .product-top,
body[data-layout="minimal"] .product-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
}
html[data-layout="minimal"] .product-name,
body[data-layout="minimal"] .product-name { font-weight: 600; font-size: 0.95rem; }
html[data-layout="minimal"] .product-price,
body[data-layout="minimal"] .product-price {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--primary);
  background: transparent;
  padding: 0;
}
html[data-layout="minimal"] .product-desc,
body[data-layout="minimal"] .product-desc { font-size: 0.82rem; color: var(--muted); margin-top: 2px; }


/* ==========================================================================
   LAYOUT TEMPLATE 2: MODERN (Modern Rounded Card View)
   ========================================================================== */
html[data-layout="modern"] .category-block,
body[data-layout="modern"] .category-block { margin-bottom: 32px; }

html[data-layout="modern"] .category-title,
body[data-layout="modern"] .category-title {
  font-size: 1.2rem;
  font-weight: 800;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 10px;
}
html[data-layout="modern"] .category-title::after,
body[data-layout="modern"] .category-title::after {
  content: '';
  flex: 1;
  height: 2px;
  background: var(--primary);
  border-radius: 2px;
  opacity: 0.8;
}

html[data-layout="modern"] .product-card,
body[data-layout="modern"] .product-card {
  display: flex;
  gap: 16px;
  background: var(--card-bg) !important;
  border: 1px solid var(--border) !important;
  border-radius: 16px !important;
  padding: 16px !important;
  margin-bottom: 14px !important;
  box-shadow: 0 8px 24px rgba(0,0,0,0.06) !important;
  transition: transform .2s ease, box-shadow .2s ease;
}
html[data-layout="modern"] .product-card:hover,
body[data-layout="modern"] .product-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 30px rgba(0,0,0,0.1) !important;
}

html[data-layout="modern"] .product-img,
body[data-layout="modern"] .product-img {
  width: 90px;
  height: 90px;
  border-radius: 12px;
  object-fit: cover;
  flex: none;
}
html[data-layout="modern"] .product-info,
body[data-layout="modern"] .product-info { flex: 1; min-width: 0; display: flex; flex-direction: column; justify-content: center; }
html[data-layout="modern"] .product-top,
body[data-layout="modern"] .product-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}
html[data-layout="modern"] .product-name,
body[data-layout="modern"] .product-name { font-weight: 700; font-size: 1rem; }
html[data-layout="modern"] .product-price,
body[data-layout="modern"] .product-price {
  font-weight: 700;
  font-size: 0.9rem;
  background: var(--primary);
  color: #ffffff;
  padding: 5px 14px;
  border-radius: 20px;
  white-space: nowrap;
  box-shadow: 0 4px 10px rgba(0,0,0,0.12);
}
html[data-layout="modern"] .product-desc,
body[data-layout="modern"] .product-desc { font-size: 0.83rem; color: var(--muted); margin: 4px 0 6px; }


/* ==========================================================================
   LAYOUT TEMPLATE 3: CLASSIC (Serif Elegance, Warm Accents)
   ========================================================================== */
html[data-layout="classic"],
body[data-layout="classic"] {
  --font-heading: 'Playfair Display', Georgia, serif;
}

html[data-layout="classic"] .category-title,
body[data-layout="classic"] .category-title {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.4rem;
  text-align: center;
  margin-bottom: 20px;
  position: relative;
  padding-bottom: 8px;
}
html[data-layout="classic"] .category-title::after,
body[data-layout="classic"] .category-title::after {
  content: '❖';
  display: block;
  font-size: 0.75rem;
  color: var(--secondary);
  margin-top: 4px;
  text-align: center;
}

html[data-layout="classic"] .product-card,
body[data-layout="classic"] .product-card {
  display: flex;
  gap: 16px;
  background: var(--card-bg) !important;
  border: 1px solid var(--border) !important;
  border-radius: 8px !important;
  padding: 16px !important;
  margin-bottom: 14px !important;
  box-shadow: var(--shadow) !important;
}
html[data-layout="classic"] .product-name,
body[data-layout="classic"] .product-name {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.08rem;
  font-weight: 600;
}
html[data-layout="classic"] .product-price,
body[data-layout="classic"] .product-price {
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--secondary);
  background: transparent;
  padding: 0;
}
html[data-layout="classic"] .product-desc,
body[data-layout="classic"] .product-desc { font-style: italic; font-size: 0.85rem; color: var(--muted); }


/* ==========================================================================
   LAYOUT TEMPLATE 4: CARD GRID (2-Column Visual Grid)
   ========================================================================== */
html[data-layout="cardgrid"] .menu-container,
body[data-layout="cardgrid"] .menu-container { max-width: 860px; }

html[data-layout="cardgrid"] .category-block,
body[data-layout="cardgrid"] .category-block {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-bottom: 36px;
}
html[data-layout="cardgrid"] .category-title,
body[data-layout="cardgrid"] .category-title {
  grid-column: span 2;
  font-size: 1.25rem;
  font-weight: 800;
  margin-bottom: 8px;
  padding-bottom: 6px;
  border-bottom: 2px solid var(--primary);
}

html[data-layout="cardgrid"] .product-card,
body[data-layout="cardgrid"] .product-card {
  display: flex;
  flex-direction: column;
  background: var(--card-bg) !important;
  border: 1px solid var(--border) !important;
  border-radius: 14px !important;
  overflow: hidden !important;
  padding: 0 !important;
  box-shadow: var(--shadow) !important;
  transition: transform .2s ease;
}
html[data-layout="cardgrid"] .product-card:hover,
body[data-layout="cardgrid"] .product-card:hover { transform: translateY(-3px); }

html[data-layout="cardgrid"] .product-img,
body[data-layout="cardgrid"] .product-img {
  width: 100%;
  height: 140px;
  object-fit: cover;
  border-radius: 0 !important;
}
html[data-layout="cardgrid"] .product-info,
body[data-layout="cardgrid"] .product-info { padding: 14px; flex: 1; display: flex; flex-direction: column; }
html[data-layout="cardgrid"] .product-top,
body[data-layout="cardgrid"] .product-top { display: flex; flex-direction: column; gap: 4px; margin-bottom: 6px; }
html[data-layout="cardgrid"] .product-name,
body[data-layout="cardgrid"] .product-name { font-size: 0.95rem; font-weight: 700; }
html[data-layout="cardgrid"] .product-price,
body[data-layout="cardgrid"] .product-price {
  font-weight: 800;
  font-size: 0.95rem;
  color: var(--primary);
  background: transparent;
  padding: 0;
}
html[data-layout="cardgrid"] .product-desc,
body[data-layout="cardgrid"] .product-desc { font-size: 0.8rem; color: var(--muted); flex: 1; }

@media (max-width: 580px) {
  html[data-layout="cardgrid"] .category-block,
  body[data-layout="cardgrid"] .category-block { grid-template-columns: 1fr; }
  html[data-layout="cardgrid"] .category-title,
  body[data-layout="cardgrid"] .category-title { grid-column: span 1; }
}


/* ==========================================================================
   LAYOUT TEMPLATE 5: SIMPLE (Dense Text-First Menu)
   ========================================================================== */
html[data-layout="simple"] .category-title,
body[data-layout="simple"] .category-title {
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 800;
  color: var(--muted);
  margin-bottom: 12px;
  padding-bottom: 4px;
  border-bottom: 2px solid var(--border);
}

html[data-layout="simple"] .product-card,
body[data-layout="simple"] .product-card {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 10px 0 !important;
  border-bottom: 1px solid var(--border) !important;
  background: transparent !important;
  border-top: none !important; border-left: none !important; border-right: none !important;
  border-radius: 0 !important;
  box-shadow: none !important;
}
html[data-layout="simple"] .product-img,
body[data-layout="simple"] .product-img { display: none !important; }
html[data-layout="simple"] .product-info,
body[data-layout="simple"] .product-info { flex: 1; }
html[data-layout="simple"] .product-top,
body[data-layout="simple"] .product-top { display: flex; justify-content: space-between; gap: 12px; }
html[data-layout="simple"] .product-name,
body[data-layout="simple"] .product-name { font-size: 0.92rem; font-weight: 600; }
html[data-layout="simple"] .product-price,
body[data-layout="simple"] .product-price { font-size: 0.92rem; font-weight: 700; color: var(--primary); background: transparent; padding: 0; }
html[data-layout="simple"] .product-desc,
body[data-layout="simple"] .product-desc { font-size: 0.8rem; color: var(--muted); }
