nav {
  padding: 1rem 5%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.08);
  position: sticky;
  top: 0;
  z-index: 999;
  transition: all 0.3s ease;
}

nav.scrolled {
  padding: 0.75rem 5%;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.12);
}

nav .logo {
  display: flex;
  align-items: center;
  /* gap: 12px; */
  cursor: pointer;
  transition: transform 0.3s ease;
}

nav .logo:hover {
  transform: translateY(-2px);
}

nav .logo img {
  height: 90px;
  width: auto;
  transition: transform 0.3s ease;
}

nav .logo:hover img {
  transform: rotate(5deg);
}

nav .logo h1 {
  font-family: "Space Grotesk", sans-serif;
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.5px;
  color: #0b8035;

  position: relative;
}

nav ul {
  list-style: none;
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

nav ul li a {
  font-family: "Inter", sans-serif;
  text-decoration: none;
  color: #2d482d;
  font-size: 0.95rem;

  padding: 0.65rem 1.25rem;
  border-radius: 12px;
  transition: all 0.3s ease;
  position: relative;
  letter-spacing: -0.2px;
}

nav ul li a::before {
  content: "";
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%) scaleX(0);
  width: 60%;
  height: 2px;
  background: linear-gradient(90deg, #6aea66, #4ba257);
  border-radius: 2px;
  transition: transform 0.3s ease;
}

nav ul li a:hover {
  background: linear-gradient(
    135deg,
    rgba(102, 234, 150, 0.1),
    rgba(147, 251, 159, 0.1)
  );
  color: #133917;
  transform: translateY(-2px);
}

nav ul li a:hover::before {
  transform: translateX(-50%) scaleX(1);
}

nav ul li a.active {
  background: linear-gradient(135deg, #66ea87, #57a24b);
  color: white;
  box-shadow: 0 4px 15px rgba(102, 234, 146, 0.4);
}

.hamburger {
  display: none;
  cursor: pointer;
  padding: 8px;
  border-radius: 8px;
  transition: background 0.3s ease;
}

.hamburger:hover {
  background: rgba(102, 234, 104, 0.1);
}

.hamburger .line {
  width: 28px;
  height: 3px;
  background: linear-gradient(90deg, #66ea73, #5ba24b);
  display: block;
  margin: 6px auto;
  border-radius: 3px;
  transition: all 0.3s ease-in-out;
}

.hamburger-active {
  transition: all 0.3s ease-in-out;
  transition-delay: 0.6s;
  transform: rotate(45deg);
}

.hamburger-active .line:nth-child(2) {
  width: 0px;
  opacity: 0;
}

.hamburger-active .line:nth-child(1),
.hamburger-active .line:nth-child(3) {
  transition-delay: 0.3s;
}

.hamburger-active .line:nth-child(1) {
  transform: translateY(9px);
}

.hamburger-active .line:nth-child(3) {
  transform: translateY(-9px) rotate(90deg);
}

.menubar {
  position: fixed;
  top: 0;
  left: -100%;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  height: 100vh;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(20px);
  transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  z-index: 998;
}

.active {
  left: 0;
}

.menubar ul {
  padding: 0;
  list-style: none;
  text-align: center;
}

.menubar ul li {
  margin-bottom: 2rem;
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 0.5s ease forwards;
}

.active .menubar ul li {
  opacity: 1;
  transform: translateY(0);
}

.menubar ul li:nth-child(1) {
  animation-delay: 0.1s;
}
.menubar ul li:nth-child(2) {
  animation-delay: 0.2s;
}
.menubar ul li:nth-child(3) {
  animation-delay: 0.3s;
}
.menubar ul li:nth-child(4) {
  animation-delay: 0.4s;
}

.menubar ul li a {
  font-family: "Space Grotesk", sans-serif;
  text-decoration: none;
  color: #2d4835;
  font-size: 1.8rem;
  font-weight: 600;
  padding: 1rem 2rem;
  border-radius: 16px;
  transition: all 0.3s ease;
  display: inline-block;
  letter-spacing: -0.5px;
}

.menubar ul li a:hover {
  background: linear-gradient(135deg, #66ea83, #4ba257);
  color: white;
  transform: scale(1.05);
  box-shadow: 0 10px 30px rgba(102, 234, 124, 0.3);
}

@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media screen and (max-width: 790px) {
  .hamburger {
    display: block;
  }

  nav ul {
    display: none;
  }

  nav .logo h1 {
    font-size: 1.5rem;
  }

  nav .logo img {
    height: 80px;
  }

  nav {
    padding: 0.75rem 5%;
  }
}

@media screen and (max-width: 480px) {
  nav .logo h1 {
    font-size: 1.5rem;
  }

  nav .logo img {
    height: 70px;
  }

  .menubar ul li a {
    font-size: 1.5rem;
  }
}
