/* ===== Новый хедер Экодом — фирменные цвета ===== */
.main-header {
    --hdr-green: #88ab27;         /* Акценты, кнопки */
    --hdr-green-dark: #5a7319;    /* Наведение кнопок */
    --hdr-green-hover: #5a7319;
    --hdr-soft: #e8eaeb;          /* Фоны и секции */
    --hdr-border: #a67c52;        /* Карточки, иконки - бордеры */
    --hdr-text: #2c2e2f;          /* Текст, заголовки */
    --hdr-body: #2c2e2f;          /* Текст основной */
    --hdr-muted: #8c9296;         /* Неактивные элементы */
}

/* Верхняя полоса */
.main-header .header-container {
    background: #ffffff;
    border-top: 4px solid var(--hdr-green);
    border-bottom: 1px solid var(--hdr-border);
    padding-top: 18px;
    padding-bottom: 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    box-sizing: border-box;
}

.main-header .logo {
    float: none;
    width: auto;
    flex: 1 1 auto;
    display: flex;
    align-items: center;
    min-width: 0;
}

.main-header .logo .logo_block {
    float: none;
    width: auto;
    max-width: none;
    display: flex;
    align-items: center;
}

.main-header .logo .logo_block > a {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.main-header .logo img {
    float: none;
    width: auto;
    max-width: 92px;
    margin: 0;
}

.main-header .logo .logo_name {
    float: none;
    max-width: 190px;
    padding: 0 0 0 16px;
    color: var(--hdr-text);
    font-size: 13px;
    font-weight: 500;
    line-height: 1.35;
}

.main-header .logo .logo_name span {
    color: var(--hdr-green-dark);
    font-weight: 700;
}

/* Соцсети и кнопка расчёта */
.main-header .logo .after_logo {
    float: none;
    width: auto;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 0 0 22px;
}

.main-header .logo .after_logo .ssil {
    padding-left: 0;
}

.main-header .logo .after_logo .ssil a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    margin: 0;
    border: 1px solid var(--hdr-border);
    border-radius: 50%;
    background-color: var(--hdr-soft);
    transition: background-color .2s, border-color .2s, color .2s;
}

.main-header .logo .after_logo .ssil a:hover {
    background-color: var(--hdr-green);
    border-color: var(--hdr-green);
}
.main-header .logo .after_logo .ssil a img {
    float: none;
    width: 19px;
    max-width: 19px;
    transition: filter .2s;
}
.main-header .logo .after_logo .ssil a:hover img {
    filter: brightness(0) invert(1);
}

/* Кнопка «Рассчитать проект» */
.main-header .logo .after_logo .ssil_2 a,
.main-header .logo .after_logo .ssil_2 a:hover,
.main-header .logo .after_logo .ssil_2 a:focus,
.main-header .logo .after_logo .ssil_2 a:active {
    box-sizing: border-box;
    width: auto;
    height: auto;
    gap: 10px;
    padding: 12px 20px;
    border: 1px solid var(--hdr-green);
    border-radius: 8px;
    background: #f9f8f6;
    color: var(--hdr-green);
    font-size: 14px;
    font-weight: 700;
    transition: background-color .2s, border-color .2s, color .2s;
}
.main-header .logo .after_logo .ssil_2 a span,
.main-header .logo .after_logo .ssil_2 a i {
    float: none;
    width: auto;
    padding-left: 0;
    color: var(--hdr-green);
    line-height: 1.2;
}
.main-header .logo .after_logo .ssil_2 a img {
    float: none;
    width: 18px;
    max-width: 18px;
    filter: none;
}

/* Телефоны и кнопка звонка */
.main-header .header-container .phone_block {
    float: none;
    width: auto;
    max-width: none;
    flex: 0 0 auto;
    display: flex;
    align-items: flex-start;
    gap: 28px;
    padding: 0;
    text-align: left;
}

.main-header .phone_block .btn_call_back {
    float: none;
    width: auto;
    max-width: none;
    padding-left: 0;
    margin-top: 0;
}

.main-header .phone_block .job_time,
.main-header .phone_block .phone .phone_call {
    box-sizing: border-box;
    display: flex;
    align-items: flex-start;
    height: 20px;
    margin: 0;
    padding-top: 0;
    padding-bottom: 0;
    color: var(--hdr-muted);
    font-size: 13px;
    line-height: 18px;
}
.main-header .phone_block .job_time {
    padding-left: 17px;
    margin-bottom: 0;
}

.main-header .phone_block .phone .phone_call {
    padding-left: 0;
    text-align: left;
}

.main-header .phone_block .phone .phone_call:before {
    display: none;
}

.main-header a.custom_btn.btn_top {
    box-sizing: border-box;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: auto;
    height: 42px;
    max-width: none;
    float: none;
    margin: 0;
    padding: 0 22px;
    border-radius: 8px;
    background-color: var(--hdr-green);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    text-align: center;
    white-space: nowrap;
    box-shadow: none;
    transition: background-color .2s, color .2s;
}
.main-header a.custom_btn.btn_top > div {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
}
.main-header a.custom_btn.btn_top:hover,
.main-header a.custom_btn.btn_top:focus,
.main-header a.custom_btn.btn_top:active {
    background-color: var(--hdr-green-dark);
    color: #fff;
}

.main-header .phone_block .phone {
    float: none;
    padding: 0;
    text-align: left;
}
.main-header .phone_block .phone .phone_a {
    box-sizing: border-box;
    height: 21px;
    margin-top: 0;
    color: var(--hdr-body);
    font-size: 17px;
    font-weight: 700;
    line-height: 21px;
    text-align: left;
}
.main-header .phone_block .phone .phone_a a,
.main-header .phone_block .phone .phone_a a:visited {
    color: inherit;
    text-decoration: none;
    white-space: nowrap;
}
.main-header .phone_block .phone .phone_a a:hover {
    color: var(--hdr-green-dark);
}

/* Зелёная полоса навигации во всю ширину */
.main-header .header_menu {
    padding-top: 0;
    background-color: var(--hdr-green);
}
.main-header .block_top_menu {
    background: transparent;
    border: 0;
    margin-bottom: 0;
}
.main-header .top_menu {
    display: flex !important;
    flex-wrap: wrap;
    justify-content: center;
    align-items: stretch;
    font-size: 0;
    list-style: none;
}
.main-header .top_menu > li {
    position: relative;
}
.main-header .top_menu ul a,
.main-header .top_menu > li > a {
    display: block;
    padding: 16px 18px;
    border-bottom: 0;
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.35;
    text-align: center;
    text-decoration: none;
    transition: background-color .2s;
}
.main-header .top_menu > li > a:hover,
.main-header .top_menu > li > a:focus,
.main-header .top_menu > li > a:active {
    background-color: var(--hdr-green-dark);
    color: #fff;
    text-decoration: none;
}

/* Выпадающие подменю */
.main-header .top_menu li > ul {
    min-width: 250px;
    padding: 6px 0;
    border: 1px solid var(--hdr-border);
    border-top: 3px solid var(--hdr-green-dark);
    border-radius: 0 0 12px 12px;
    background: #f9f8f6;
    box-shadow: 0 18px 34px rgba(44, 46, 47, 0.07); /* светлая тень */
    box-sizing: border-box;
}
.main-header .top_menu li > ul li {
    display: block;
}
.main-header .top_menu li > ul li a,
.main-header .top_menu li > ul li a:visited {
    padding: 11px 18px;
    border-bottom: 1px solid var(--hdr-border);
    color: var(--hdr-body);
    font-size: 14px;
    font-weight: 500;
    text-align: left;
    white-space: normal;
}
.main-header .top_menu li > ul li:last-child a {
    border-bottom: 0;
}
.main-header .top_menu li > ul li a:hover,
.main-header .top_menu li > ul li a:focus {
    background-color: var(--hdr-soft);
    color: var(--hdr-green-dark);
}

/* Видимый фокус */
.main-header .top_menu a:focus-visible,
.main-header a.custom_btn.btn_top:focus-visible,
.main-header .logo .after_logo .ssil a:focus-visible {
    outline: 3px solid #88ab27;
    outline-offset: 3px;
}

/* Бургер */
.main-header .menu__icon span {
    background: var(--hdr-green);
}

/* Отступ контента под абсолютный хедер */
body .page_p {
    padding-top: 178px;
}

@media (max-width: 1200px) {
    .main-header .logo .after_logo {
        padding-left: 14px;
    }
    .main-header .header-container .phone_block {
        gap: 20px;
    }
    .main-header .top_menu ul a,
    .main-header .top_menu > li > a {
        padding: 15px 14px;
        font-size: 14px;
    }
}

@media (max-width: 1024px) {
    .main-header .logo .after_logo .ssil_2 a span {
        display: none;
    }
    .main-header .logo .after_logo .ssil_2 a {
        padding: 12px 14px;
    }
    body .page_p {
        padding-top: 156px;
    }
}

@media (max-width: 900px) {
    .main-header .header-container {
        padding-top: 14px;
        padding-bottom: 14px;
        gap: 14px;
    }
    .main-header .logo .after_logo {
        display: none;
    }
    .main-header .phone_block .btn_call_back {
        display: none;
    }
    .main-header .phone_block .phone .phone_call {
        display: none;
    }
    .main-header .phone_block .phone .phone_a {
        font-size: 15px;
    }
    .main-header .header_menu {
        background-color: #f9f8f6;
    }
    body .page_p {
        padding-top: 130px;
    }
}

@media (max-width: 600px) {
    .main-header .logo img {
        max-width: 68px;
    }
    .main-header .logo .logo_name {
        max-width: 150px;
        padding-left: 12px;
        font-size: 12px;
    }
    .main-header .top_menu > li > a {
        padding: 14px 12px;
        font-size: 14px;
    }
    body .page_p {
        padding-top: 118px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .main-header .top_menu a,
    .main-header a.custom_btn.btn_top,
    .main-header .logo .after_logo .ssil a,
    .main-header .logo .after_logo .ssil_2 a {
        transition: none;
    }
}