/* ==========================================================================
   Base Variables & Reset
   ========================================================================== */
:root {
  --primary-color: #b5855d;
  --hero-color: #b5855d;
  --white: #ffffff;
  --gray-light: #f5f5f5;
  --gray: #666;
  --gray-lighter: #999;
}

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


/* ==========================================================================
   Typography & Base Styles
   ========================================================================== */
body {
  font-family: "Cabin", sans-serif;
  line-height: 1.6;
  font-feature-settings: "lnum";
  background-color: var(--gray-light);
}

#locations .section-title {
  margin-bottom: 0.5rem;
}

#locations .section-subtitle {
  font-family: "Cabin", sans-serif;
  font-weight: 400;
  color: var(--primary-color);
  font-size: 1.2rem;
  text-align: center;
  margin-bottom: 2rem;
}

h1, h2, h3, .hero-content p {
  font-family: "Teachers", "Comic Sans MS", sans-serif;
  font-weight: 400;
  color: var(--primary-color);
  font-optical-sizing: auto;
  line-height: 1.15;
  letter-spacing: 0.03em;
}

.small-space {
  font-size: 0.9rem;
  /* background-color: red; */
}

p{
  color: var(--gray);
}

h2 {
  font-size: 2rem;
}

.main-menu-section {
  background-color: var(--gray-light);
}

/* ==========================================================================
   Layout & Utilities
   ========================================================================== */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.no-wrap {
  white-space: nowrap;
}

section {
  padding: 5rem 0;
}

.section-title {
  text-align: center;
  margin-bottom: 3rem;
}

/* ==========================================================================
   Navigation
   ========================================================================== */
nav {
  background: var(--white);
  padding: 0;
  position: fixed;
  width: 100%;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

nav.scrolled {
  padding: 0.5rem 0;
}

.nav-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  height: 10em;
  transition: height 0.3s ease;
}

nav.scrolled .nav-content {
  height: 4em;
}

.logo {
  height: 8em;
  width: auto;
  transition: height 0.3s ease;
}

nav.scrolled .logo {
  height: 3em;
}

/* Navigation Links */
.nav-links {
  display: flex;
  gap: 2rem;
}

.nav-links a {
  text-decoration: none;
  color: var(--primary-color);
  position: relative;
  font-size: 1.2rem;
}

.nav-links a::after {
  content: "";
  position: absolute;
  width: 0;
  height: 1px;
  bottom: -4px;
  left: 0;
  background-color: var(--primary-color);
  transition: width 0.3s ease;
}

.nav-links a:hover::after {
  width: 100%;
}

/* Mobile Navigation */
.burger-menu {
  display: none;
  font-size: 1.5rem;
  color: var(--primary-color);
  cursor: pointer;
  z-index: 101;
  position: absolute;
  right: 1em;
}

.mobile-nav {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  background: var(--white);
  z-index: 99;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 2rem;
}

.mobile-nav.active {
  display: flex;
}

.mobile-nav a {
  text-decoration: none;
  color: var(--primary-color);
  font-size: 1.5rem;
  font-weight: 600;
  position: relative;
}

.mobile-nav a::after {
  content: "";
  position: absolute;
  width: 0;
  height: 2px;
  bottom: -4px;
  left: 0;
  background-color: var(--primary-color);
  transition: width 0.3s ease;
}

.mobile-nav a:hover::after {
  width: 100%;
}

/* Back Button (Carta page) */
.back-button {
  color: var(--primary-color);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero {
  padding-top: 10em;
  height: 100vh;
  display: flex;
  align-items: center;
  text-align: center;
  color: var(--hero-color);
  background: linear-gradient(
    rgba(255, 255, 255, 0.5),
    rgba(255, 255, 255, 0.6),
    rgba(255, 255, 255, 0.6),
    rgba(255, 255, 255, 1)
  ),
  url("img/background.jpg");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.hero-content h1 {
  font-size: 2.5rem;
  margin-bottom: 2.5rem;
}

.hero-content p {
  font-size: 1.8rem;
  margin-top: 1.5rem;
}

.hero-image {
  width: 100%;
  height: 100%;
  max-height: 50vmin;
  max-width: 90vh;
  object-fit: cover;
}

.instagram-cta {
  background-color: var(--gray-light);
  padding: 3rem 0;
  text-align: center;
}

.instagram-content h2 {
  margin-bottom: 1rem;
}

.instagram-content p {
  margin-bottom: 1.5rem;
  font-size: 1.2rem;
}

.instagram-button {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background-color: var(--gray-lighter);
  color: var(--white);
  text-decoration: none;
  padding: 0.8rem 1.5rem;
  border-radius: 25px;
  font-size: 1.2rem;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.instagram-button:hover {
  transform: translateY(-2px);
  background-color: var(--primary-color);
}

@media (max-width: 768px) {
  .instagram-cta {
    padding: 2rem 0;
  }
  
  .instagram-content p {
    font-size: 1rem;
  }
  
  .instagram-button {
    font-size: 1rem;
    padding: 0.6rem 1.2rem;
  }
}

/* ==========================================================================
   About Section
   ========================================================================== */
.about-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: center;
}

.about-content p {
  font-size: 1.2rem;
  line-height: 1.25;
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
  font-family: "Cabin", sans-serif;
  font-weight: 400;
  text-align: justify;
}

.about-video {
  width: 100%;
  border-radius: 10px;
  object-fit: cover;
  aspect-ratio: 1;
}

/* ==========================================================================
   Menu Section
   ========================================================================== */
.menu-options {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
  text-align: center;
}

.menu-card {
  padding: 2rem;
  background-color: var(--white);
  border-radius: 10px;
}

.menu-card p {
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
}

.menu-button {
  background: var(--gray-lighter);
  color: var(--white);
  border: none;
  padding: 10px 20px;
  margin-top: 1rem;
  cursor: pointer;
  border-radius: 5px;
  transition: background-color 0.3s ease, transform 0.2s ease;
}

.menu-button:hover {
  background-color: var(--primary-color);
  transform: translateY(-2px);
}

/* Menu Items (Carta page) */
.menu-section {
  padding: 12rem 0 2rem;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  background-color: var(--white);
}

.menu-category {
  background: var(--white);
  border-radius: 10px;
  padding: 2rem;
  margin-bottom: 2rem;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.category-title {
  color: var(--primary-color);
  font-size: 1.5rem;
  margin: -2rem -2rem 1.5rem -2rem;
  /* box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05); */
  padding: 2rem;
  background-color: #f8f8f8;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-radius: 10px 10px 0 0;
}

.category-title.collapsed {
  margin-bottom: -2rem;
  border-radius: 10px;
}

.category-title::after {
  content: "\f107";
  font-family: "Font Awesome 5 Free";
  font-weight: 900;
  transition: transform 0.3s ease;
  transform: rotate(-180deg);
}

.category-title.collapsed::after {
  transform: rotate(0deg);
}

.menu-items {
  display: grid;
  gap: 1.5rem;
  transition: height 0.3s ease;
  overflow: hidden;
  height: 0;
  grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
}

.menu-items.show {
  height: auto;
}

.menu-item {
  display: grid;
  grid-template-columns: 120px 1fr auto;
  gap: 1.5rem;
  align-items: center;
  background: var(--white);
  padding: 1rem;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  position: relative;
}

.menu-item h3 .icons {
  margin-left: 0.4rem;
}
.menu-item h3 i {
  font-size: 0.8rem;
  margin-right: 0.2rem;
  color: #afafaf
}

.item-image {
  width: 120px;
  height: 120px;
  border-radius: 8px;
  object-fit: cover;
}

.item-info h3 {
  margin-bottom: 0.5rem;
}

.item-description {
  color: var(--gray);
  font-size: 0.9rem;
}

.item-price {
  font-weight: 600;
  color: var(--primary-color);
  white-space: nowrap;
}

/* Varieties */
.varieties {
  margin-top: 0.5rem;
}

.variety {
  font-size: 0.9rem;
  margin: 0.2rem 0;
}

.variety-name {
  font-style: italic;
  margin-right: 0.5rem;
}

.quantity {
  color: var(--gray);
  margin-left: 0.5rem;
  margin-right: 0.5rem;
}

.price {
  color: var(--primary-color);
  font-weight: 600;
  margin-right: 0.5rem;
}

/* Dietary Indicators */
.dietary-indicators {
  position: absolute;
  top: 15px;
  right: 15px;
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  max-width: 80px;
  justify-content: flex-end;
}

.dietary-indicators i {
  background: rgba(255, 255, 255, 0.9);
  border-radius: 50%;
  padding: 0.8rem;
  font-size: 1.1em;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  width: 1.2em;
  height: 1.2em;
  display: flex;
  align-items: center;
  justify-content: center;
}

.dietary-indicators i.vegetarian-icon {
  color: #008000; /* Green color for vegan */
}

.dietary-indicators i.vegan-icon {
  color: #9933cc; /* Purple color for vegetarian */
}

.dietary-indicators i.gluten-icon {
  color: #e6b800; /* Darker yellow for gluten-free */
}

.dietary-indicators i.keto-icon {
  color: #a30000;
}

/* ==========================================================================
   Locations Section
   ========================================================================== */
.locations-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.location-card {
  text-align: center;
  padding: 2rem;
  background-color: var(--gray-light);
  border-radius: 10px;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.location-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  object-position: 50% 30%;
  border-radius: 8px;
}

.location-map {
  width: 100%;
  height: 200px;
  border: none;
  border-radius: 8px;
}

.location-contact {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
}

.whatsapp-link,
.phone-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--white);
  text-decoration: none;
  padding: 0.5rem 1rem;
  border-radius: 5px;
  margin-top: 1rem;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.whatsapp-link:hover,
.phone-link:hover {
  transform: translateY(-2px);
  opacity: 0.9;
}

.whatsapp-link {
  background: #57966e;
}

.phone-link {
  background: #4e86c6;
  margin-right: 0.5rem;
}

.phone-link i,
.whatsapp-link i {
  font-size: 1.2rem;
}

/* ==========================================================================
   Footer
   ========================================================================== */
footer {
  background: var(--primary-color);
  color: var(--white);
  padding: 2rem 0;
  text-align: center;
}

footer p {
  color: var(--white);
}

.social-links {
  margin-top: 1rem;
}

.social-links a {
  color: var(--white);
  margin: 0 10px;
  font-size: 1.5rem;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.social-links a:hover {
  transform: translateY(-2px);
  opacity: 0.8;
}

/* ==========================================================================
   Preloader
   ========================================================================== */
.preloader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(255, 255, 255, 0.9);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

/* ==========================================================================
   Media Queries
   ========================================================================== */
@media (max-width: 768px) {
  .nav-links {
    display: none;
  }


  .about-content,
  .menu-options,
  .locations-grid {
    grid-template-columns: 1fr;
  }

  .hero-content h1 {
    font-size: 2rem;
  }

  .burger-menu {
    display: block;
  }

  .nav-content {
    height: 8em;
  }

  nav.scrolled .nav-content {
    height: 3.5em;
  }

  .logo {
    height: 6em;
  }

  nav.scrolled .logo {
    height: 2.5em;
  }

  .menu-item {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 1rem;
  }

  .item-image {
    width: 100%;
    height: 200px;
    margin: 0 auto;
  }

  .item-price {
    text-align: center;
  }

  .category-title {
    font-size: 1.25rem;
  }

  .menu-section {
    padding: 10rem 0 2rem;
  }

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

  .menu-item {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 1rem;
  }
}

.search-container {
  position: relative;
  margin-left: auto;
}

.search-container input {
  padding: 8px 32px 8px 12px;
  border: 1px solid #ddd;
  border-radius: 20px;
  font-size: 14px;
  width: 200px;
}

.search-container .search-icon {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #666;
}

.search-results {
  display: none;
  margin-bottom: 20px;
}

.search-results-container {
  background: white;
  border-radius: 8px;
  padding: 20px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
  gap: 1.5rem;
}

.search-results-container h2 {
  font-family: 'Teachers', sans-serif;
  color: #333;
  margin-bottom: 1.5rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid #e0e0e0;
}

@media (max-width: 768px) {
  .search-results-container {
    grid-template-columns: 1fr;
  }

  .search-results-container h2 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
  }
}

/* Carta Page Mobile Specific Styles */
@media (max-width: 768px) {
  .carta-page .nav-content {
    flex-wrap: wrap;
    height: auto;
    padding: 1rem 20px;
    gap: 1rem;
  }

  .carta-page nav.scrolled .nav-content {
    height: auto;
    padding: 0.5rem 20px;
  }

  .carta-page .search-container {
    order: 3;
    width: 100%;
    margin: 0;
  }

  .carta-page .search-container input {
    width: 100%;
    padding: 10px 32px 10px 12px;
    font-size: 16px; /* Prevents iOS zoom on focus */
  }

  .carta-page .back-button {
    order: 1;
  }

  .carta-page .logo {
    order: 2;
    height: 4em;
  }

  .carta-page nav.scrolled .logo {
    height: 3em;
  }
}

/* Carta Page Specific Styles */
.carta-page .nav-content {
  display: flex;
  align-items: center;
  position: relative;
}

.carta-page .logo {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

.carta-page .search-container {
  margin-left: auto;
}

/* Existing mobile styles */
@media (max-width: 768px) {
  .carta-page .nav-content {
    flex-wrap: wrap;
    height: auto;
    padding: 1rem 20px;
    gap: 1rem;
  }

  .carta-page .logo {
    position: static;
    transform: none;
    order: 2;
    height: 4em;
  }
}

.about-section {
  background-color: var(--white);
}

.locations-section {
  background-color: var(--white);
}

.important-info {
  margin-top: 2rem;
  padding: 1.5rem;
  background-color: #f8f8f8;
  border-radius: 8px;
}

.dietary-icons {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-bottom: 1rem;
}

.icon-info {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.allergen-warning {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid #ddd;
  font-style: italic;
  color: #666;
}

.dietary-icons .vegetarian-icon {
  color: #008000;
}

.dietary-icons .vegan-icon {
  color: #9933cc; /* Purple color for keto */
}

.dietary-icons .gluten-icon {
  color: #e6b800;
}

.dietary-icons .keto-icon {
  color: #a30000;
}

.dietary-indicators {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

.dietary-indicators i {
  font-size: 0.9em;
}