
.header {
    display: flex;
    align-items: center;
    padding-top: 20px;
    padding-bottom: 24px;
    justify-content: space-between;
}

/* Меню слева */
.header__menu {
    max-width: 644px;
    width: 100%;
    border: 1px solid #E2E8F0;
    display: flex;
    align-items: center;
    height: 48px;
    border-radius: 12px;
}

.header__list {
    list-style: none;
    display: flex;
    align-items: center;
    margin: 0;
    padding: 0;
    height: 100%;
    border-radius: 12px;
    padding: 0 3px;
}
.logo__img {
    /* margin-right: 70px; */
}

.header__item {
    position: relative;
}

.header__link {
    text-decoration: none;
    color: #2D3748;
    font-size: 16px;
    line-height: 24px;
    font-weight: 400;
    padding: 10px 16px;
    border-radius: 10px;
    transition: background-color 0.3s ease;

}

.header__link:hover {
    background-color: #2D3748;
    color: #fff;
}

/* .header__link_active {
    background-color:#2D3748;
    color:#fff;
} */

/* Кнопки справа */
.header__buttons {
    max-width: 290px;
    width: 100%;
    height: 48px;
    display: flex;
    justify-content: space-between;
}

.header__button_demo {
    max-width: 92px;
    width: 100%;
    height:100%;
    background-color: #E2E8F0;
    color: #2D3748;
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: 600;
    font-size: 16px;
    line-height: 24px;
    border-radius: 12px;
}

.header__button_application {
    max-width: 182px;
    width: 100%;
    height:100%;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: #171923;
    color: #FFFFFF;
    border-radius: 12px;
    font-size: 16px;
    line-height: 24px;
    border-radius: 12px;
}

.header__button:hover {
    background-color: #000;
    color: #fff;
}

/* Скрытые по умолчанию кнопки бургера и крестика */
.burger,
.burger-close {
  display: none;
  position: relative;
  width: 30px;
  height: 30px;
  background: none;
  border: none;
  cursor: pointer;
  z-index: 1001;
}

/* Общие стили для линий бургера и крестика */
.burger__line,
.burger-close__line {
  position: absolute;
  top: 50%;
  left: 0;
  width: 100%;
  height: 3px;
  background-color: #2D3748;
  transform: translateY(-50%);
  transition: all 0.3s ease;
}

/* Линии бургера */
.burger__line::before,
.burger__line::after {
  content: '';
  position: absolute;
  width: 100%;
  height: 3px;
  background-color: #2D3748;
  transition: all 0.3s ease;
}

.burger__line::before {
  top: -8px;
  left: 0;
}
.burger__line::after {
  bottom: -8px;
  left: 0;
}

/* Активный (кликнутый) бургер — превращается в крестик */
.burger.active .burger__line {
  background-color: transparent;
}

.burger.active .burger__line::before {
  transform: rotate(45deg);
  top: 0;
}

.burger.active .burger__line::after {
  transform: rotate(-45deg);
  bottom: 0;
}

/* Стили для крестика */
.burger-close__line {
  transform: rotate(45deg);
}

.burger-close__line::before {
  content: '';
  position: absolute;
  top: 0px;
  left: 0px;
  width: 100%;
  height: 3px;
  background-color: #2D3748;
  transform: rotate(-90deg);
}

.header__menu {
    transition: max-height 0.3s ease-out;
    overflow: hidden;
  }
  
  .header__menu.active {
    max-height: 500px;
  }
  .mobile-menu {
    position: fixed;
    top: 0;
    right: -300px; /* скрываем за экраном */
    width: 260px;
    height: 100vh;
    background-color: #fff;
    box-shadow: -2px 0 10px rgba(0, 0, 0, 0.1);
    padding-top: 80px;
    z-index: 999;
    transition: right 0.3s ease;
  }
  
  .mobile-menu.active {
    right: 0;
  }
  
  .mobile-menu__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
  }
  
  .mobile-menu__item {
    padding: 15px 20px;
  }
  
  .mobile-menu__link {
    text-decoration: none;
    color: #2D3748;
    font-size: 16px;
    line-height: 24px;
    display: block;
    transition: color 0.3s ease;
  }
  
  .mobile-menu__link:hover {
    color: #4A5568;
  }

  @media(max-width:1145px){
    .header__link {
      font-size: 14px;
      line-height: 20px;
    }
    .header__list {
      justify-content: space-around;
      width: 100%;
    }
    .header__link {
      font-size: 14px;
      line-height: 20px;
      padding: 10px 0px;
    }
    .header__menu {
      width: 63%;
    }
  }

@media (max-width: 1024px) {
  .header__menu {
    display: none;
  }

  .burger {
    display: block;
  }
}

@media(max-width:600px){
  .header__button_demo {
    font-size: 12px;
    line-height: 18px;
  }
  .header__button_application {
    font-size: 12px;
    line-height: 18px;
  }
  .header__buttons {
    height: 40px;
  }
}

@media (max-width: 480px) {
  .header {
    padding-bottom: 0px;
  }

}

@media (max-width: 420px) {
    .header__buttons {
        display: none;
    }
}
