/* Base Styles & Variables */
:root {
  --primary-color: #1e7e34; /* Rich Dark Green */
  --primary-dark: #155724; /* Even Darker Green */
  --primary-light: #d4edda; /* Light Green */
  --secondary-color: #000000; /* Black */
  --light-color: #ffffff; /* White */
  --text-color: #333333;
  --light-gray: #f5f5f5;
  --medium-gray: #dddddd;
  --dark-gray: #777777;
  --font-primary: "Montserrat", sans-serif;
  --font-secondary: "Montserrat", sans-serif;
  --transition: all 0.3s ease;
}

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

body {
  font-family: var(--font-primary);
  color: var(--text-color);
  line-height: 1.6;
  overflow-x: hidden;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

section {
  padding: 80px 0;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-secondary);
  margin-bottom: 20px;
  color: var(--secondary-color);
}

h1 {
  font-size: 2.8rem;
  line-height: 1.2;
}

h2 {
  font-size: 2.2rem;
}

h3 {
  font-size: 1.8rem;
}

p {
  margin-bottom: 15px;
  font-size: 1rem;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition);
}

ul {
  list-style: none;
}

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

#preloader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--light-color);
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: opacity 0.3s ease;
}

#preloader.fade-out {
  opacity: 0;
}

.loader {
  width: 40px;
  height: 40px;
  border: 3px solid var(--primary-color);
  border-bottom-color: transparent;
  border-radius: 50%;
  display: inline-block;
  box-sizing: border-box;
  animation: rotation 0.8s linear infinite;
}

@keyframes rotation {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* Buttons */
.cta-button,
.secondary-button {
  display: inline-block;
  padding: 12px 30px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  border-radius: 4px;
  transition: var(--transition);
  font-size: 0.9rem;
  text-align: center;
}

.cta-button {
  background-color: var(--primary-color);
  color: var(--light-color);
  border: 2px solid var(--primary-color);
}

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

.secondary-button {
  background-color: transparent;
  color: var(--light-color);
  border: 2px solid var(--light-color);
  margin-left: 15px;
}

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

.section-header {
  text-align: center;
  margin-bottom: 50px;
}

.section-header p {
  font-size: 1.1rem;
  color: var(--dark-gray);
}

/* Header & Navigation */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background-color: var(--light-color);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  transition: var(--transition);
}

.header.scrolled {
  background-color: rgba(255, 255, 255, 0.95);
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 0;
}

.logo img {
  height: 50px;
  width: auto;
}

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

.nav-item {
  margin-left: 30px;
  position: relative;
}

.nav-link {
  font-weight: 500;
  color: var(--secondary-color);
  transition: var(--transition);
  position: relative;
}

.nav-link:hover {
  color: var(--primary-color);
}

.nav-link:after {
  content: "";
  position: absolute;
  width: 0;
  height: 2px;
  background: var(--primary-color);
  bottom: -5px;
  left: 0;
  transition: var(--transition);
}

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

.nav-link.cta-button {
  padding: 10px 20px;
  border-radius: 4px;
  color: var(--light-color);
  background-color: var(--primary-color);
}

.nav-link.cta-button:hover {
  color: var(--primary-color);
  background-color: var(--light-color);
}

.nav-link.cta-button:after {
  display: none;
}

.nav-link.active {
  color: var(--primary-color) !important;
}

.nav-link.active:after {
  width: 100% !important;
  background-color: var(--primary-color) !important;
}

.hamburger {
  display: none;
  cursor: pointer;
  z-index: 1002;
}

.bar {
  display: block;
  width: 25px;
  height: 3px;
  margin: 5px auto;
  background-color: var(--secondary-color);
  transition: var(--transition);
}

/* Hero Section */
.hero {
  position: relative;
  height: 100vh;
  min-height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--light-color);
  overflow: hidden;
  margin-top: 80px; /* To account for fixed header */
}

.hero-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  background-image: url("../img/main-backup.jpg");
  background-size: cover;
  background-position: center;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(42, 57, 46, 0.6); /* Darker green overlay */
}

.hero-content {
  max-width: 800px;
  padding: 0 20px;
  z-index: 1;
}

.hero-content h1 {
  font-size: 3.5rem;
  margin-bottom: 20px;
  color: var(--light-color);
  text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
}

.hero-content p {
  font-size: 1.3rem;
  margin-bottom: 30px;
  color: var(--light-color);
}

.hero-buttons {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
}

/* About Section */
.about-section {
  background-color: var(--light-color);
}

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

.about-text {
  flex: 1;
}

.about-image {
  flex: 1;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.about-image img {
  width: 100%;
  height: auto;
  display: block;
  transition: var(--transition);
}

.about-features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin-top: 30px;
}

.feature {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 500;
}

.feature i {
  color: var(--primary-color);
  font-size: 1.2rem;
}

/* Featured Products Section */
.featured-section {
  background-color: var(--primary-light);
  padding: 80px 0;
}

.featured-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.featured-item {
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  transition: var(--transition);
  background-color: var(--light-color);
}

.featured-image {
  height: 250px;
  overflow: hidden;
}

.featured-content {
  padding: 20px;
}

.featured-content h3 {
  margin-bottom: 10px;
  color: var(--secondary-color);
  font-size: 1.5rem;
}

.featured-content p {
  color: var(--text-color);
  margin-bottom: 0;
}

/* Services Section */
.services-section {
  background-color: var(--light-color);
}

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

.service-card {
  background-color: var(--primary-light);
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  transition: var(--transition);
  border: 1px solid var(--medium-gray);
}

.service-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
  border-color: var(--primary-color);
}

.service-icon {
  width: 60px;
  height: 60px;
  background-color: var(--primary-color);
  color: var(--light-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 20px;
}

.service-card h3 {
  margin-bottom: 15px;
  color: var(--secondary-color);
}

.service-card ul {
  margin-top: 20px;
}

.service-card ul li {
  position: relative;
  padding-left: 20px;
  margin-bottom: 10px;
}

.service-card ul li:before {
  content: "";
  position: absolute;
  left: 0;
  top: 10px;
  width: 8px;
  height: 8px;
  background-color: var(--primary-color);
  border-radius: 50%;
}

/* Reviews Section */
.reviews-section {
  background-color: var(--primary-light);
}

.reviews-slider {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.review-card {
  background-color: var(--light-color);
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.review-stars {
  color: var(--primary-color);
  margin-bottom: 15px;
}

.review-text {
  font-style: italic;
  margin-bottom: 20px;
}

.review-author {
  font-weight: 600;
  color: var(--secondary-color);
}

/* FAQ Section */
.faq-section {
  background-color: var(--light-color);
}

.faq-accordion {
  max-width: 800px;
  margin: 0 auto;
}

.accordion-item {
  margin-bottom: 15px;
  border: 1px solid var(--medium-gray);
  border-radius: 8px;
  overflow: hidden;
}

.accordion-button {
  width: 100%;
  padding: 20px;
  text-align: left;
  background-color: var(--light-color);
  border: none;
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--secondary-color);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: var(--transition);
}

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

.accordion-button i {
  transition: var(--transition);
}

.accordion-button.active i {
  transform: rotate(180deg);
}

.accordion-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
  padding: 0 20px;
  background-color: var(--primary-light);
}

.accordion-content p {
  padding: 20px 0;
}

/* Contact Section */
.contact-section {
  background-color: var(--primary-color);
  color: var(--light-color);
}

.contact-container {
  display: flex;
  gap: 50px;
}

.contact-info {
  flex: 1;
}

.contact-info h2 {
  color: var(--light-color);
}

.contact-map {
  flex: 1;
  height: 400px;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.contact-map iframe {
  width: 100%;
  height: 100%;
  border: none;
}

.info-item {
  display: flex;
  align-items: center;
  margin-bottom: 20px;
}

.info-item i {
  width: 40px;
  height: 40px;
  background-color: var(--light-color);
  color: var(--primary-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 15px;
  font-size: 1rem;
}

.info-item a {
  color: var(--light-color);
  transition: var(--transition);
}

.info-item a:hover {
  text-decoration: none;
  color: var(--secondary-color);
}

/* Footer */
.footer {
  background-color: var(--light-color);
  color: var(--secondary-color);
  padding: 60px 0 0;
  position: relative;
  margin-top: auto;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 40px;
  margin-bottom: 40px;
}

.footer-logo img {
  height: 50px;
  margin-bottom: 20px;
}

.footer-logo p {
  margin-bottom: 20px;
  color: var(--dark-gray);
}

.social-links {
  display: flex;
  gap: 15px;
}

.social-links a {
  width: 40px;
  height: 40px;
  background-color: var(--primary-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.social-links a:hover {
  background-color: var(--primary-color);
  color: var(--light-color);
}

.footer-links h3,
.footer-services h3,
.footer-contact h3 {
  color: var(--secondary-color);
  margin-bottom: 25px;
  font-size: 1.3rem;
  position: relative;
  padding-bottom: 10px;
}

.footer-links h3:after,
.footer-services h3:after,
.footer-contact h3:after {
  content: "";
  position: absolute;
  width: 50px;
  height: 2px;
  background-color: var(--primary-color);
  bottom: 0;
  left: 0;
}

.footer-links ul li,
.footer-services ul li {
  margin-bottom: 12px;
}

.footer-links a,
.footer-services a {
  color: var(--dark-gray);
  transition: var(--transition);
}

.footer-links a:hover,
.footer-services a:hover {
  color: var(--primary-color);
  padding-left: 5px;
}

.footer-contact ul li {
  margin-bottom: 15px;
  display: flex;
  align-items: center;
  color: var(--dark-gray);
}

.footer-contact ul li i {
  margin-right: 10px;
  color: var(--primary-color);
  width: 20px;
  text-align: center;
}

.footer-bottom {
  border-top: 1px solid var(--medium-gray);
  padding: 20px 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  gap: 10px;
  position: relative;
  z-index: 1;
}

.footer-bottom p {
  margin-bottom: 0;
  color: var(--dark-gray);
}

.footer-bottom a {
  color: var(--primary-color);
  font-weight: 600;
}

.footer-bottom a:hover {
  color: var(--primary-dark);
}

/* Back to Top Button */
#backToTop {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 50px;
  height: 50px;
  background-color: var(--primary-color);
  color: var(--light-color);
  border: none;
  border-radius: 50%;
  font-size: 1.2rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
  z-index: 999;
}

#backToTop:hover {
  background-color: var(--primary-dark);
  transform: translateY(-5px);
}

#backToTop.show {
  opacity: 1;
  visibility: visible;
}

/* Mobile Menu Styles */
@media (max-width: 768px) {
  .hamburger {
    display: block;
  }

  .hamburger.active .bar:nth-child(2) {
    opacity: 0;
  }

  .hamburger.active .bar:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
  }

  .hamburger.active .bar:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
  }

  .nav-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-color: var(--light-color);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    transition: var(--transition);
    transform: translateX(-100%);
    z-index: 1001;
    padding: 0;
  }

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

  .nav-item {
    margin: 15px 0;
    width: 100%;
  }

  .nav-link {
    display: block;
    padding: 15px;
    font-size: 1.2rem;
    color: var(--secondary-color);
    width: 100%;
  }

  .nav-link.cta-button {
    margin: 20px auto;
    width: 80%;
    max-width: 300px;
    padding: 15px;
  }

  /* Remove underline for active links in mobile menu */
  .nav-link.active::after {
    display: none;
  }

  body.menu-open {
    overflow: hidden;
  }

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

  .hero-content p {
    font-size: 1.1rem;
  }

  .hero-buttons {
    flex-direction: column;
    gap: 15px;
  }

  .secondary-button {
    margin-left: 0;
  }

  section {
    padding: 60px 0;
  }

  /* About Section Mobile Fix */
  .about-content {
    flex-direction: column;
    gap: 30px;
  }

  .about-image {
    width: 100%;
    margin-top: 20px;
  }

  .about-image img {
    width: 100%;
    height: auto;
    min-height: 250px;
    object-fit: cover;
  }

  .contact-map {
    height: 300px;
  }

  /* Footer Mobile Fix */
  .footer {
    padding-bottom: 20px;
  }

  .footer-bottom {
    padding: 20px 15px;
    font-size: 0.85rem;
    position: relative;
    z-index: 10;
  }

  #backToTop {
    bottom: 70px;
    right: 20px;
    width: 45px;
    height: 45px;
  }
}

@media (max-width: 576px) {
  .hero-content h1 {
    font-size: 1.8rem;
  }

  h2 {
    font-size: 1.8rem;
  }

  .footer-content {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  #backToTop {
    bottom: 60px;
    right: 15px;
    width: 40px;
    height: 40px;
    font-size: 1rem;
  }
}
