/* Стеклянная шапка (вариант D1, 09.11.2026). Разметка — partials/header.
   Файл подключён последним и перекрывает старые правила шапки из style.css,
   mobile-fixes.css и site.css, поэтому откат — вернуть шаблон и убрать файл.

   Ширины идут сверху вниз: что не влезает, уходит по очереди.
   1440+  две фразы, всё меню, полная кнопка
   <1440  поля 24, меню плотнее, короткая кнопка
   <1366  поля 16, одна фраза
   <1280  «Пакеты», «Калькулятор», «О нас» в «Ещё», вход значком
   <1024  меню в кнопке, рядом «Помощь детям», в полосе только связь и язык
   <768   телефон: одна строка без логотипа, полосы нет
   <390   Viber уходит в меню */

:root { --ic-header-h: 132px; }

/* Шапка закреплена и не занимает места: отступ у обёртки задан здесь, а не
   скриптом — страница не прыгает при загрузке. Фото главной уходит под стекло. */
.ic-hd-wrap { padding-top: 148px; }
.bg-home { background-origin: padding-box; }

.ic-glass {
    box-sizing: border-box;
    background: rgba(255, 255, 255, .62);
    -webkit-backdrop-filter: blur(18px) saturate(1.6);
    backdrop-filter: blur(18px) saturate(1.6);
    border: 1px solid rgba(255, 255, 255, .75);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .8), 0 12px 32px rgba(3, 62, 140, .16);
}

@supports not ((-webkit-backdrop-filter: blur(2px)) or (backdrop-filter: blur(2px))) {
    .ic-glass { background: rgba(255, 255, 255, .92); }
}

header.ic-hd,
header.ic-hd.ic-fixed,
header.ic-hd.ic-fixed.is-scrolled {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 9000;
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 16px max(40px, calc((100% - 1360px) / 2)) 0;
    background: none;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    pointer-events: none;
    font-family: "Open Sans", Arial, sans-serif;
    transition: padding-top .25s ease;
}

header.ic-hd::before { display: none; }
header.ic-hd > * { pointer-events: auto; }

/* ---------- Верхняя полоса ---------- */
/* Обе капсулы со стеклом — отдельные слои, и основная ложилась поверх
   выпадающих списков полосы (язык, «О нас»). Поэтому полоса выше неё. */
.ic-hd__strip {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    height: 40px;
    padding: 0 16px 0 24px;
    border-radius: 20px;
    font-size: 13px;
    color: #0A2B4A;
    transition: height .25s ease, opacity .2s ease, margin .25s ease;
}

.ic-hd__trust { display: flex; align-items: center; min-width: 0; white-space: nowrap; }
.ic-hd__tp { display: inline-flex; align-items: center; gap: 6px; color: #0A2B4A; font-weight: 400; }
.ic-hd__tp:hover, .ic-hd__tp:focus { color: #033E8C; text-decoration: none; }
.ic-hd__tp b { font-weight: 700; }
.ic-hd__tp-star { color: #007A50; font-size: 15px; }
.ic-hd__tp-stars { color: #007A50; letter-spacing: 1px; }

.ic-hd__phrase { padding-left: 18px; margin-left: 18px; border-left: 1px solid rgba(3, 62, 140, .2); line-height: 18px; }

.ic-hd__links { display: flex; align-items: center; flex: none; }
.ic-hd__links > * + * { margin-left: 10px; padding-left: 10px; border-left: 1px solid rgba(3, 62, 140, .2); }
.ic-hd__phone { color: #033E8C; font-weight: 600; white-space: nowrap; }

.ic-hd__soc { display: flex; align-items: center; }
.ic-hd__ic { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 38px; flex: none; }
.ic-hd__ic img { display: block; width: 26px; height: 26px; }

.ic-hd__about { position: relative; }
.ic-hd__about-link { display: inline-flex; align-items: center; gap: 5px; height: 38px; color: #033E8C; font-weight: 600; white-space: nowrap; }
.ic-hd__about-link:hover, .ic-hd__about-link:focus { color: #033E8C; text-decoration: none; }
.ic-hd__about-link svg { width: 10px; height: auto; }
.ic-hd__about-list {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    z-index: 20;
    min-width: 220px;
    margin: 0;
    padding: 8px;
    list-style: none;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 12px 32px rgba(3, 62, 140, .16);
}
.ic-hd__about:hover .ic-hd__about-list,
.ic-hd__about:focus-within .ic-hd__about-list { display: block; }
.ic-hd__about-list a { display: block; padding: 8px 12px; border-radius: 8px; color: #0A2B4A; font-size: 14px; white-space: nowrap; }
.ic-hd__about-list a:hover { background: #EEF4FF; color: #033E8C; text-decoration: none; }

header.ic-hd .ic-hd__lang .ic-lang__btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 38px;
    margin: 0;
    padding: 0 2px;
    border: 0;
    background: none;
    box-shadow: none;
    color: #033E8C;
    font-size: 13px;
    font-weight: 600;
}

/* ---------- Основная капсула ---------- */
.ic-hd__bar {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 12px;
    height: 68px;
    padding: 0 10px 0 28px;
    border-radius: 34px;
    transition: height .25s ease, border-radius .25s ease;
}

.ic-hd__logo {
    display: block;
    flex: none;
    width: 172px;
    overflow: hidden;
    transition: width .42s cubic-bezier(.3, 1.1, .4, 1), opacity .2s ease;
}
.ic-hd__logo img { display: block; width: 172px; max-width: none; height: auto; }

.ic-hd__mob { display: none; }

.ic-hd__nav { flex: 1 1 auto; min-width: 0; display: flex; justify-content: center; transition: opacity .18s ease; }

header.ic-hd #menu.navbar { display: flex; align-items: center; min-height: 0; margin: 0; border: 0; border-radius: 0; background: none; }
header.ic-hd .navbar-collapse { display: block; padding: 0; border: 0; overflow: visible; box-shadow: none; }
header.ic-hd #menu .nav.navbar-nav { display: flex; flex-wrap: nowrap; gap: 4px; float: none; margin: 0; padding: 0; }
header.ic-hd #menu .nav.navbar-nav::before,
header.ic-hd #menu .nav.navbar-nav::after { display: none; }
header.ic-hd #menu .nav.navbar-nav > li { position: relative; float: none; margin: 0; padding: 0; }

header.ic-hd #menu .nav.navbar-nav > li > a {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 44px;
    padding: 0 9px;
    border: 0;
    border-radius: 999px;
    background: none;
    box-shadow: none;
    animation: none;
    color: #0A2B4A;
    font-size: 15px;
    font-weight: 600;
    line-height: 1;
    white-space: nowrap;
}
header.ic-hd #menu .nav.navbar-nav > li > a:hover,
header.ic-hd #menu .nav.navbar-nav > li > a:focus,
header.ic-hd #menu .nav.navbar-nav > li:hover > a { background: rgba(255, 255, 255, .8); color: #033E8C; text-decoration: none; }
header.ic-hd #menu .nav.navbar-nav > li > a svg { flex: none; width: 10px; height: auto; margin: 0; }
header.ic-hd #menu .nav.navbar-nav > li > a::before,
header.ic-hd #menu .nav.navbar-nav > li > a::after { display: none; }

header.ic-hd #menu .nav.navbar-nav > li.ic-hd__help > a { background: rgba(15, 122, 95, .1); color: #0B6650; }
header.ic-hd #menu .nav.navbar-nav > li.ic-hd__help > a:hover,
header.ic-hd #menu .nav.navbar-nav > li.ic-hd__help > a:focus { background: rgba(15, 122, 95, .18); color: #0B6650; }

header.ic-hd #menu .nav.navbar-nav > li.ic-hd__more { display: none; }
.ic-hd__menu-btn { display: none; }

.ic-hd__right { display: flex; align-items: center; gap: 6px; flex: none; margin-left: auto; }

header.ic-hd .cabinetbtn { flex: none; margin: 0; }
header.ic-hd .cabinetbtn a { width: auto; min-width: 116px; height: 44px; padding: 0 14px; font-size: 14px; }

.ic-hd__cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: none;
    height: 48px;
    padding: 0 22px;
    border-radius: 999px;
    background: linear-gradient(180deg, #1D5FB5 0%, #033E8C 100%);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .22), 0 4px 12px rgba(3, 62, 140, .22);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    white-space: nowrap;
}
.ic-hd__cta:hover, .ic-hd__cta:focus { color: #fff; text-decoration: none; filter: brightness(1.08); }
.ic-hd__cta-short { display: none; }

.ic-hd__burger { display: none; }

/* ---------- Поиск: лупа становится логотипом ---------- */
.ic-hd__lensbox { position: relative; flex: none; width: 44px; height: 44px; }

.ic-hd__lens,
.ic-hd__close {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, .6);
    color: #033E8C;
    cursor: pointer;
}

.ic-hd__lens { z-index: 2; transition: transform .42s cubic-bezier(.3, 1.1, .4, 1), background-color .3s ease; }

.ic-hd__lens-ic,
.ic-hd__lens-mark { position: absolute; left: 50%; top: 50%; transition: opacity .28s ease, transform .42s cubic-bezier(.3, 1.1, .4, 1); }
.ic-hd__lens-ic { width: 20px; height: 20px; margin: -10px 0 0 -10px; }
.ic-hd__lens-mark { width: 17px; height: 30px; max-width: none; margin: -15px 0 0 -8.5px; opacity: 0; transform: rotate(-45deg) scale(.55); }

.ic-hd__close { z-index: 1; opacity: 0; visibility: hidden; transform: translateX(var(--hd-close-x, 0)); }

header.ic-hd #search.ic-hd__field {
    position: absolute;
    width: auto;
    top: 50%;
    left: var(--hd-field-l, 60px);
    right: var(--hd-field-r, 400px);
    height: 44px;
    margin-top: -22px;
    opacity: 0;
    visibility: hidden;
    transition: opacity .25s ease .12s, visibility 0s linear .37s;
}
header.ic-hd #search.ic-hd__field input {
    display: block;
    width: 100%;
    height: 44px;
    padding: 0 18px;
    border: 1px solid rgba(3, 62, 140, .2);
    border-radius: 22px;
    outline: 0;
    background: rgba(255, 255, 255, .85);
    color: #0A2B4A;
    font-size: 15px;
    -webkit-appearance: none;
    appearance: none;
}
header.ic-hd #search.ic-hd__field input:focus { border-color: rgba(3, 62, 140, .45); background: #fff; }
header.ic-hd #search.ic-hd__field .search-autocomplete { margin-top: 12px; border-radius: 20px; }

header.ic-hd.is-search .ic-hd__logo { width: 0; opacity: 0; }
header.ic-hd.is-search .ic-hd__nav,
header.ic-hd.is-search .ic-hd__mob { opacity: 0; visibility: hidden; pointer-events: none; }
header.ic-hd.is-search .ic-hd__lens { transform: translateX(var(--hd-lens-x, 0)); background-color: transparent; }
header.ic-hd.is-search .ic-hd__lens-ic { opacity: 0; transform: rotate(45deg) scale(.8); }
header.ic-hd.is-search .ic-hd__lens-mark { opacity: 1; transform: none; }
header.ic-hd.is-search .ic-hd__close { opacity: 1; visibility: visible; }
header.ic-hd.is-search #search.ic-hd__field { opacity: 1; visibility: visible; transition: opacity .25s ease .12s, visibility 0s; }

/* ---------- Прокрутка: остаётся основная капсула ---------- */
header.ic-hd.ic-fixed.is-scrolled { padding-top: 8px; gap: 0; }
header.ic-hd.is-scrolled .ic-hd__strip { height: 0; padding-top: 0; padding-bottom: 0; border-width: 0; opacity: 0; overflow: hidden; pointer-events: none; }
header.ic-hd.is-scrolled .ic-hd__bar { height: 56px; border-radius: 28px; padding-right: 6px; }
header.ic-hd.is-scrolled .ic-hd__logo { width: 149px; }
header.ic-hd.is-scrolled .ic-hd__logo img { width: 149px; }
header.ic-hd.is-scrolled.is-search .ic-hd__logo { width: 0; }
header.ic-hd.is-scrolled .ic-hd__cta { height: 44px; }

/* ---------- Якоря клиники и врача: своя кнопка заявки больше не нужна ---------- */
.ic-anchors__cta, .ic-anchors__cta.is-shown { display: none; }

/* ---------- Ширины ---------- */
@media (max-width: 1439.98px) {
    header.ic-hd, header.ic-hd.ic-fixed, header.ic-hd.ic-fixed.is-scrolled { padding-left: 24px; padding-right: 24px; }
    header.ic-hd #menu .nav.navbar-nav > li > a { padding: 0 8px; }
    .ic-hd__cta-full { display: none; }
    .ic-hd__cta-short { display: inline; }
}

@media (max-width: 1365.98px) {
    header.ic-hd, header.ic-hd.ic-fixed, header.ic-hd.ic-fixed.is-scrolled { padding-left: 16px; padding-right: 16px; }
    .ic-hd__phrase--2 { display: none; }
}

@media (max-width: 1279.98px) {
    .ic-hd__logo { width: 149px; }
    .ic-hd__logo img { width: 149px; }
    .ic-hd__about { display: none; }
    header.ic-hd #menu .nav.navbar-nav > li.ic-hd__xl { display: none; }
    header.ic-hd #menu .nav.navbar-nav > li.ic-hd__more { display: block; }
    header.ic-hd .cabinetbtn a { width: 44px; min-width: 0; padding: 0; }
    header.ic-hd .cabinetbtn__t { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
}

@media (max-width: 1099.98px) {
    header.ic-hd #menu .nav.navbar-nav > li > a { padding: 0 6px; }
    .ic-hd__cta { padding: 0 16px; }
}

@media (max-width: 1023.98px) {
    .ic-hd__phrase, .ic-hd__soc--networks { display: none; }
    header.ic-hd #menu .nav.navbar-nav > li { display: none; }
    header.ic-hd #menu .nav.navbar-nav > li.ic-hd__more { display: none; }
    header.ic-hd #menu .nav.navbar-nav > li.ic-hd__help { display: block; }
    .ic-hd__nav { justify-content: flex-start; }
    .ic-hd__menu-btn {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        height: 44px;
        margin-right: 4px;
        padding: 0 14px;
        border: 0;
        border-radius: 999px;
        background: rgba(255, 255, 255, .7);
        color: #033E8C;
        font-size: 15px;
        font-weight: 600;
    }
    header.ic-hd #menu.navbar { gap: 4px; }
}

@media (max-width: 767.98px) {
    :root { --ic-header-h: 64px; }
    .ic-hd-wrap { padding-top: 76px; }

    header.ic-hd, header.ic-hd.ic-fixed, header.ic-hd.ic-fixed.is-scrolled { padding: 8px 10px 0; gap: 0; }
    .ic-hd__strip, .ic-hd__logo, .ic-hd__nav, .ic-hd__cta { display: none; }

    .ic-hd__bar, header.ic-hd.is-scrolled .ic-hd__bar { height: 56px; padding: 0 5px 0 16px; border-radius: 28px; gap: 0; }

    .ic-hd__mob { display: flex; align-items: center; flex: 1 1 auto; min-width: 0; gap: 8px; transition: opacity .18s ease; }
    .ic-hd__tp-mini { display: flex; flex-direction: column; flex: none; font-size: 10px; line-height: 13px; color: #0A2B4A; white-space: nowrap; }
    .ic-hd__tp-mini span { color: #007A50; font-size: 11px; }
    .ic-hd__tp-mini b { font-weight: 700; }
    .ic-hd__mob .ic-hd__soc { margin-left: auto; }
    .ic-hd__mob .ic-hd__ic { width: 40px; height: 44px; }
    .ic-hd__mob .ic-hd__ic img { width: 28px; height: 28px; }

    .ic-hd__right { gap: 0; margin-left: 0; }
    header.ic-hd .cabinetbtn { margin: 0 0 0 4px; }

    .ic-hd__burger {
        display: flex;
        align-items: center;
        justify-content: center;
        flex: none;
        width: 44px;
        height: 44px;
        margin-left: 6px;
        padding: 0;
        border: 0;
        border-radius: 50%;
        background: linear-gradient(180deg, #1D5FB5 0%, #033E8C 100%);
        color: #fff;
        transition: opacity .18s ease;
    }

    .ic-hd__lens-mark { width: 20px; height: 36px; margin: -18px 0 0 -10px; }

    header.ic-hd.is-search .cabinetbtn,
    header.ic-hd.is-search .ic-hd__burger { opacity: 0; visibility: hidden; pointer-events: none; }

    /* 16 px: с меньшим шрифтом iPhone приближает страницу при фокусе на поле. */
    header.ic-hd #search.ic-hd__field input { padding: 0 4px; border: 0; background: transparent; font-size: 16px; }
    header.ic-hd #search.ic-hd__field input:focus { background: transparent; }
    /* Шире поля — на всю капсулу: поле отступает от её краёв на 56 и 55 px. */
    /* !important: в mobile-fixes.css у панели left и right тоже с ним. */
    header.ic-hd #search.ic-hd__field .search-autocomplete { left: -56px !important; right: -55px !important; margin-top: 12px; }
}

@media (max-width: 389.98px) {
    .ic-hd__ic--viber { display: none; }
}

@media (prefers-reduced-motion: reduce) {
    header.ic-hd, .ic-hd__strip, .ic-hd__bar, .ic-hd__logo, .ic-hd__nav, .ic-hd__lens,
    .ic-hd__lens-ic, .ic-hd__lens-mark, .ic-hd__field { transition: none; }
}

/* ---------- Выбор языка в меню телефона: в шапке для него нет места ---------- */
.mnav-langs { display: flex; gap: 8px; padding: 12px 16px 0; }
.mnav-langs a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    height: 44px;
    min-width: 72px;
    padding: 0 12px;
    border-radius: 999px;
    background: rgba(3, 62, 140, .06);
    color: #033E8C;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
}
.mnav-langs a.is-active { background: #033E8C; color: #fff; }
