header {
  background: #fff;
  padding: 10px 20px;
  height: 80px;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 10;
}

.navbar {
  height: 70px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
}

.logo a {
  display: flex;
  height: fit-content;
}

.logo img {
    height: 60px;
    width: auto;
}

.nav-right {
    display: flex;
    align-items: center;
    flex: 1;
    justify-content: center;
}

.menu {
    flex-grow: 1;
    display: flex;
    justify-content: center;
}

.menu ul {
    display: flex;
    gap: 60px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.menu a {
    color: #999999;
    font-family: 'Work Sans', sans-serif;
    font-weight: 600;
    font-size: 18px;
    letter-spacing: 0.5px;
    text-decoration: none;
    position: relative;
    transition: color 0.3s ease;
}

.menu a:hover {
    color: #4849E8;
}

.menu a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 3px;
    background-color: #4849E8;
    border-radius: 2px;
    transition: width 0.3s ease-in-out;
}

.menu a:hover::after {
    width: 100%;
}

.menu a.active {
    color: #4849E8;
}

.menu a.active::after {
    width: 100%;
}


.lang-desktop {
    margin-left: 20px;
    position: relative;
}

.language-switch {
    display: flex;
    align-items: center;
}

.language-switch:active {
  -webkit-tap-highlight-color: transparent !important;
}

.toggle-checkbox {
  display: none;
}

.toggle-label {
    display: inline-block;
    position: relative;
    width: 100px;
    height: 40px;
    background-color: #f0f0f0;
    border-radius: 25px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    overflow: hidden;
    box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.1);
}

.toggle-inner {
    position: absolute;
    width: 200%;
    height: 100%;
    left: 0;
    top: 0;
    display: flex;
    transition: transform 0.3s ease;
}

.toggle-checkbox:checked + .toggle-label .toggle-inner {
    transform: translateX(-50%);
}

.toggle-hu, .toggle-en {
    width: 50%;
    height: 100%;
    display: flex;
    align-items: center;
    gap: 5px;
    font-weight: 600;
    font-size: 14px;
    color: #4849E8;
}

.toggle-en {
  justify-content: start;
  padding-left: 10px;
  background-color: rgba(153, 153,153, 0.04);
}

.toggle-hu {
  justify-content: end;
  padding-right: 10px;
  border-radius: 8px;
  background-color: rgba(153, 153, 153, 0.04);
}

.toggle-switch {
    position: absolute;
    top: 3px;
    left: 3px;
    width: 34px;
    height: 34px;
    background-color: #fff;
    border-radius: 50%;
    transition: transform 0.3s ease;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
}

.toggle-checkbox:checked + .toggle-label .toggle-switch {
    transform: translateX(60px);
}

.toggle-label img {
    width: 20px;
    height: auto;
}

.hamburger {
    display: none;
    font-size: 28px;
    cursor: pointer;
    color: white;
    width: 30px;
    height: 25px;
    position: relative;
}

.hamburger .bar {
    display: block;
    width: 100%;
    height: 3px;
    background-color: #4849E8;
    border-radius: 2px;
    position: absolute;
    left: 0;
    transition: transform 0.3s ease-in-out, opacity 0.3s ease-in-out;
}

.hamburger .top-bar {
    top: 0;
}

.hamburger .middle-bar {
    top: 50%;
    transform: translateY(-50%);
}

.hamburger .bottom-bar {
    bottom: 0;
}

.hamburger.active .top-bar {
    transform: rotate(45deg) translate(7px, 7px);
}

.hamburger.active .middle-bar {
    opacity: 0;
}

.hamburger.active .bottom-bar {
    transform: rotate(-45deg) translate(7px, -7px);
}

@media (max-width: 1240px) {
  .logo img {
    height: 40px;
  }
  
  .nav-right {
    display: none;
    position: absolute;
    top: 60px;
    right: 32px;
    width: 280px;
    background: rgba(240, 240, 240, 0.75);
    backdrop-filter: blur(10px);
    z-index: 100;
    flex-direction: column;
    align-items: center;
    text-align: center;
    border-radius: 8px;
    box-shadow: 4px 16px 25px rgba(72, 73, 232, 0.15);
  }

  .nav-right.active {
    display: unset;
  }

  .hamburger {
    display: block;
    max-width: 300px;
  }

  .menu,
  .lang-desktop {
    max-width: 300px;
    display: block;
    width: 100%;
    display: flex;
    justify-content: space-around;
    margin-left: 0;
  }

  .lang-desktop {
    margin: 20px 0;
  }

  .toggle-en {
    background-color: rgba(72, 73, 232, 0.1);
  }

  .toggle-hu {
    background-color: rgba(72, 73, 232, 0.1);
  }

  .menu ul {
    width: 100%;
    flex-direction: column;
    align-items: center;
    gap: 8px;
  }

  .menu a {
    color: #4849E8;
  }

  .menu ul li {
    padding: 12px;
  }
}