/* ==========================================
   1. GLOBAL TOKENS & RESET
   ========================================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --bg: #faf6f0;
  --surface: #f4eee4;
  --card: #ffffff;
  --border: #e6dec2;
  --accent: #c1440e;
  --accent-gold: #e8a020;
  --text: #2c2520;
  --muted: #706558;
  --nav-h: 70px;
}

body {
  font-family: 'DM Sans', sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  padding-top: calc(var(--nav-h) + 10px); 
  padding-bottom: 90px; 
}

/* ==========================================
   2. FIXED NAVIGATION LAYER
   ========================================== */
nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--nav-h);
  background-color: #fbf6f0;
  z-index: 100000;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 2rem;
}

.nav-brand-block {
  display: flex;
  align-items: center !important;
  flex-direction: row !important;
  gap: 8px; 
  white-space: nowrap !important;  
}

.nav-logo-img {
  width: 40px;
  height: 40px;
  object-fit: contain;
  border-radius: 50%;
}

.logo {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 2rem;
  letter-spacing: 0.05em;
  color: var(--accent);
  text-decoration: none;
}

.logo span {
  color: var(--text);
}

.nav-links {
  display: flex;
  gap: 2rem;
  list-style: none;
  align-items: center;
  margin: 0;
  padding: 0;
}

.nav-links a {
  text-decoration: none;
  color: var(--text);
  font-weight: 600;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  transition: color 0.2s;
}

.nav-links a:hover, 
.nav-links a.active {
  color: var(--accent);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.nav-cart-trigger {
  background: none;
  border: none;
  font-family: 'DM Sans', sans-serif;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.9rem;
  padding: 0.5rem;
}

#cartCount {
  background: var(--accent);
  color: white;
  border-radius: 10px;
  padding: 2px 8px;
  font-size: 0.75rem;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 24px;
  height: 18px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
}

.nav-toggle span {
  width: 100%;
  height: 2px;
  background-color: #c1440e;
  transition: all 0.3s ease;
}

/* ==========================================
   3. FIXED CATEGORY BAR WRAPPER (BOTTOM)
   ========================================== */
.bottom-category-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background-color: #e6dcbe; 
  border-top: 1px solid #c9bda1;
  border-bottom: 1px solid #c9bda1;
  padding: 12px 0 calc(12px + env(safe-area-inset-bottom));
  z-index: 9999;
  box-shadow: 0 -4px 15px rgba(0, 0, 0, 0.08);
}

.bottom-category-bar .tab-bar {
  display: flex;
  gap: 12px;
  list-style: none;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 16px;
  overflow-x: auto;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.bottom-category-bar .tab-bar::-webkit-scrollbar {
  display: none;
}

.bottom-category-bar .tab-bar button {
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  background-color: #ffffff;
  color: #3e5062;
  font-family: 'DM Sans', sans-serif;
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 8px 18px;
  border: 1px solid #c9bda1;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.bottom-category-bar .tab-bar button:hover {
  color: var(--text);
  border-color: #3e5062;
}

.bottom-category-bar .tab-bar button.active {
  background-color: #c1440e;
  color: #ffffff;
  border-color: #c1440e;
}

.category-container {
  display: none !important;
}

/* ==========================================
   4. CONTENT ENGINE SWITCHES
   ========================================== */
.menu-content {
  max-width: 1100px;
  margin: 2rem auto 0;
  padding: 0 2rem;
}

.menu-section {
  display: none;
}

.menu-section.active-section {
  display: block;
}

.section-header {
  margin-bottom: 2rem;
  border-left: 4px solid var(--accent);
  padding-left: 1rem;
}

.section-header h1 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 3rem;
  letter-spacing: 0.04em;
  color: var(--accent);
  line-height: 1;
}

.section-header p {
  color: var(--muted);
  font-size: 0.9rem;
  margin-top: 4px;
}

.sub-category-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 2rem;
  color: var(--accent);
  margin: 1.5rem 0 1rem;
  letter-spacing: 0.04em;
}

.spacing-top {
  margin-top: 2.5rem;
}

.items-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 1.5rem;
  margin-bottom: 3rem;
}

/* ==========================================
   5. UNIFORM CARDS & ASPECT RATIO (1:1)
   ========================================== */
.item-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.2rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  overflow: hidden;
}

.item-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 6px 16px rgba(44, 37, 32, 0.06);
}

.item-img-box {
  width: 100%;
  aspect-ratio: 1 / 1;
  background: var(--surface);
  border-radius: 8px;
  margin-bottom: 1rem;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.item-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.item-img::after {
  content: "Munch Time Cafe";
  display: flex;
  align-items: center;
  justify-content: center;
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  background: var(--surface);
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 500;
}

.item-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 6px;
}

.item-name {
  font-weight: 600;
  font-size: 1rem;
  color: var(--text);
  flex: 1;
}

.item-price {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.3rem;
  color: var(--accent);
  white-space: nowrap;
}

.item-desc {
  font-size: 0.82rem;
  color: var(--muted);
  line-height: 1.5;
  margin-bottom: 12px;
}

.item-meta {
  margin-top: 12px;
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  align-items: center;
}

.badge {
  font-size: 0.65rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.badge-veg { background: #e8f5e9; color: #2e7d32; border: 1px solid #c8e6c9; }
.badge-chicken { background: #fff3e0; color: #e65100; border: 1px solid #ffe0b2; }
.badge-spicy { background: #ffebee; color: #c62828; border: 1px solid #ffcdd2; }
.badge-paneer { background: #f3e5f5; color: #4a148c; border: 1px solid #e1bee7; }

.add-btn {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 10px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.2s;
  margin-top: 12px;
}

.add-btn:hover {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.add-btn.added-state {
  background-color: #fff3e0 !important; 
  color: #c1440e !important; 
  border: 2px solid #c1440e !important; 
}

/* ==========================================
   6. GROUP LIST CONTAINER RULES
   ========================================== */
.layout-group-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 2rem;
}

.group-box {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.2rem;
}

.group-box h3 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.4rem;
  color: var(--accent);
  margin-bottom: 12px;
  border-bottom: 2px solid var(--border);
  padding-bottom: 4px;
  letter-spacing: 0.02em;
}

.group-list-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  font-size: 0.92rem;
  border-bottom: 1px dashed var(--border);
  color: var(--text);
}

.group-list-item:last-child {
  border-bottom: none;
}

.item-meta-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  color: var(--text);
}

.list-add-btn {
  background: none;
  border: none;
  color: var(--accent);
  font-weight: bold;
  cursor: pointer;
  font-size: 1.2rem;
  padding: 0 5px;
  display: flex;
  align-items: center;
}

/* ==========================================
   7. SLIDE-OUT CRAVE LIST PANEL
   ========================================== */
.cart-sidebar {
  position: fixed;
  top: 0;
  right: -360px;
  width: 360px;
  height: 100vh;
  background: var(--card);
  border-left: 1px solid var(--border);
  z-index: 20000;
  box-shadow: -4px 0 20px rgba(0,0,0,0.05);
  display: flex;
  flex-direction: column;
  transition: right 0.3s ease;
}

.cart-sidebar.open {
  right: 0;
}

.cart-header {
  padding: 1.5rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.cart-header h2 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 2rem;
  color: var(--accent);
}

.close-cart {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--muted);
}

.cart-items-list {
  flex: 1;
  overflow-y: auto;
  padding: 1.5rem;
  list-style: none;
}

.cart-item-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 12px;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--surface);
}

.cart-item-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.cart-item-name {
  font-weight: 600;
  font-size: 0.95rem;
}

.cart-item-price {
  font-size: 0.85rem;
  color: var(--muted);
}

.cart-qty-controls {
  display: flex;
  align-items: center;
  gap: 8px;
}

.qty-btn {
  background: var(--surface);
  border: 1px solid var(--border);
  width: 24px;
  height: 24px;
  border-radius: 4px;
  font-weight: bold;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cart-footer {
  padding: 1.5rem;
  border-top: 1px solid var(--border);
  background: var(--surface);
  padding-bottom: calc(85px + env(safe-area-inset-bottom)) !important;  
}

.cart-total-box {
  display: flex;
  justify-content: space-between;
  font-weight: 600;
  margin-bottom: 1rem;
  font-size: 1.1rem;
}

.checkout-btn {
  width: 100%;
  background: #25D366;
  color: white;
  border: none;
  padding: 12px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  text-align: center;
}

/* ==========================================
   8. HOMEPAGE COMPONENTS AND CORE DESIGN
   ========================================== */
.hero { 
  padding: 6rem 2rem 4rem; 
  text-align: center; 
  max-width: 900px; 
  margin: 0 auto; 
}

.hero h1 { 
  font-family: 'Playfair Display', serif; 
  font-size: 3.5rem; 
  font-weight: 600; 
  line-height: 1.2; 
  margin-bottom: 1.5rem; 
}

.hero-tagline-italic {
  font-family: 'Playfair Display', serif; 
  font-style: italic; 
  color: var(--accent); 
  margin-bottom: 1rem;
  font-size: 1.2rem;
}

.hero-description {
  font-size: 1.1rem; 
  color: var(--muted); 
  max-width: 600px; 
  margin: 0 auto 2.5rem;
}

.cta-group { 
  display: flex; 
  gap: 1rem; 
  justify-content: center; 
}

.btn { 
  display: inline-block; 
  padding: 0.9rem 2rem; 
  font-size: 0.85rem; 
  font-weight: 600; 
  text-transform: uppercase; 
  letter-spacing: 0.05em; 
  border-radius: 6px; 
  text-decoration: none; 
  transition: all 0.2s ease;
}

.btn-primary { background: var(--accent); color: #fff; }
.btn-secondary { background: transparent; color: var(--text); border: 2px solid var(--text); }
.btn:hover { transform: translateY(-2px); opacity: 0.95; }

.photo-feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  max-width: 1100px;
  margin: 0 auto 5rem;
  padding: 0 2rem;
}

.feature-pic-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.feature-pic-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 6px 16px rgba(44, 37, 32, 0.06);
}

.feature-pic-box {
  width: 100%;
  height: 230px;
  background: var(--surface);
  overflow: hidden;
}

.feature-pic-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.feature-card-body {
  padding: 2rem 1.5rem;
  text-align: center;
}

.feature-card-body h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1.4rem;
  margin-bottom: 0.8rem;
  color: var(--text);
}

.feature-card-body p {
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.5;
}

.carousel-section {
  max-width: 1100px;
  margin: 0 auto 5rem;
  padding: 0 2rem;
}

.carousel-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 2.5rem;
  color: var(--accent);
  letter-spacing: 0.04em;
  margin-bottom: 1.5rem;
  border-left: 4px solid var(--accent);
  padding-left: 1rem;
}

.carousel-wrapper {
  position: relative;
  width: 100%;
}

.carousel-container {
  width: 100%;
  overflow-x: auto;
  scrollbar-width: none;
}

.carousel-container::-webkit-scrollbar {
  display: none;
}

.carousel-track {
  display: flex;
  gap: 1.5rem;
  padding-bottom: 1rem;
}

.carousel-slide {
  flex: 0 0 280px;
  height: 280px;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--surface);
}

.carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.carousel-slide:hover img {
  transform: scale(1.04);
}

.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 44px;
  height: 44px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 50%;
  color: var(--accent);
  font-size: 1.1rem;
  font-weight: bold;
  cursor: pointer;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(44, 37, 32, 0.08);
  transition: all 0.2s ease;
}

.carousel-arrow:hover {
  background: var(--accent);
  color: #ffffff;
  border-color: var(--accent);
}

.arrow-left { left: -22px; }
.arrow-right { right: -22px; }

/* ==========================================
   9. CAKES & CUSTOMIZATION SHEET MODULE
   ========================================== */
.generic-hero {
  max-width: 1000px;
  margin: 0 auto;
  padding: 4rem 2rem 1rem;
  text-align: center;
}

.generic-hero h1 {
  font-family: 'Playfair Display', serif;
  font-size: 3.5rem;
  font-weight: 600;
  color: var(--text);
}

.form-wrapper {
  max-width: 650px;
  margin: 2rem auto 6rem;
  padding: 0 2rem;
}

.clean-form-box {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 2.5rem 2rem;
  box-shadow: 0 4px 12px rgba(44, 37, 32, 0.02);
}

.clean-form-box h1 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 2.5rem;
  color: var(--accent);
  letter-spacing: 0.03em;
  margin-bottom: 2rem;
  text-align: center;
}

.field-group {
  margin-bottom: 1.5rem;
}

.field-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text);
}

.field-group input,
.field-group select {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg);
  font-family: 'DM Sans', sans-serif;
  font-size: 0.95rem;
  color: var(--text);
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.field-group input:focus,
.field-group select:focus {
  outline: none;
  border-color: var(--accent);
  background: var(--card);
}

.wa-submit-btn {
  width: 100%;
  background: #25D366;
  color: #fff;
  border: none;
  padding: 14px;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  cursor: pointer;
  transition: opacity 0.2s ease, transform 0.15s ease;
  margin-top: 1rem;
}

.wa-submit-btn:hover {
  opacity: 0.95;
  transform: translateY(-1px);
}

/* ==========================================
   10. CONTACT MATRIX & FLAT FOOTER
   ========================================== */
.get-in-touch-section {
  max-width: 1100px;
  margin: 5rem auto;
  padding: 0 2rem;
}

.git-container {
  display: flex;
  gap: 3rem;
  align-items: flex-start;
}

.git-map-box {
  flex: 1.2;
  height: 400px;
  border-radius: 14px;
  border: 1px solid var(--border);
  overflow: hidden;
  background: var(--card);
}

.git-info-box {
  flex: 1;
}

.git-info-box h2 {
  font-family: 'Playfair Display', serif;
  font-size: 2.5rem;
  color: var(--text);
  font-weight: 600;
  margin-bottom: 2rem;
}

.git-field {
  margin-bottom: 1.5rem;
}

.git-label {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-bottom: 4px;
}

.git-value {
  font-size: 1.05rem;
  color: var(--text);
  font-weight: 500;
}

.git-review-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1.8rem;
  margin-top: 2rem;
}

.git-quote {
  font-style: italic;
  font-size: 0.95rem;
  color: var(--muted);
  text-align: center;
  line-height: 1.5;
  margin-bottom: 1.2rem;
}

.git-review-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--accent);
  color: #ffffff;
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 12px;
  border-radius: 6px;
  transition: opacity 0.2s ease;
}

.git-review-btn:hover {
  opacity: 0.95;
}

.flat-footer {
  background: var(--text);
  padding: 3rem 2rem 2.5rem;
  text-align: center;
  width: 100%;
}

.flat-footer-links {
  display: flex;
  justify-content: center;
  gap: 2rem;
  margin-bottom: 2rem;
}

.flat-footer-links a {
  color: #ffffff;
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
  transition: color 0.15s ease;
}

.flat-footer-links a:hover {
  color: var(--accent-gold);
}

.flat-copyright {
  font-size: 0.80rem;
  color: var(--muted);
  letter-spacing: 0.02em;
}

/* ==========================================
   11. CONSOLIDATED BREAKPOINT ENGINE
   ========================================== */
@media (max-width: 768px) {
  nav {
    padding: 0 1rem;
    height: 60px;
  }
  
  body {
    padding-top: 70px;
  }

  .logo {
    font-size: 1.4rem !important; 
  }
  
  .nav-logo-img {
    width: 32px !important; 
    height: 32px !important;
  }

  .nav-links {
    display: none;
  }

  .menu-content {
    padding: 0 1rem;
    margin-top: 1.5rem;
  }

  .items-grid {
    grid-template-columns: 1fr;
  }

  .layout-group-grid {
    grid-template-columns: 1fr;
  }

  .cart-sidebar {
    width: 100%;
    right: -100%;
    height: 100vh;
  }

  .hero { 
    padding: 4rem 1rem 2rem; 
  }

  .hero h1 { 
    font-size: 2.3rem; 
  }

  .photo-feature-grid { 
    padding: 0 1rem; 
    gap: 1.5rem; 
  }

  .carousel-section { 
    padding: 0 1rem; 
  }

  .carousel-slide { 
    flex: 0 0 240px; 
    height: 240px; 
  }

  .carousel-arrow {
    display: none;
  }

  .generic-hero h1 {
    font-size: 2.4rem;
  }

  .clean-form-box {
    padding: 2rem 1.25rem;
  }

  .get-in-touch-section {
    padding: 0 1rem;
    margin: 3rem auto;
  }

  .git-container {
    flex-direction: column;
    gap: 2.5rem;
  }

  .git-map-box {
    width: 100%;
    height: 300px;
  }

  .flat-footer-links {
    flex-wrap: wrap;
    gap: 1.25rem 1.5rem;
  }

  .nav-toggle {
    display: flex;
    z-index: 100001;
  }

  .nav-menu-wrapper {
    display: none;
    position: fixed;
    top: 60px;
    left: 0;
    width: 100%;
    background-color: #fff8f2;
    box-shadow: 0 8px 16px rgba(0,0,0,0.1);
    z-index: 99999;
  }

  .nav-menu-wrapper.mobile-open {
    display: block;
  }

  .nav-links {
    display: flex;
    flex-direction: column;
    width: 100%;
    padding: 1rem 0;
  }

  .nav-links li {
    width: 100%;
    text-align: center;
  }

  .nav-links li a {
    display: block;
    padding: 0.75rem 0;
    width: 100%;
  }
}

/* Background tint layer */
.cart-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(0, 0, 0, 0.4);
  z-index: 19999; 
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.cart-sidebar.open + .cart-overlay,
.cart-overlay.active {
  opacity: 1;
  pointer-events: auto;
}
