/* nav.css — shared navigation component */

.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 20px var(--page-px);
  background-color: var(--color-cream);
  max-width: 1440px;
  margin: 0 auto;
}

.nav__logo {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  width: 115px;
}

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

.nav__menu {
  display: flex;
  align-items: center;
  gap: clamp(20px, 3.5vw, 50px);
}

.nav__link {
  font-size: 18px;
  font-weight: var(--fw-regular);
  line-height: 100%;
  color: var(--color-forest);
  white-space: nowrap;
  transition: opacity 0.15s ease;
}

.nav__link--active {
  font-weight: 700 !important;
}

.nav__link:hover {
  opacity: 0.6;
}

.nav__lang {
  font-size: 18px;
  font-weight: var(--fw-regular);
  line-height: 100%;
  color: var(--color-forest);
  white-space: nowrap;
}

.nav__lang--active {
  font-weight: var(--fw-semibold);
  text-decoration: underline;
  text-decoration-style: solid;
}

.nav__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 22px;
  background-color: var(--color-forest);
  color: var(--color-white);
  border-radius: 6px;
  font-size: 18px;
  font-weight: var(--fw-regular);
  line-height: 100%;
  white-space: nowrap;
  transition: opacity 0.2s ease;
}

.nav__cta:hover {
  opacity: 0.85;
}

/* ---- Hamburger toggle (hidden on desktop) ---- */
.nav__toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 32px;
  height: 32px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  z-index: 110;
}

.nav__toggle-bar {
  display: block;
  width: 100%;
  height: 2px;
  background-color: var(--color-forest);
  border-radius: 2px;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

/* ---- Tablet ---- */
@media (max-width: 1024px) {
  .nav__menu {
    gap: 28px;
  }

  .nav__link {
    font-size: 16px;
  }

  .nav__lang {
    font-size: 16px;
  }

  .nav__cta {
    font-size: 16px;
    padding: 10px 18px;
  }

  .nav__logo {
    width: 90px;
  }
}

/* ---- Mobile ---- */
@media (max-width: 768px) {
  .nav {
    align-items: center;
    padding: 16px var(--page-px);
  }

  .nav__logo {
    width: 70px;
  }

  .nav__toggle {
    display: flex;
  }

  .nav__menu {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--color-cream);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 32px;
    z-index: 105;
    padding: 80px 20px 40px;
  }

  .nav__menu.nav__menu--open {
    display: flex;
  }

  .nav__link {
    font-size: 24px;
  }

  .nav__lang {
    font-size: 20px;
  }

  .nav__cta {
    font-size: 20px;
    padding: 14px 28px;
  }

  /* Animate hamburger → X */
  .nav__toggle--active .nav__toggle-bar:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
  }

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

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