/* Общий стиль хедера */
.header {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 60px;
  background-color: transparent;
  position: relative;
  z-index: 1000;
  font-family: 'Nunito', sans-serif;
  /* Убираем стандартные отступы у body, если нужно */
  margin: 0 0 20px;
  padding: 20px 0 0;
}

/* Главный контейнер - здесь появляются отступы по бокам 100px */
.header_container {
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
  padding-left: 80px; /* Отступ слева 80px */
  padding-right: 80px; /* Отступ справа 80px */

  display: flex;
  justify-content: space-between; /* Разводим левый и правый блоки по краям */
  align-items: center;
  gap: 20px; /* Отступ между блоками, если они не влезают */
  box-sizing: border-box;
}

/* Общий стиль для внутренних блоков (белый фон, прозрачность, скругление) */
.header_inner {
  display: flex;
  align-items: center;
  gap: 20px; /* Расстояние между элементами внутри блока */

  /* Фон и оформление */
  background-color: #f8f8f8;
  border-radius: 10px; /* Радиус углов 10px */

  /* Внутренние отступы, чтобы контент не прилипал к краям фона */
  padding: 8px 20px;

  /* Опционально: тень для красоты */
  backdrop-filter: blur(2px); /* лёгкий блюр для улучшения читаемости */
  justify-content: space-between;

}

.header_inner--left {
  width: fit-content;
  min-width: 55%;
}

.newdiz-account:hover {
  background-color: #0088cc;
}

/* Левый блок — ничего менять не нужно, он и так слева */
/* .header_inner--left {
  justify-content: flex-start;
} */

/* Правый блок — прижимаем к правому краю с помощью margin-left: auto */
.header_inner--right {
  margin-left: auto;
  justify-content: flex-end;
}

/* Заголовок */
.header_title p {
  font-size: 28px;
  line-height: 1.4;
  font-weight: bold;
  color: black;
  letter-spacing: 1px;
  margin: 0;
}

/* Город */
.header-city h1 {
  font-size: 16px;
  line-height: 1.4;
  font-weight: bold;
  color: black;
  letter-spacing: 1px;
  margin: 0;
  text-decoration: none;
}

/* Навигация */
.header-nav ul {
  list-style-type: none;
  display: flex;
  align-items: center;
  margin: 0;
  padding: 0;
  gap: 15px;
}

.header-nav li a {
  text-decoration: none;
  color: black;
  transition: all 0.3s ease-in-out;
  border-bottom: 2px solid transparent;
  /* padding: 0 15px; */
  font-size: 16px;
  font-weight: normal;
  white-space: nowrap; /* Чтобы текст не переносился */
  line-height: 1.4;
}
.search_work {
  font-weight: bold;
}

.header-nav li a:hover {
  border-bottom: 2px solid black;
}

/* Помощь */
.header-help p {
  margin: 0;
}
.header-help a {
  text-decoration: none;
  color: black;
  font-size: 16px;
  font-weight: 600;
  /* padding: 0 15px; */
  display: inline-block;
  transition: all 0.3s ease-in-out;
  border-bottom: 2px solid transparent;
}
.header-help a:hover {
  border-bottom: 2px solid black;
}

.header_title {
  display: flex;
}
.header_title img {
  height: 35px;
}

.header-nav a.active {
  border-bottom: 2px solid black;
  font-weight: bold;
}

/* Кнопка входа */
.header-login {
  display: inline-flex;
  align-items: center;
}

.newdiz-account {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: center;
  padding: 7px 16px;
  background-color: transparent;
  border-radius: 8px;
  /* border: 2px solid black; */
  color: #fff;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.3s ease-in-out;
  text-decoration: none;
  white-space: nowrap;
  background: #0088cc;
}

.login-arrow {
  width: 20px;
  height: 20px;
  transition: transform 0.3s ease-in-out;
  margin-right: 10px;
}

.newdiz-account:hover .login-arrow {
  transform: translateX(5px);
}

/* Меню для мобил */
.header__btn-menu {
  display: none;
  width: 28px;
  height: 20px;
  transform: rotate(0deg);
  transition: .5s ease-in-out;
  cursor: pointer;
}

.header__btn-menu span {
  position: absolute;
  width: 100%;
  left: 0;
  transform: rotate(0deg);
  transition: .25s ease-in-out;
  height: 3px;
  background-color: #000;
}

.header__btn-menu span:nth-child(1) {
  top: 0;
}

.header__btn-menu span:nth-child(2),
.header__btn-menu span:nth-child(3) {
  top: 8px;
}

.header__btn-menu span:nth-child(4) {
  top: 16px;
}

.header__btn-menu.close-menu span:nth-child(1) {
  top: 8px;
  width: 0;
  left: 50%;
}

.header__btn-menu.close-menu span:nth-child(2) {
  transform: rotate(45deg);
}

.header__btn-menu.close-menu span:nth-child(3) {
  transform: rotate(-45deg);
}

.header__btn-menu.close-menu span:nth-child(4) {
  top: 8px;
  width: 0;
  left: 50%;
}

.menu__mobile {
  display: none;
  position: absolute;
  white-space: nowrap;
  background-color: #f8f8f8;
  padding: 10px;
  margin: 10px 0 0;
  border-radius: 10px;
}

.menu__mobile ul {
  list-style: none;
}

.menu__mobile li {
  margin: 0 0 5px;
}

.menu__mobile li a {
  text-decoration: none;
  color: black;
  transition: all 0.3s ease-in-out;
  border-bottom: 2px solid transparent;
  font-size: 16px;
  font-weight: normal;
  white-space: nowrap;
}

.menu__mobile li a:hover {
  border-bottom: 2px solid black;
}

.menu__mobile li a.active {
  border-bottom: 2px solid black;
  font-weight: bold;
}

.menu__mobile h1 {
  font-size: 16px;
  line-height: 1;
  letter-spacing: 1px;
}

.first__img-mobile {
  display: none;
}

/* Адаптивность для маленьких экранов */
@media (max-width: 1200px) {

}

@media (max-width: 1100px) {
  .header_container {
    padding-left: 15px;
    padding-right: 15px;
  }

  .header_inner {
    gap: 15px;
    padding: 8px 15px;
  }
}

@media (max-width: 900px) {
  .header-nav,
  .header-city {
    display: none;
  }

  .header__btn-menu {
    display: block;
  }

  .header_inner--left {
    min-width: auto;
  }

  .header_inner--right {
    margin-left: unset;
  }

  .first__img-mobile {
    display: block;
  }
}

@media (max-width: 600px) {
  .header_inner {
    gap: 10px;
    padding: 8px;
  }

  .header_title img {
    height: 30px;
  }

  .header__nav-mobile {
    order: 2;
  }

  .menu__mobile {
    right: 15px;
  }

  .header_inner--right {
    margin-left: auto;
  }
  
  .header_title p {
    font-size: 22px;
  }

  .header-city p {
    font-size: 14px;
  }

  .header-nav li a,
  .header-help a {
    font-size: 14px;
    padding: 5px;
  }

  .newdiz-account {
    font-size: 14px;
    padding: 2px 12px;
  }
}

@media (max-width: 400px) {
  .header_container {
    gap: 10px;
  }
  
  .header_title img {
    height: 20px;
  }

  .header_inner {
    gap: 5px;
    padding: 5px;
  }
}


@media (min-width: 901px) {
  .menu__mobile {
    display: none !important;
  }
}
