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

body {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

a {
  text-decoration: none;
  transition: 1s;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
    margin-left: 4rem;
    margin-right: 4rem;
    border-bottom: 1px solid #eee;
    position: relative;
}

.header-right {
    display: flex;
    align-items: center;
}

.nav-logo {
   height: 6rem;
   border-radius: .5rem;
}

.nav-links {
    display: flex;
    list-style: none;
    margin-right: 20px;
}

.nav-links li {
    margin: 0 1rem;
}

.nav-links a {
    text-decoration: none;
    color: black;
    font-size: 1.4rem;
    font-weight: 500;
    transition: 1s;
}

.nav-links a:hover {
    color: #F58546;
}

.nav-menu-btn {
   display: none;
}

.cart-icon {
    cursor: pointer;
    font-size: 2rem;
    position: relative;
}

.cart-count {
    position: absolute;
    top: -10px;
    right: -10px;
    background-color: #f44336;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    transition: transform 0.2s;
}

.cart-container {
  position: fixed;
  top: 0;
  right: -500px; 
  width: 350px;
  max-width: 100%;
  height: 100vh;
  background-color: white;
  box-shadow: -2px 0 10px rgba(0, 0, 0, 0.2);
  z-index: 1000;
  transition: 1s;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

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

.cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid #eee;
}

#closeCart {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
}

.cart-items {
    padding: 20px;
}

.empty-cart-message {
    text-align: center;
    padding: 20px;
    color: #777;
}

.cart-summary {
    padding: 20px;
    border-top: 1px solid #eee;
}

.cart-total {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 15px;
}

.checkout-btn {
    width: 100%;
    padding: 12px;
    background-color: #4CAF50;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    padding: 10px;
    border-bottom: 1px solid #eee;
}

@media (max-width: 768px) {
  .nav-links {
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    width: 100%;
    background-color: #F58546;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    transform: translateX(100%);
    transition: 1s;
    z-index: 999;
  }

  .nav-links.active {
    transform: translateX(0);
  }

    .nav-menu-btn {
      display: block;
      position: absolute;
      right: 4rem;
      z-index: 1001;
      font-size: 2.5rem;
      display: block;
      cursor: pointer;
    }

    .nav-links {
      z-index: 999;
      gap: 1rem;
  }

  .nav-links li {
    margin: 1rem 0;
    padding-right: 25rem;
  }

  .cart-container {
    width: 100%; 
    right: -100%;
    z-index: 1001;
    position: absolute;
    
  }
}



/* Hero Section */

.hero {
  background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), url('images/bg3.jpg') no-repeat center center/cover;
  height: 50vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: wheat;
  padding: 0 1rem;
}

.hero h1 {
  font-family: 'Alfa Slab One';
  letter-spacing: .2rem;
  font-size: 3.5rem;
  margin-bottom: 1rem;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.hero p {
  font-size: 1.4rem;
  max-width: 600px;
  color: beige;
  margin-bottom: 2rem;
}

.btn {
  background-color: var(--primary);
  color: white;
  padding: .8rem 2rem;
  border: none;
  border-radius: 50px;
  font-weight: bold;
  text-transform: uppercase;
  cursor: pointer;
  transition: background-color 0.3s;
  text-decoration: none;
}

.btn:hover {
  background-color: #e25a2a;
}

.quantity-control-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.quantity-control {
  display: flex;
  flex-direction: row; 
  align-items: center;
  gap: .5rem; 
}

.quantity-btn {
  padding: 0.3rem 0.6rem;
  font-size: 1rem;
  margin: 0;
  background-color: #f0f0f0;
  border: 1px solid #ccc;
  cursor: pointer;
  border-radius: 4px;
}


.quantity-btn:hover {
  background-color: #e0e0e0;
}

.quantity-btn:active {
  transform: scale(0.95);
}

.quantity {
  font-size: 1rem;
  margin: 0.2rem 0;
}

.quantity-change {
  animation: quantityChange 1s;
}

.remove-item {
  display: block;
  margin-top: .5rem;
  height: 2rem;
  width: 6rem;
  font-size: .9rem;
  background-color: #ff4d4f;
  color: white;
  border: none;
  border-radius: .5rem;
  cursor: pointer;
  transition: 1s;
}

.remove-item:hover {
  background-color: #e60000;
}

@keyframes quantityChange {
    0% { transform: scale(1); }
    50% { transform: scale(1.3); color: #f44336; }
    100% { transform: scale(1); }
}

.menu-category-title {
  margin-top: 5rem;
  margin-bottom: 2rem;
  font-size: 2.5rem;
  color: black;
  text-align: center;
}

.menu-categories {
  display: flex;
  justify-content: center;
  margin-top: 4rem;
  margin-bottom: 3rem;
  flex-wrap: wrap;
  gap: 1rem;
}


.category-btn {
  background: none;
  border: none;
  font-family: 'Lato', sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text);
  cursor: pointer;
  padding: .5rem 1rem;
  border-radius: .5rem;
  transition: 1s;
}

.category-btn.active {
  background-color: #F58546;
  color: white;
}

.category-btn:hover:not(.active) {
  color: wheat;
}

.item-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  margin-bottom: 10px;
}

.item-title {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 700;
}

.item-price {
  font-size: 1.3rem;
  font-weight: 700;
  color: #ff6b35;
}


.products {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
  margin-left: 5rem;
  margin-right: 5rem;
}

.product-card {
    border: 1px solid #eee;
    border-radius: .5rem;
    padding: 1rem;
    transition: 1s;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.product-image {
    width: 100%;
    height: 350px;
    object-fit: contain;
    border-radius: .5rem;
    margin-bottom: 1rem;
}

.product-title {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 10px;
}

.product-price {
    font-size: 16px;
    color: #4CAF50;
    margin-bottom: 15px;
}

.product-description {
  font-size: 1.2rem;
  line-height: 1.5;
}

.add-to-cart {
    width: 100%;
    margin-top: 1.5rem;
    padding: 8px 12px;
    background-color: #F58546;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: 1s;
}

.add-to-cart:hover {
    background-color: #0056b3;
}

@media (max-width: 768px) {
   
    .products {
      grid-template-columns: 1fr; /* Single column on mobile */
      gap: 1rem;
      margin-left: 1rem;
      margin-right: 1rem;
    }
    
    .product-card {
      padding: 1rem; /* Reduce padding to maximize width */
      width: 100%; /* Ensure full width */
    }
    
    .product-image {
      height: 250px; /* Optionally reduce image height on mobile */
    }
    
}


/* Footer */

.footer {
  position: relative;
  background-image: url("images/footer.png");
  background-size: cover;
  background-position: center;
  color: white;
  overflow: hidden;
  padding-top: 5rem;
  margin-top: 4rem;
}

.footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)); 
  z-index: 0;
}

.footer-container {
  margin-left: 4rem;
  position: relative;
  z-index: 1;
}

.footer-content-grid {
  display: grid;
  padding-bottom: 3rem;
  grid-template-columns: 1fr 2fr;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.logo-img {
  border-radius: .5rem;
  height: 6rem;
  margin-bottom: 1rem;
}

.footer-description {
  width: 100%;
  margin-bottom: 1.5rem;
  font-size: 1.2rem;
  line-height: 1.4;
}

.footer-socials {
  display: flex;
  gap: 1rem;
}

.footer-socials a {
  background-color: #F58546;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #333;
  transition: 1s;
}

.footer-socials a:hover {
  background: #F58546;
  transform: translateY(-3px);
}

.footer-links-container {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
}

.footer-links-column-1 {
  margin-left: 6rem;
}

.footer-links-column-2 {
  margin-left: 10.5rem;
  width: 100%;
}

.footer-links-column-1 h4 {
  color: white;
  font-size: 1.2rem;
  margin-bottom: 20px;
  position: relative;
  padding-bottom: 10px;
}

.footer-links-column-2 h4 {
  color: white;
  font-size: 1.2rem;
  margin-bottom: 20px;
  position: relative;
  padding-bottom: 10px;
}

.footer-links-column-1 h4::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  height: 2px;
  width: 40px;
  background-color: #F58546;
}

.footer-links-column-2 h4::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  height: 2px;
  width: 40px;
  background-color: #F58546;
}

.footer-links-container .footer-connect {
  font-size: 1.5rem;
}

.footer-connect {
  margin-left: -1rem;
}

.footer-menu, .footer-contact {
  list-style: none;
  line-height: 1.5;
  width: 120%;
  padding: 0;
  margin: 0;
}

.footer-links-column-2 .footer-newsletter {
  font-size: 1.7rem;
}

.footer-links-column-2 .newsletter-tagline {
  font-size: 1.4rem;
}

.footer-menu li, .footer-contact li {
  margin-bottom: 12px;
  font-size: 1.3rem;
}

.footer-menu a {
  font-size: 1.5rem;
  color: white;
  text-decoration: none;
  opacity: .8;
  transition: 1s;
}

.footer-menu a:hover {
  opacity: 1;
  color: #F58546;
  padding-left: 5px;
}

.footer-contact li {
  display: flex;
  align-items: center;
  margin-left: -1rem;
}

.footer-contact span {
  margin-right: 10px;
  width: 20px;
  display: inline-flex;
  justify-content: center;
  color: #F58546;
}

.footer-subscribe {
  margin-top: 15px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-subscribe input {
  padding: 12px;
  border-radius: 4px;
  border: none;
  background: rgba(255, 255, 255, 0.1);
  color: white;
}

.footer-subscribe input::placeholder {
  color: rgba(255, 255, 255, 0.6);
}

.footer-subscribe button {
  padding: 12px;
  border: none;
  background: #F58546;
  color: white;
  border-radius: 4px;
  cursor: pointer;
  transition: 1s;
}

.footer-subscribe button:hover {
  background: #F58546;
}

.footer-bar {
  background: rgba(0, 0, 0, 0.5);
  padding: 20px 0;
}

.footer-bar-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-legal {
  display: flex;
  gap: 20px;
}

.footer-legal a {
  color: white;
  opacity: 0.7;
  text-decoration: none;
  transition: 1s;
}

.footer-legal a:hover {
  opacity: 1;
}


/* Media Queries */


@media (max-width: 768px) {
  .hero h1 {
    font-size: 2.5rem;
  }
  
  .menu-section {
    padding: 3rem 5%;
  }
  
  .nav-links {
    gap: 1rem;
  }
}


@media (max-width: 768px) {
  .footer {
    position: relative;
    background-image: url("images/footer.png");
    background-size: cover;
    background-position: center;
    color: white;
    overflow: hidden;
    padding-top: 5rem;
    margin-top: 4rem;
  }

  .footer-container {
    margin-left: -3.5rem;
  }
  
  /* Change the layout to stack items vertically */
  .footer-content-grid {
    display: flex;
    flex-direction: column;
  }

  /* Ensure footer-brand appears first */
  .footer-brand {
    order: 1;
    margin-bottom: 3rem; /* Add space between sections */
  }

  /* Ensure footer-links-container appears second */
  .footer-links-container {
    order: 2;
    grid-template-columns: 1fr;
 
  }

  .footer-logo {
    margin-left: 5rem;
  }
  
  .footer-description {
    margin-left: 5rem;
    width: 75%;
  }

  .footer-bar-content {
    flex-direction: column;
    gap: 15px;
    text-align: center;
  }

  .footer-socials {
    margin-left: 5rem;
  }

  /* Reset the negative margins and align with parent */
  .footer-connect {
    margin-left: -1rem;
  }
  
  .footer-contact {
    margin: 0;
   
  }
  
  .footer-newsletter {
    width: 75%;
    margin-top: 1rem;
    margin-left: -5.2rem;
  }

  .newsletter-tagline {
    margin-left: -5.2rem;
    width: 75%;
  }

  .footer-subscribe {
    margin-left: -5.2rem;
    width: 65%;
  }
}
