/* Top Bar Styles */
.top-bar {
  background-color: var(--light-gray);
  font-size: 0.9rem;
  padding: 0.8rem 1rem;
}

/* Mobile styles (default) */
@media (max-width: 767px) {
  .top-bar {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.8rem;
  }

  .top-links {
    display: flex;
    flex-direction: row;
  }

  .top-links button {
    margin-left: 0;
    margin-right: 1rem;
    text-decoration: none;
    font-weight: 500;
    background-color: transparent;
    border: none;
  }

  /* Hide sign in link on mobile */
  .top-links .green {
    display: none;
  }
}

/* Desktop styles */
@media (min-width: 768px) {
  .top-bar {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    padding: 0.8rem 5rem;
  }

  .top-links {
    display: block;
  }

  .top-links button {
    margin-left: 1rem;
    text-decoration: none;
    font-weight: 500;
    border: none;
    background-color: transparent;
  }
}

/* Link colors */
.top-links .blue {
  color: var(--blue);
}

.top-links .orange {
  color: var(--orange);
}

.top-links .green {
  color: var(--green);
}

/* Navbar Styles */
.main-nav {
  background-color: var(--white);
  padding: 0.8rem 0;
  box-shadow: rgba(0, 0, 0, 0.15) 0px 2px 8px;
  position: relative;
  z-index: 10000;
}

.navbar-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1440px;
  width: 100%;
  margin: 0 auto;
  padding: 0 1rem;
  box-sizing: border-box;
}

.logo-img {
  width: 3rem;
  height: 3rem;
  margin-bottom: -1rem;
  object-fit: cover;
}

.menu-toggle {
  display: none;
}

.menu-icon {
  display: block;
  cursor: pointer;
  border-radius: 50%;
  padding: 0.8rem;
  border: 1px solid var(--green);
  width: 45px;
  height: 45px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  transition: all 0.3s ease;
}

.menu-line {
  display: block;
  width: 25px;
  height: 3px;
  background-color: var(--green);
  margin: 2px 0;
  transition: all 0.3s ease;
  transform-origin: center;
}
/* Animation for the menu icon when it's toggled */
.menu-toggle:checked ~ label .menu-line:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.menu-toggle:checked ~ label .menu-line:nth-child(2) {
  opacity: 0;
}

.menu-toggle:checked ~ label .menu-line:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

.navbar-menu {
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  background-color: var(--light-gray);
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
  z-index: 100;
}

.menu-toggle:checked ~ .navbar-menu {
  max-height: 500px;
  box-shadow: 0 6px 10px rgba(0, 0, 0, 0.1);
}

.navbar-nav {
  list-style: none;
  padding: 1rem;
  margin-bottom: 0rem;
}

.nav-item {
  /* margin-bottom: 0.8rem; */
}

.nav-link {
  color: var(--text);
  text-decoration: none;
  font-weight: 500;
  display: block;
  padding: 1.5rem 0;
}

.nav-link.active {
  color: var(--green);
}

.dropdown {
  position: relative;
}

.dropdown-toggle {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.dropdown-arrow {
  font-size: 0.7rem;
}

.dropdown-menu {
  display: none;
  list-style: none;
  background-color: var(--white);
  padding: 0.5rem 0;
  margin-top: 0.5rem;
  margin-left: 1rem;
}

.dropdown:hover .dropdown-menu {
  display: block;
}

.dropdown-item {
  color: var(--text);
  text-decoration: none;
  padding: 0.5rem 1rem;
  display: block;
}

.dropdown-item:hover {
  background-color: var(--light-gray);
}

@media (min-width: 768px) {
  .logo-img {
    margin-bottom: 0rem;
  }
  .menu-icon {
    display: none;
  }
  .navbar-container {
    justify-content: space-between;
  }

  .nav-item {
    margin-bottom: 0rem;
  }
  .nav-link.active {
    color: var(--green);
    border-bottom: 3px solid var(--green);
  }

  .navbar-brand {
    margin-right: 2rem;
    margin-bottom: 0rem;
  }

  .navbar-menu {
    position: static;
    max-height: none;
    overflow: visible;
    background-color: transparent;
    flex: 1;
    display: flex;
    justify-content: flex-end;
  }

  .navbar-nav {
    display: flex;
    padding: 0;
    margin-left: auto;
  }
  .nav-link {
    padding: 0.5rem 1.4rem;
  }

  .dropdown-menu {
    position: absolute;
    left: 0;
    top: 100%;
    min-width: 200px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
    margin-left: 0;
  }
}
