/* Responsive layout for the Aqua theme. Desktop rules remain in styles.css. */

@media (max-width: 1024px) {
  .wr,
  .wr2 {
    box-sizing: border-box;
    width: 100%;
    max-width: 1000px;
    padding-right: 16px;
    padding-left: 16px;
  }

  .wr2 {
    max-width: 938px;
  }

  .slider_wr {
    box-sizing: border-box;
    width: 100%;
  }
}

@media (max-width: 767px) {
  html,
  body {
    width: 100%;
    min-width: 0;
    max-width: 100%;
    overflow-x: hidden;
  }

  body,
  body * {
    box-sizing: border-box;
  }

  img,
  video,
  iframe {
    max-width: 100%;
  }

  .wr,
  .wr2 {
    width: 100%;
    max-width: none;
    padding-right: 14px;
    padding-left: 14px;
  }

  .top {
    height: auto;
    min-height: 0;
  }

  .top .wr.pos_rel {
    display: grid;
    grid-template-columns: 78px minmax(0, 1fr);
    grid-template-rows: repeat(3, auto);
    align-items: center;
    gap: 6px 12px;
    padding-top: 10px;
    padding-bottom: 10px;
  }

  .logo {
    position: relative;
    top: auto;
    right: auto;
    bottom: auto;
    left: auto;
    grid-column: 1;
    grid-row: 1 / 4;
    width: 78px;
    height: 91px;
    margin: 0;
    background-position: center;
    background-size: contain;
  }

  .logo:after {
    display: none;
  }

  .top_phones {
    grid-column: 2;
    grid-row: 1;
    display: block;
    min-width: 0;
    margin: 0;
    padding: 3px 0 3px 24px;
    background-position: left center;
    font-size: 14px;
    line-height: 1.35;
    overflow-wrap: anywhere;
  }

  .top_email {
    grid-column: 2;
    grid-row: 2;
    display: block;
    min-width: 0;
    margin: 0;
    padding: 0;
    background: none;
    overflow-wrap: anywhere;
  }

  .top_email a {
    font-size: 14px;
  }

  .search_form {
    grid-column: 2;
    grid-row: 3;
    float: none;
    min-width: 0;
    width: 100%;
    margin: 0;
  }

  .search_form form {
    display: flex;
    align-items: center;
    width: 100%;
  }

  .search_form input[type="text"] {
    flex: 1 1 auto;
    width: 1%;
    min-width: 0;
    height: 36px;
  }

  .search_form input[type="submit"] {
    flex: 0 0 25px;
  }

  .menu {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    height: auto;
    margin: 0;
    padding: 4px 0;
    border-bottom-width: 4px;
    line-height: 1.2;
  }

  .menu a,
  .menu a:first-child,
  .menu a:last-child,
  .menu a:nth-child(4) {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 0;
    min-height: 40px;
    height: auto;
    margin: 0;
    padding: 6px 3px;
    font-size: 10px;
    line-height: 1.2;
    text-align: center;
    white-space: normal;
    overflow-wrap: anywhere;
  }

  .menu a:hover,
  .menu a.active {
    outline: none;
    background: #ffba00;
  }

  .path {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 3px 0;
    height: auto;
    margin-top: 14px;
    background: none;
    line-height: 1.4;
    text-align: left;
  }

  .path a,
  .path .last_span {
    max-width: 100%;
    height: auto;
    padding-top: 3px;
    padding-bottom: 3px;
    font-size: 12px;
    overflow-wrap: anywhere;
  }

  .path .laast:after,
  .path .last_span:after {
    display: none;
  }

  .main {
    min-height: 0;
    padding-top: 18px;
  }

  .left_col,
  .right_col,
  .left_side,
  .right_side {
    float: none;
    width: 100%;
    max-width: 100%;
    margin: 0;
  }

  .right_side {
    font-size: 14px;
  }

  .right_side .big_header,
  .big_header {
    margin-top: 14px;
    margin-bottom: 16px;
    padding-bottom: 10px;
    font-size: 23px;
    line-height: 1.25;
    letter-spacing: 0;
    overflow-wrap: anywhere;
  }

  .lined_header {
    margin-top: 16px;
    background: none;
    font-size: 24px;
    line-height: 1.25;
  }

  .lined_header span {
    padding: 0 8px;
  }

  .main_text,
  .r_text {
    max-width: 100%;
    text-align: left;
    overflow-wrap: anywhere;
  }

  .main_text img,
  .r_text img,
  .right_side img {
    height: auto;
  }

  .catalog_menu {
    width: 100%;
    max-width: 100%;
    background-image: none;
  }

  .cat_type {
    float: none;
    margin: 8px 0;
    text-align: right;
  }

  .sub_menu {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin: 8px 0 12px;
  }

  .sub_menu a {
    height: auto;
    min-height: 34px;
    margin: 0;
    padding: 7px 9px;
    line-height: 1.2;
  }

  .group_list,
  .main .object_list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin: 16px 0;
  }

  .main .one_group,
  .main .t2 .one_group,
  .main .t2 .one_group:nth-child(2n+1),
  .main .t2 .one_group:nth-child(2n),
  .main .one_group:nth-child(4n+1) {
    width: auto;
    min-width: 0;
    margin: 0;
    padding: 8px;
    text-align: center;
  }

  .g_img,
  .main .t2 .g_img.gn {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 120px;
    line-height: normal;
  }

  .g_img img {
    position: static;
    max-width: 100%;
    max-height: 115px;
    object-fit: contain;
  }

  .one_group img + img {
    display: none;
  }

  .main .g_name {
    font-size: 12px;
    line-height: 1.3;
  }

  .main .object_list.t2 .object,
  .main .object {
    display: block;
    width: auto;
    min-width: 0;
    height: auto;
    min-height: 0;
    margin: 0;
    padding: 10px;
  }

  .main .object img {
    display: block;
    width: 100%;
    max-width: 100%;
    max-height: 150px;
    margin: 0 auto;
    object-fit: contain;
  }

  .object span {
    font-size: 13px;
    line-height: 1.3;
  }

  .pos_list_type2:not(.pos_slider):not(.slick-slider) {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin: 12px 0;
    font-size: 14px;
  }

  .pos_list_type2:not(.pos_slider):not(.slick-slider) .one_pos {
    display: flex;
    flex-direction: column;
    width: auto;
    max-width: none;
    min-width: 0;
    min-height: 0;
    margin: 0;
    padding: 8px;
    overflow: hidden;
    position: relative;
  }

  .pos_list:not(.pos_list_type2):not(.pos_slider) .one_pos {
    width: 100%;
    min-height: 0;
    padding: 10px;
  }

  .pos_list .pos_img {
    display: block;
    width: 100%;
    margin: 0;
    padding: 0;
  }

  .pos_img img {
    max-width: 100%;
    max-height: 160px;
    object-fit: contain;
  }

  .pos_info,
  .pos_list_type2 .pos_info {
    float: none;
    width: auto;
    margin: 0;
    padding: 8px 0 0;
  }

  .pos_name,
  .main .pos_name,
  .pos_list_type2 .pos_name {
    min-height: 0;
    margin-bottom: 8px;
    font-size: 14px;
    line-height: 1.3;
    text-align: left;
  }

  .pos_col_left,
  .pos_col_right,
  .pos_list_type2 .pos_col_right {
    float: none;
    width: 100%;
    margin: 8px 0 0;
  }

  .p_line span,
  .p_line b {
    width: auto;
    max-width: 100%;
  }

  .price,
  .price2 {
    min-width: 0;
    max-width: 100%;
    white-space: normal;
  }

  .pos_list_type2 .price span {
    position: static;
    display: block;
    height: auto;
    margin: 0;
  }

  .pos_list_type2 .old_price {
    position: static;
    margin: 0;
    text-align: left;
  }

  .pos_list_type2:not(.pos_slider):not(.slick-slider) .buy_block {
    display: block;
    position: static;
    width: auto;
    margin-top: 8px;
    padding: 8px 0 0;
    border: 0;
    border-top: 1px solid #eee;
  }

  .pos_r_side,
  .pos_photo {
    float: none;
    width: 100%;
    max-width: 100%;
    margin: 12px 0;
  }

  .big2 {
    display: block;
    width: 100%;
    text-align: center;
  }

  .big2 img {
    width: auto;
    max-width: 100%;
    max-height: 55vh;
    object-fit: contain;
  }

  .mini_list2 {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
  }

  .mini_list2 a {
    margin: 0;
  }

  .call_form,
  .buy_button,
  .buy_button_1 {
    min-height: 44px;
    line-height: 1.25;
    padding: 12px;
    text-align: center;
  }

  .slider {
    height: 220px;
    margin-bottom: 0;
  }

  .slider_wr {
    width: 100%;
  }

  .slide {
    height: 220px;
  }

  .slide img {
    display: block;
    width: 100%;
    height: 220px;
    object-fit: cover;
  }

  .slider_m_text {
    top: 28px;
    right: 18px;
    left: 18px;
    width: auto;
    font-size: clamp(20px, 6vw, 30px);
    line-height: 1.15;
  }

  .slider_s_text {
    top: auto;
    right: 18px;
    bottom: 25px;
    left: 18px;
    width: auto;
    font-size: 12px;
    line-height: 1.35;
  }

  .slider_wave {
    display: none;
  }

  .sl_left,
  .sl_right {
    top: 50%;
    width: 25px;
    height: 60px;
    transform: translateY(-50%);
    background-size: auto 60px;
  }

  .sl_left {
    left: 4px;
  }

  .sl_right {
    right: 4px;
  }

  .slider2 {
    width: 100%;
    height: auto;
    min-height: 0;
    margin: 24px 0;
    padding: 12px;
  }

  .one_slide2 {
    position: relative;
    display: block;
  }

  .sl_left2,
  .sl_right2 {
    float: none;
    width: 100%;
    height: auto;
    margin: 0;
    line-height: 1.4;
    text-align: center;
  }

  .sl_left2 img {
    max-width: 100%;
    max-height: 180px;
    object-fit: contain;
  }

  .sl_right2 {
    margin-top: 12px;
  }

  .sl2_left,
  .sl2_right {
    top: 10px;
  }

  .tabs,
  .tab_select {
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .table_spec,
  .nontab table,
  .cart-table {
    display: block;
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .footer {
    height: auto;
    margin-top: 32px;
    padding: 20px 0;
  }

  .footer .f_right,
  .footer .f_col {
    float: none;
    width: 100%;
    max-width: 100%;
    margin: 0 0 14px;
  }

  .footer .f_menu {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 14px;
  }

  .footer .logo2 {
    display: block;
    width: auto;
    max-width: 100%;
    height: auto;
    margin: 16px auto 0;
  }

  #element_to_pop_up {
    width: calc(100vw - 24px);
    min-width: 0;
    max-width: calc(100vw - 24px);
  }

  .ov_form,
  .ov_wr,
  .ov_wr input[type="text"],
  .ov_wr input[type="email"],
  .ov_wr input[type="password"],
  .ov_wr textarea {
    box-sizing: border-box;
    width: 100%;
    min-width: 0;
    max-width: 100%;
  }
}

@media (max-width: 480px) {
  .menu {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .menu a,
  .menu a:first-child,
  .menu a:last-child,
  .menu a:nth-child(4) {
    min-height: 42px;
    font-size: 12px;
  }

  .slider,
  .slide,
  .slide img {
    height: 190px;
  }

  .slider_m_text {
    top: 24px;
  }

  .slider_s_text {
    bottom: 18px;
  }

  .main .object_list.t2 .object,
  .main .object {
    padding: 8px;
  }
}
