/* Base Variables */
:root {
  --primary-color: #1a3d2f; /* Dark Green */
  --secondary-color: #e8f5e9; /* Light Green */
  --accent-color: #00bfa5;    /* Teal Accent */
  --background-color: #ffffff;
  --text-color: #2e2e2e;
  --light-gray: #f0f0f0;
  --dark-gray: #333333;
  --white: #ffffff;
  --font-primary: 'Poppins', sans-serif;
  --font-secondary: 'Roboto', sans-serif;
}

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

body {
  font-family: var(--font-primary);
  background-color: var(--background-color);
  color: var(--text-color);
  scroll-behavior: smooth;
  line-height: 1.6;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

ul, ol {
  list-style: none;
}

a {
  color: var(--primary-color);
  text-decoration: none;
  transition: color 0.3s ease, transform 0.3s ease;
}

a:hover {
  color: var(--accent-color);
  transform: translateY(-2px);
}

.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  color: var(--dark-gray);
  font-family: var(--font-primary);
  line-height: 1.2;
}

h1 {
  font-size: 3rem;
  margin-bottom: 20px;
}

h2 {
  font-size: 2.5rem;
  margin-bottom: 20px;
}

h3 {
  font-size: 1.8rem;
  margin-bottom: 15px;
}

p {
  font-size: 1rem;
  margin-bottom: 15px;
  color: var(--text-color);
}

strong {
  font-weight: 600;
}

.btn {
  display: inline-block;
  padding: 12px 30px;
  border-radius: 50px;
  font-size: 1rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1px;
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.3s ease;
  border: none;
}

.btn-primary {
  background-color: var(--accent-color);
  color: var(--white);
}

.btn-primary:hover {
  background-color: var(--primary-color);
  transform: translateY(-3px);
}

.btn-gradient {
  background: linear-gradient(45deg, var(--primary-color), var(--accent-color));
  color: var(--white);
}

.btn-gradient:hover {
  opacity: 0.9;
  transform: translateY(-3px);
}

.btn:active {
  transform: translateY(1px);
}

/* Header */
header {
  background-color: var(--white);
  position: fixed;
  width: 100%;
  top: 0;
  z-index: 999;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.main-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
}

.logo img {
  height: 60px;
  transition: transform 0.3s ease;
}

.logo img:hover {
  transform: scale(1.05);
}

.nav {
  display: flex;
  align-items: center;
}

.nav div {
  display: flex;
  gap: 30px;
}

.nav a {
  font-size: 1rem;
  position: relative;
  padding: 5px 0;
}

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

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

.nav-icons {
  display: flex;
  align-items: center;
  gap: 25px;
  margin-left: 20px;
}

.icon-link {
  position: relative;
  color: var(--dark-gray);
  cursor: pointer;
  transition: color 0.3s ease;
}

.icon-link:hover {
  color: var(--accent-color);
}

.icon-link img {
  height: 28px;
  filter: grayscale(100%);
  transition: filter 0.3s ease, transform 0.3s ease;
}

.icon-link:hover img {
  filter: none;
  transform: scale(1.1);
}

.tooltip {
  visibility: hidden;
  opacity: 0;
  background-color: var(--dark-gray);
  color: var(--white);
  text-align: center;
  border-radius: 5px;
  padding: 5px 10px;
  position: absolute;
  bottom: -45px;
  left: 50%;
  transform: translateX(-50%);
  transition: opacity 0.3s ease;
  font-size: 0.9rem;
  white-space: nowrap;
}

.icon-link:hover .tooltip {
  visibility: visible;
  opacity: 1;
}

.cart-count {
  position: absolute;
  top: -10px;
  right: -10px;
  background-color: var(--accent-color);
  color: var(--white);
  border-radius: 50%;
  padding: 2px 7px;
  font-size: 0.8rem;
  display: none; /* Initially hidden */
}

.cart-icon .cart-count {
  display: block;
}

.icon {
  display: none;
  font-size: 28px;
  cursor: pointer;
  background: none;
  border: none;
  color: var(--dark-gray);
}

.icon i {
  color: var(--dark-gray);
}

.search_field {
  padding: 8px 12px;
  border: 1px solid var(--light-gray);
  border-radius: 30px;
  font-size: 0.9rem;
  margin-left: 20px;
  background-color: #f9f9f9;
  width: 250px;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.search_field:focus {
  border-color: var(--primary-color);
  outline: none;
  box-shadow: 0 0 5px rgba(0, 191, 165, 0.5);
}

/* Hero Section */
.hero {
  position: relative;
  background: linear-gradient(rgba(26, 61, 47, 0.85), rgba(0, 0, 0, 0.65)), url('../images/background2.jpg') center/cover no-repeat;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  text-align: center;
  padding: 0 20px;
}

.hero-content {
  max-width: 800px;
  width: 100%;
  padding: 100px 0;
  margin: 0 auto;
  text-align: center;
  animation: fadeIn 1s ease-in-out;
}

.hero h1 {
  font-size: 4rem;
  margin-bottom: 20px;
  line-height: 1.2;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.8);
  color: var(--white);
}

.hero p {
  font-size: 1.5rem;
  margin-bottom: 30px;
  font-weight: 300;
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.7);
  color: var(--white); /* Ensure the text is visible */
}

.search-bar {
  position: relative;
  max-width: 600px;
  margin: 0 auto 30px auto;
}

.search-input {
  width: 100%;
  padding: 15px 20px;
  border: none;
  border-radius: 50px;
  font-size: 1rem;
  outline: none;
  background-color: rgba(255, 255, 255, 0.9);
}

.search-input::placeholder {
  color: var(--dark-gray);
}

.search-button {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  padding: 8px 12px;
  background-color: var(--accent-color);
  border: none;
  border-radius: 50%;
  color: var(--white);
  font-size: 1.2rem;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.search-button:hover {
  background-color: var(--primary-color);
}

.hero .btn {
  margin-top: 20px;
  background-color: var(--accent-color);
  border: none;
  color: var(--white);
}

.hero .btn:hover {
  background-color: var(--primary-color);
}

/* Categories Section */
.categories-section {
  padding: 60px 0;
  background-color: var(--background-color);
}

.categories-section h2 {
  text-align: center;
  font-size: 2.5rem;
  margin-bottom: 50px;
  position: relative;
}

.categories-section h2::after {
  content: '';
  height: 4px;
  width: 100px;
  background-color: var(--accent-color);
  position: absolute;
  left: 50%;
  bottom: -15px;
  transform: translateX(-50%);
}

.categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 40px;
}

.category-item {
  position: relative;
  overflow: hidden;
  border-radius: 15px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.category-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 25px rgba(0, 0, 0, 0.2);
}

.category-item img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.category-item img {
  aspect-ratio: 4/3;
}

.category-item:hover img {
  transform: scale(1.1);
}

.category-item h3 {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  color: var(--white);
  font-size: 1.8rem;
  text-shadow: 0 2px 5px rgba(0, 0, 0, 0.7);
  z-index: 2;
  text-align: center;
  width: calc(100% - 40px);
}

.category-item p {
  display: none;
}

.category-item::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  transition: background 0.5s ease;
  z-index: 1;
}

.category-item:hover::after {
  background: rgba(0, 0, 0, 0.6);
}

.category-item:hover h3 {
  color: var(--accent-color);
}

/* About Section */
.about-section {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 80px 0;
  background-color: var(--secondary-color);
  position: relative;
  overflow: hidden;
}

.about-section::before {
  content: '';
  position: absolute;
  top: -100px;
  right: -100px;
  width: 200px;
  height: 200px;
  background-color: var(--accent-color);
  border-radius: 50%;
  opacity: 0.1;
}

.about-content {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 30px;
}

.about-image {
  flex: 1;
  text-align: center;
}

.about-image img {
  width: 100%;
  max-width: 500px; /* Make the image smaller */
  height: auto;
  border-radius: 15px;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
}

.text-content {
  flex: 1;
}

.text-content h2 {
  font-size: 2.5rem;
  margin-bottom: 25px;
  font-weight: 700;
  color: var(--primary-color);
}

.text-content p {
  font-size: 1.2rem;
  margin-bottom: 30px;
  font-family: var(--font-secondary);
}

.text-content .btn {
  background-color: var(--primary-color);
  color: var(--white);
}

.text-content .btn:hover {
  background-color: var(--accent-color);
}

/* Services Section */
.services-section {
  padding: 80px 0;
  background-color: var(--background-color);
}

.services-section h2 {
  text-align: center;
  font-size: 2.5rem;
  margin-bottom: 50px;
  position: relative;
}

.services-section h2::after {
  content: '';
  height: 4px;
  width: 100px;
  background-color: var(--accent-color);
  position: absolute;
  left: 50%;
  bottom: -15px;
  transform: translateX(-50%);
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px;
}

.service-item {
  background-color: var(--secondary-color); /* Changed background color */
  border-radius: 15px;
  padding: 30px 25px;
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.service-item:nth-child(even) {
  background-color: var(--white); /* Alternate colors */
}

.service-item:hover {
  transform: translateY(-10px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.service-item img {
  display: block;
  margin: 0 auto 20px auto; /* Centers the image horizontally and adds bottom margin */
  height: 100px;
  width: auto; /* Maintains aspect ratio */
  background-color: transparent; /* Ensures the background is transparent */
  background: none; /* Removes any background */
}

.service-item h3 {
  font-size: 1.6rem;
  margin-bottom: 15px;
  font-weight: 600;
  color: var(--primary-color);
}

.service-item p {
  font-size: 1rem;
  color: var(--dark-gray);
}

/* Advantage Section */
.advantage-section {
  padding: 80px 0;
  background-color: var(--background-color);
}

.advantage-section h2 {
  text-align: center;
  font-size: 2.5rem;
  margin-bottom: 50px;
  position: relative;
}

.advantage-section h2::after {
  content: '';
  height: 4px;
  width: 100px;
  background-color: var(--accent-color);
  position: absolute;
  left: 50%;
  bottom: -15px;
  transform: translateX(-50%);
}

.advantage-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px;
}

.advantage-item {
  background-color: var(--secondary-color); /* Changed background color */
  border-radius: 15px;
  padding: 30px;
  text-align: center;
  transition: transform 0.3s ease;
}

.advantage-item:nth-child(even) {
  background-color: var(--white); /* Alternate colors */
}

.advantage-item:hover {
  transform: translateY(-10px);
}

.advantage-item img {
  display: block;
  margin: 0 auto 20px auto; /* Centers the image horizontally and adds bottom margin */
  height: 100px;
  width: auto; /* Maintains aspect ratio */
  background-color: transparent; /* Ensures the background is transparent */
  background: none; /* Removes any background */
}

.advantage-item h3 {
  font-size: 1.6rem;
  margin-bottom: 15px;
  color: var(--primary-color);
}

.advantage-item p {
  font-size: 1rem;
  color: var(--text-color);
}

/* Contact Section */
.contact-section {
  padding: 80px 0;
  background-color: var(--background-color);
}

.contact-section h2 {
  text-align: center;
  font-size: 2.5rem;
  margin-bottom: 50px;
  position: relative;
}

.contact-section h2::after {
  content: '';
  height: 4px;
  width: 100px;
  background-color: var(--accent-color);
  position: absolute;
  left: 50%;
  bottom: -15px;
  transform: translateX(-50%);
}

.contact-form {
  max-width: 600px;
  margin: 0 auto;
  background-color: var(--white);
  padding: 40px;
  border-radius: 15px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-size: 1rem;
  margin-bottom: 8px;
  color: var(--dark-gray);
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 15px 20px;
  border: 1px solid var(--light-gray);
  border-radius: 30px;
  font-size: 1rem;
  outline: none;
  background-color: #f9f9f9;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: var(--dark-gray);
}

.contact-form input:focus,
.contact-form textarea:focus {
  border-color: var(--accent-color);
  box-shadow: 0 0 10px rgba(0, 191, 165, 0.2);
}

.contact-form button {
  width: 100%;
  padding: 15px;
  border: none;
  background-color: var(--primary-color);
  color: var(--white);
  font-size: 1.1rem;
  border-radius: 50px;
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.3s ease;
}

.contact-form button:hover {
  background-color: var(--accent-color);
  transform: translateY(-3px);
}

.contact-info {
  text-align: center;
  margin-top: 40px;
}

.contact-info p {
  font-size: 1.1rem;
  margin-bottom: 15px;
  color: var(--dark-gray);
}

.contact-info a {
  color: var(--primary-color);
}

.contact-info a:hover {
  color: var(--accent-color);
}

/* Footer */
footer {
  background-color: var(--primary-color);
  color: var(--white);
  padding: 50px 20px 30px 20px;
}

.footer-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 40px;
}

.footer-column {
  flex: 1 1 250px;
  min-width: 200px;
}

.footer-column h3 {
  font-size: 1.6rem;
  margin-bottom: 20px;
  color: var(--white);
}

.footer-column p,
.footer-column a {
  font-size: 1rem;
  margin-bottom: 10px;
  color: var(--white);
  transition: color 0.3s ease;
}

.footer-column a:hover {
  color: var(--accent-color);
}

.footer-column ul {
  list-style: none;
  padding: 0;
}

.footer-column li {
  margin-bottom: 10px;
}

.social-icons {
  display: flex;
  gap: 20px;
}

.social-icons a {
  color: var(--white);
  font-size: 1.8rem;
  transition: color 0.3s ease, transform 0.3s ease;
}

.social-icons a:hover {
  color: var(--accent-color);
  transform: scale(1.1);
}

.footnote {
  text-align: center;
  margin-top: 30px;
  font-size: 0.9rem;
  color: var(--white);
}

.footnote a {
  color: var(--white);
  text-decoration: underline;
}

.footnote a:hover {
  color: var(--accent-color);
}

/* Back-to-Top Button */
#back-to-top {
  position: fixed;
  bottom: 40px;
  right: 40px;
  display: none;
  background-color: var(--accent-color);
  color: var(--white);
  border: none;
  padding: 12px 16px;
  border-radius: 50%;
  cursor: pointer;
  z-index: 1000;
  transition: background-color 0.3s ease, transform 0.3s ease;
}

#back-to-top.show {
  display: block;
}

#back-to-top:hover {
  background-color: var(--primary-color);
  transform: translateY(-3px);
}

#back-to-top i {
  font-size: 1.2rem;
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  } 
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsive Styles */
@media (max-width: 1200px) {
  .about-content {
    flex-direction: row;
  }
}

@media (max-width: 992px) {
  .nav div {
    display: none;
  }

  .icon {
    display: block;
  }

  .nav {
    position: absolute;
    top: 70px;
    left: 0;
    background-color: var(--white);
    width: 100%;
    flex-direction: column;
    display: none;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  }

  .nav.active div {
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 20px;
  }

  .nav-icons {
    margin-top: 20px;
    justify-content: center;
  }

  .categories-grid,
  .services-grid,
  .advantage-grid {
    grid-template-columns: 1fr 1fr;
  }

  .about-content {
    flex-direction: column;
    text-align: center;
    gap: 50px;
  }

  .about-image,
  .text-content {
    flex: 1 1 100%;
  }

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

  .hero p {
    font-size: 1.2rem;
  }

  .search-input {
    width: 90%;
    max-width: none;
  }
}

@media (max-width: 768px) {
  .categories-grid,
  .services-grid,
  .advantage-grid {
    grid-template-columns: 1fr;
  }

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

  .hero p {
    font-size: 1rem;
  }

  .search-input {
    width: 100%;
  }

  .about-content {
    gap: 30px;
  }
}

@media (max-width: 576px) {
  .main-header .container {
    flex-wrap: wrap;
    justify-content: space-between;
  }

  .logo {
    flex: 1 1 100%;
    text-align: center;
    margin-bottom: 20px;
  }

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

  .hero p {
    font-size: 0.9rem;
  }

  .footer-container {
    flex-direction: column;
    align-items: center;
  }

  .footer-column {
    text-align: center;
  }

  .social-icons {
    justify-content: center;
  }

  .search-input {
    width: 100%;
  }
}

/* Additional Styles */
noscript p {
  background-color: var(--light-gray);
  padding: 15px;
  text-align: center;
  font-size: 1rem;
}

.no-js-message {
  display: none;
}

input:required,
textarea:required {
  border-left: 3px solid var(--accent-color);
}

input:invalid,
textarea:invalid {
  border-left: 3px solid var(--primary-color);
}

.ng-invalid.ng-touched {
  border-color: var(--primary-color);
}

.cc-banner {
  background-color: var(--white);
  color: var(--text-color);
  border-top: 1px solid var(--light-gray);
}

.cc-banner .cc-btn {
  background-color: var(--primary-color);
  color: var(--white);
  border-radius: 5px;
  padding: 10px 20px;
}

.cc-banner .cc-btn:hover {
  background-color: var(--accent-color);
}

.ngdialog-content {
  background-color: var(--white);
  border-radius: 10px;
  padding: 20px;
}

.nav.active {
  display: flex;
}

.loader {
  border: 8px solid var(--light-gray);
  border-top: 8px solid var(--primary-color);
  border-radius: 50%;
  width: 60px;
  height: 60px;
  animation: spin 1s linear infinite;
  margin: 0 auto;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
