/* bottom menu start*/
/* Основной контейнер */
.nav-mobile-menu-open-outer {
  display: flex;
  flex-direction: row;
  justify-content: center;
  gap: 1rem;
}
.mobile-bottom-nav {
  position: fixed;
  z-index: 1000;
  bottom: 3rem;
  left: 50%;
  transform: translateX(-50%);
  padding: 10px;
/*  max-width: 700px;*/
  background: #ececed7a;
  backdrop-filter: blur(18px);
  color: white;
  border-radius: 100px;
  text-align: center;
  backdrop-filter: blur(18px);
  border-radius: 200px;
  border: 1px solid;

  background: var(--menuBGColor);
  border: 1px solid;
  border-color: var(--menuBGColorBorder);

  width: auto;
  /* Меню в свернутом состоянии */
  transition: width 0.3s ease-out;
  overflow: hidden;
  opacity: 0;
  /* Скрываем, пока не произойдёт скролл */
}

/* Кнопка Menu / Close */
.nav-mobile-menu-open {
  display: block;
  padding: 12px 36px;
  background: #ff5722;
  color: white;
  border-radius: 12px;
  cursor: pointer;
  text-decoration: none;
  width: -webkit-fill-available;
}
/*
.nav-mobile-menu-open-outer .to-top-button {
  width: 50px;
  height: 50px;
  background: #000;
  color: #fff;
  border: none;
  border-radius: 50%;
  font-size: 24px;
  cursor: pointer;
  opacity: 1;
  transform: translateY(20px);
  transition: opacity 0.3s ease, transform 0.3s ease;
  z-index: 1000;
}

.nav-mobile-menu-open-outer .to-top-button:hover {
  background: #333;
}
*/
.to-top-button, .back-button {
    height: max-content;
    background: #e8e8e8;
    padding: 12px 24px;
    border-radius: 120px;
    color: #363131;
    font-size: 1rem;
    text-decoration: none;
    cursor: pointer;
  /*  transform: translateY(20px);*/
    transition: opacity 0.4s ease, transform 0.4s ease;
    z-index: 1000;
}
.to-top-button:hover, .back-button:hover {
  background: #fff;
}
.back-button svg {
  width: 18px;
  height: 18px;
}
/*
.back-button {
  display: none;
}*/
/* Вложенное меню (изначально скрыто) */
.mobile-bottom-menu-inner {
  height: 0;
  overflow: hidden;
  opacity: 0;
  padding: 0;
  border-radius: 0 0 8px 8px;
  transition: height 0.3s ease-out, opacity 0.3s ease-out;
}

@media (min-width: 1024px) {
  .mobile-bottom-nav {
    display: flex;
    flex-direction: row;
  }
  /*
  .nav-mobile-menu-open-outer {
    display: none;
  }
*/
  .nav-mobile-menu-open-outer .back-button, .nav-mobile-menu-open-outer .nav-mobile-menu-open {
    display: none;
  }

  .nav-right-bottom .nav-buttons {
    display: none;
  }

  .mobile-bottom-menu-inner {
    height: auto;
    overflow: visible;
    opacity: 1;
  }
  .mobile-bottom-menu-inner .nav-buttons {
    display: none;
  }
  .to-top-button {
    margin-left: 1.6rem;
  }
  .to-top-button::before {
    content: '';
    position: absolute;
    width: 1px;
    height: 80%;
    background: #c5c5c5;
    padding-left: 1px;
    left: -14px;
    top: 5px;
  }
}

@media (max-width: 1024px) {
  .nav-right-bottom {
    display: flex;
    flex-direction: column;
    flex-wrap: wrap;
    align-items: center;
    padding-bottom: 3rem;
  }
  .mobile-bottom-menu-inner .nav-buttons {
    justify-content: center;
  }
}

/* Когда меню открыто */
.mobile-bottom-nav.open {
  width: calc(100% - 2rem);
}

.mobile-bottom-menu-inner ul {
  padding: 10px;
  margin: 0;
  list-style: none;
}

.mobile-bottom-menu-inner li {
  padding: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.mobile-bottom-menu-inner li:last-child {
  border-bottom: none;
}
/* bottom menu end*/
.nav-menu {
  display: flex;
  gap: 12px;
}
/*
.nav-mobile-menu {
  display: none;
}
*/
.nav-menu a {
  height: max-content;
  background: #e8e8e8;
  background: #ffffff;
  border: 1px solid #c8c8c8;
  padding: 12px 24px;
  border-radius: 120px;
  color: #363131;
  font-size: 1rem;
  text-decoration: none;
  transition: all 400ms ease;
  white-space: nowrap;
}

.nav-menu a:hover {
  background: #f5f5f5;
}

.nav-menu .to-top-button {
  height: max-content;
  background: #e8e8e8;
  padding: 12px 24px;
  border-radius: 12px;
  color: #363131;
  font-size: 1rem;
  text-decoration: none;
  cursor: pointer;
  transform: translateY(20px);
  transition: opacity 0.4s ease, transform 0.4s ease;
  z-index: 1000;
  margin-left: 1rem;
}

.nav-menu .to-top-button:hover {
  background: #fff;
}

.nav-menu .to-top-button::before {
  content: '';
  position: absolute;
  width: 1px;
  height: 80%;
  background: #c5c5c5;
  padding-left: 1px;
  left: -14px;
  top: 5px;
}
.nav-menu .getintouch, .getintouch {
  display: block;
  padding: 12px 36px;
  background: #ff5722;
  color: white;
  border-radius: 120px;
  border: 0px;
  transition: all 400ms ease;
}
.nav-menu .getintouch:hover, .getintouch:hover {
  background: #173cf7;
}
.nav-menu .arrow-back-button, .nav-menu .arrow-back-button:hover {
  background-image: url(../img/icon-back-arrow-black.svg);
  background-repeat: no-repeat;
  background-position: center;
  height: 3rem;
  min-width: 4rem;
  position: relative;
}
@media (min-width: 1024px) {
  .arrow-back-button {
    margin-right: 1.6rem;
}
  .arrow-back-button::after {
    content: '';
    position: absolute;
    width: 1px;
    height: 80%;
    background: #c5c5c5;
    padding-left: 1px;
    right: -14px;
    top: 5px;
  }

}
@media (max-width: 1024px) {
.nav-menu .arrow-back-button {
  display: none;
}
#mainpage  .back-button {

}
}
