/* Header spacing polish. Palette values stay untouched. */
.header,
.header * {
  box-sizing: border-box;
}

.header_top .row,
.header_top .col-xs-12.col-md-8 {
  min-height: 36px;
}

.header_top .col-xs-12.col-md-8 {
  display: flex;
  flex-direction: row-reverse;
  align-items: stretch;
  justify-content: flex-start;
}

.header_top .top_item {
  float: none;
  width: auto;
  height: auto;
  min-height: 36px;
  padding: 0 14px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.header_top .top_item > a,
.header_top .top_item > span,
.header_top .top_item .switch {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  min-height: 36px;
}

.header_top .top_item svg {
  flex: 0 0 auto;
  margin-top: 0;
}

.logo {
  margin-top: 0;
}

.logo img {
  width: auto;
}

.search {
  margin-top: 0;
}

.search_input {
  height: 40px;
  line-height: 40px;
}

.search_button {
  height: 40px;
  line-height: 40px;
}

.header_phones {
  margin-top: 0;
  margin-bottom: 0;
}

.tel_wrap {
  min-height: 42px;
  padding-left: 52px;
  display: inline-flex;
  align-items: center;
  background-position: left center;
}

@media (min-width: 768px) {
  .header_top .row,
  .header_middle .row,
  .header_bottom .container {
    display: flex;
    align-items: center;
  }

  .header_top .row::after,
  .header_middle .row::after,
  .header_bottom .container::after {
    content: none;
    display: none;
  }

  .header_top .mobile-hidden.col-md-4 {
    display: flex;
    align-items: center;
    min-height: 36px;
  }

  .top_notice {
    width: 100%;
    overflow: hidden;
  }

  .top_notice_title {
    margin-top: 0;
  }

  .top_notice_text {
    max-width: calc(100% - 95px);
    overflow: hidden;
  }

  .header_middle .row {
    padding: 14px 0;
  }

  .logo {
    display: flex;
    align-items: center;
  }

  .logo img {
    max-height: 68px;
  }

  .header_middle .col-md-4.col-xl-6 {
    display: flex;
    align-items: center;
  }

  .search {
    width: 100%;
  }

  .header_phones {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    justify-content: center;
    min-height: 68px;
  }

  .header_bottom .container {
    min-height: 44px;
  }

  .menu {
    float: none;
    flex: 1 1 auto;
    margin-right: 24px;
  }

  .menu_group_header {
    float: none;
  }

  .menu_list_1 {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    margin: 0;
  }

  .menu_group_header .menu_item_1 {
    display: block;
  }

  #cart_informer {
    flex: 0 0 155px;
    width: 155px;
    margin-left: 0;
  }
}

@media (max-width: 767px) {
  .header_top .col-xs-12.col-md-8 {
    padding-left: 8px;
    padding-right: 8px;
  }

  .header_top .top_item {
    min-width: 42px;
    padding-left: 10px;
    padding-right: 10px;
  }

  .logo {
    padding-top: 10px;
    text-align: center;
  }

  .logo img {
    max-height: 64px;
  }

  .search {
    margin-top: 12px;
  }

  .header_phones {
    margin-top: 10px;
    margin-bottom: 12px;
  }

  .header_phone {
    margin-top: 0;
    margin-bottom: 0;
  }

  #cart_informer {
    height: 42px;
    line-height: 42px;
  }

  .cart_info {
    line-height: 42px;
  }
}

@media (max-width: 420px) {
  .header_top .top_item {
    min-width: 38px;
    padding-left: 8px;
    padding-right: 8px;
  }

  .logo img {
    max-height: 58px;
  }

  .search {
    margin-top: 10px;
  }
}
