body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
  text-align: center;
  overflow-x: auto; /* allow horizontal scrolling */
  overflow-y: auto; /* allow vertical scrolling */
}

html {
  scroll-behavior: smooth;
  overflow-x: auto; /* allow horizontal scrolling */
  overflow-y: auto; /* allow vertical scrolling */
}

nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem;
  background: #333;
  color: white;
}

.nav-links {
  list-style: none;
  display: flex;
}

.nav-links li {
  margin: 0 15px;
}

.nav-links a {
  color: white;
  text-decoration: none;
  font-size: 1.2rem;
}

.home {
  padding: 4rem 2rem;
  background-color: #f4f4f4;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
}

.home h1 {
  font-size: 2.5rem;
  color: #333;
}

.home p {
  font-size: 1.2rem;
  color: #666;
  margin-top: 10px;
}

.logo-container {
  display: flex;
  align-items: center;
  text-decoration: none;
}

.logo {
  width: 100px;
  height: 100px;
  margin-right: 15px;
  border-radius: 50%;
}

.home-logo-container {
  text-align: center;
  margin-bottom: 20px;
}

.home-logo {
  width: 150px; /* Adjust size as needed */
  height: 150px; /* Set height equal to width to make it a circle */
  border-radius: 50%; /* This makes the logo round */
  object-fit: cover; /* Ensures the logo fits within the circle without distortion */
}

.company-name {
  font-size: 1.5rem;
  font-weight: bold;
  color: white;
}

.products,
.contact {
  padding: 2rem;
}

.products h2,
.contact h2 {
  font-size: 2rem;
  color: #333;
}

/* Product List - Three columns */
.product-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr); /* 3 columns */
  gap: 20px;
  justify-items: center;
  padding: 20px;
}

/* Responsive adjustments */
@media (max-width: 1024px) {
  .product-list {
    grid-template-columns: repeat(2, 1fr); /* 2 columns for medium screens */
  }
}

.product {
  position: relative;
  overflow: hidden;
  transition: transform 0.3s ease, background-color 0.3s ease;
  border-radius: 5px;
}

.product:hover {
  transform: scale(1.05);
  background-color: rgba(0, 0, 0, 0.1); /* Slight highlight effect */
}

.product img {
  width: 100%;
  height: 400px;
  object-fit: cover;
  border-radius: 5px;
  background-color: #f4f4f4;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.product-info {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 10px;
  background-color: rgba(0, 0, 0, 0.6);
  color: white;
  text-align: center;
  opacity: 0;
  transition: opacity 0.3s ease;
  transform: translateY(100%);
}

.product:hover .product-info {
  opacity: 1;
  transform: translateY(0);
}

.product-info h3 {
  margin: 0;
  font-size: 1.2rem;
}

.product-info p {
  font-size: 1rem;
  margin: 5px 0 0;
  font-weight: bold;
}

/* Show Details Button */
.show-details-btn {
  margin-top: 10px;
  padding: 10px 15px;
  background-color: #333;
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-size: 1rem;
}

.show-details-btn:hover {
  background-color: #555;
}

/* Modal Layout */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  justify-content: center;
  align-items: center;
}

.modal-content {
  background: white;
  padding: 20px;
  width: 60%; /* Slimmer width */
  max-width: 500px; /* Prevents too wide */
  height: 80%; /* Taller modal */
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
}

.modal-body {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px;
  overflow-y: auto;
}

.modal-body img {
  width: 400px;
  height: 400px;
  object-fit: cover;
  border-radius: 5px;
}

.modal-info {
  text-align: center;
}

.modal-info h3 {
  margin: 0;
  font-size: 1.5rem;
}

.modal-info p {
  font-size: 1rem;
  margin-top: 10px;
}

.close-modal {
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 2rem;
  cursor: pointer;
  color: #333;
}

.close-modal:hover {
  color: red;
}

.check-more-btn {
  display: inline-block;
  margin-top: 20px;
  padding: 10px 20px;
  background-color: #333;
  color: white;
  text-decoration: none;
  border-radius: 5px;
  font-size: 1rem;
}

.check-more-btn:hover {
  background-color: #555;
}

.menu-toggle {
  display: none;
}

.reviews-section,
.add-review-section {
  max-width: 600px;
  margin: 20px auto;
  padding: 20px;
  border-radius: 8px;
  background: #f9f9f9;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

#reviews-container .review {
  background: #fff;
  padding: 10px;
  margin-bottom: 10px;
  border-left: 4px solid #333;
}

.add-review-section input,
.add-review-section textarea {
  width: 100%;
  padding: 10px;
  margin: 10px 0;
  border: 1px solid #ddd;
  border-radius: 5px;
}

.add-review-section button {
  background: #333;
  color: #fff;
  padding: 10px;
  border: none;
  cursor: pointer;
  width: 100%;
  border-radius: 5px;
}

.add-review-section button:hover {
  background: #333;
}

.star-rating {
  display: flex;
  gap: 5px; /* Adjust the gap between stars */
}

.star-rating label {
  cursor: pointer;
  font-size: 24px; /* Adjust the size of the stars */
}

@media (max-width: 600px) {
  nav {
    flex-wrap: wrap;
    position: relative;
  }

  .nav-links {
    display: none;
    flex-direction: column;
    width: 100%;
    background-color: #333;
    text-align: center;
  }

  .nav-links li {
    margin: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .nav-links a {
    display: block;
    padding: 15px 0;
  }

  .nav-links.active {
    display: flex;
  }

  .menu-toggle {
    display: block;
    background: none;
    border: none;
    font-size: 2rem; /* big dots/hamburger */
    color: white;
    cursor: pointer;
  }
}

/* Style the navigation links as buttons */
.nav-links li {
  margin: 0 15px;
  list-style: none;
}

.nav-links a {
  display: inline-block;
  padding: 10px 20px;
  background-color: #333;
  color: white;
  text-decoration: none;
  font-size: 1.2rem;
  border-radius: 5px;
  text-transform: uppercase; /* Make the text uppercase for button effect */
  transition: transform 0.3s ease, background-color 0.3s ease,
    box-shadow 0.3s ease; /* Add animation transitions */
}

.nav-links a:hover {
  background-color: #555;
  transform: translateY(-3px); /* Lift the button up */
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1); /* Add subtle shadow for hover effect */
}

/* Add a slight animation effect when the page loads */
.nav-links a {
  opacity: 0;
  animation: fadeIn 0.6s forwards;
}

.nav-links a:nth-child(1) {
  animation-delay: 0.2s;
}
.nav-links a:nth-child(2) {
  animation-delay: 0.4s;
}
.nav-links a:nth-child(3) {
  animation-delay: 0.6s;
}
.nav-links a:nth-child(4) {
  animation-delay: 0.8s;
}

/* Keyframe animation for fade-in effect */
@keyframes fadeIn {
  to {
    opacity: 1;
  }
}
/* Style the product links to look like buttons */
.product-category ul li a {
  display: inline-block;
  padding: 12px 20px;
  background-color: #333;
  color: white;
  text-decoration: none;
  font-size: 1rem;
  border-radius: 5px;
  margin: 8px 0;
  text-align: center;
  transition: transform 0.3s ease, background-color 0.3s ease,
    box-shadow 0.3s ease; /* Animation */
}

/* Hover effect for product links */
.product-category ul li a:hover {
  background-color: #555;
  transform: translateY(-3px); /* Lift the button effect */
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1); /* Add shadow effect */
}

/* Animation for the product links */
.product-category ul li a {
  opacity: 0;
  list-style-type: none;
  display: block;
  animation: fadeIn 0.6s forwards;
}

/* Initially hide subcategory lists */
.product-list-hidden {
  display: none;
  opacity: 0;
  transition: opacity 0.3s ease;
}

/* When subcategory list is visible */
.product-list-visible {
  display: block;
  opacity: 1;
}

/* Style for the main category titles */
.category-title {
  cursor: pointer;
  padding: 10px;
  background-color: white;
  color: #444;
  border-radius: 5px;
  text-align: center;
  font-size: 1.5rem;
  margin-bottom: 10px;
  transition: background-color 0.3s ease;
}

.category-title:hover {
  background-color: white;
}

/* Style for subcategory titles */
.subcategory-title {
  cursor: pointer;
  padding: 8px;
  background-color: #444;
  color: white;
  font-size: 1.2rem;
  margin-top: 5px;
  border-radius: 5px;
  transition: background-color 0.3s ease;
}

.subcategory-title:hover {
  background-color: #666;
}

/* Keyframe animation for fade-in effect */
@keyframes fadeIn {
  to {
    opacity: 1;
  }
}
