/* --- Верхняя линия: локация + соцсети --- */

.header__location__block {
    display: flex;
    gap: 8px;
}

.location__block__title p {
    font-family: "Tilda";
    color: #999999;
    font-size: 16px;
    line-height: 24px;
    padding: 0;
    position: relative;
    margin: 0;
    top: 4px;
}

.contact-item {
    text-decoration: none;
}

.social__link {
    transition: 0.2s ease;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* анимация */
.social__icon path,
.social__icon circle {
    transition: fill 0.2s ease;
}

/* HOVER */

/* голубой → белый */
.social__link:hover .social__icon path[fill="#00A1E4"],
.social__link:hover .social__icon circle[fill="#00A1E4"] {
    fill: #ffffff !important;
}

/* белый → голубой */
.social__link:hover .social__icon path[fill="#F7F5F9"] {
    fill: #00A1E4 !important;
}

/* светлый фон SVG (если нужно) */
.social__link:hover .social__icon path[fill="#EEF0FF"] {
    fill: #00A1E4 !important;
}

.header__social__block {
    display: flex;
    gap: 5px;
}

.header__social__block a {
    display: block;
    padding: 0;
    margin: 0;
    line-height: 10px;
}

.header__social__block a img {
    width: 15px;
    height: 15px;
}

@media(max-width: 768px) {
    .header__social__block a img {
        width: 23px;
        height: auto;
    }
}

/* --- Обёртка шапки --- */

.header__block {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header__top__block {
    border-bottom: 1px solid #d1cfcf;
    padding: 16px 0px;
}

/* --- Поиск в шапке --- */

.header__search {
    width: 500px;
    display: flex;
}

@media (max-width: 768px) {
    .header__search {
        width: auto;
    }
}

.search__wrap {
    position: relative;
    width: 100%;
}

.search__input {
    width: 100%;
    font-family: "Tilda";
    padding: 9px 10px 10px 40px;
    border: 1px solid #d0d0d0;
    border-radius: 5px;
    font-size: 16px;
    outline: none;
    height: 45px;
    border-right: none;
    border-radius: 5px 0 0 5px;
}

.search__input:focus {
    border-color: #00A1E4;
}

.search__img {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    pointer-events: none;
}

.search__btn {
    font-family: "Tilda";
    position: relative;
    right: 0;
    top: 0;
    height: 45px;
    padding: 0 20px;
    border: none;
    background: #00A1E4;
    color: #fff;
    border-radius: 0 5px 5px 0;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.2s ease, box-shadow 0.2s ease;
}

.search__btn:hover {
    background-color: #008FCC;
    box-shadow: 0 4px 10px rgba(0, 161, 228, 0.35);
}

/* --- Корзина в шапке --- */

.header__basket {
    position: relative;
}

.basket__items {
    position: relative;
    display: inline-block;
}

.basket__items svg path {
    width: 34px;
    filter: none;
    transition: 0.2s ease;
}

.basket__items svg:hover path {
    stroke: #00A1E4;
}

.basket__count {
    position: absolute;
    top: -6px;
    right: -6px;
    background: #00A1E4;
    color: #fff;
    font-size: 12px;
    padding: 1px 7px;
    border-radius: 50%;
    font-weight: bold;
}

.basket__block {
    display: flex;
    width: 100px;
    gap: 12px;
    justify-content: center;
    align-items: center;
}

.basket__title p {
    font-size: 11px;
    line-height: 120%;
    color: #0A0D14;
    font-weight: 400;
    padding: 0;
    margin: 0;
    line-height: 14px;
    cursor: pointer;
}

.basket__title a,
.basket__sum a {
    text-decoration: none;
}

.basket__sum span {
    font-size: 14px;
    color: #00A1E4;
    font-weight: 500;
    padding: 0;
    margin: 0;
    white-space: nowrap;
    cursor: pointer;
}

/* --- Центр шапки (лого + поиск + корзина) --- */

.header__center__flex {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 10px;
}

/* --- Меню --- */

.menu {
    display: flex;
    align-items: center;
    gap: 30px;
    list-style: none;
    margin: 0;
    padding: 10px 0;
}

.menu-item {
    position: relative;
}

.menu-item>a {
    text-decoration: none;
    color: #fff;
    font-size: 14px;
    display: flex;
    align-items: center;
    font-weight: 400;
    gap: 6px;
    font-family: Tilda;
    line-height: 24px;
    filter: none;
    transition: 0.2s ease;
}

.menu-item>a:hover {
    color: #00A1E4;
}

/* Стрелка у "Каталога" */

.arrow-icon {
    width: 14px;
    height: 14px;
    fill: none;
    stroke: #fff;
    stroke-width: 2px;
    transition: 0.3s ease;
    transform: rotate(0deg);
    margin-top: 2px;
}

.menu-item.catalog:hover .arrow-icon {
    transform: rotate(180deg);
    color: #00A1E4;
    stroke: #00A1E4;
}

/* Дропдаун каталога */

/* .catalog-dropdown {
    position: absolute;
    left: 0;
    top: 100%;
    background: #fff;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    padding: 15px;
    border-radius: 8px;
    display: none;
    grid-template-columns: repeat(4, 150px);
    gap: 15px;
    z-index: 20;
    filter: none;
    transition: 0.2s ease;
}

.menu-item.catalog:hover .catalog-dropdown {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
} */

/* ======================
   MEGAMENU (DESKTOP)
====================== */

.header__megamenu {
    max-height: 0;
    opacity: 0;
    pointer-events: none;
    overflow: hidden;
    transform: translateY(-20px);
    transition: all 0.4s ease;
}

header.is-megamenu-open .header__megamenu {
    max-height: 500px;
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

.megamenu {
    background: #0a0d14;
}

.megamenu__grid {
    display: grid;
    grid-template-columns: 260px 1px 1fr;
    gap: 32px;
    padding: 40px;
}

.megamenu__divider {
    background: #444;
}

.megamenu__categories {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.megamenu__categories a {
    text-decoration: none;
}

.megamenu__category {
    background: none;
    border: none;
    color: #999;
    text-align: left;
    cursor: pointer;
    font-size: 14px;
}

.megamenu__category.is-active {
    color: #fff;
}

.megamenu__preview {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 30px;
}

.megamenu__preview-image {
    background: #fff;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.megamenu__preview-image img {
    max-width: 120px;
    object-fit: contain;
}

.megamenu__preview-title {
    color: #fff;
    font-size: 22px;
}

.megamenu__preview-text {
    color: #999;
    margin-top: 10px;
    font-weight: 300;
}

.megamenu__preview-btn {
    margin-top: 20px;
    display: inline-block;
    padding: 12px 30px;
    background: #00a1e4;
    color: #fff;
    border-radius: 7px;
    text-decoration: none;
}

.megamenu__preview-btn:hover {
    color: #00A1E4;
    background: #fff;
}

.catalog-item {
    text-align: center;
    cursor: pointer;
    border: 1px solid #00A1E4;
    padding: 10px 20px;
    border-radius: 5px;
    text-decoration: none;
}

.catalog-item img {
    width: 100%;
    height: 100px;
    object-fit: cover;
    border-radius: 6px;
    margin-bottom: 8px;
}

.catalog-item span {
    font-size: 14px;
    color: #333;
}

/* --- Нижняя полоса шапки --- */

.header__bottom {
    background-color: #0A0D14;
    padding: 10px 0px;
    margin-top: 15px;
}

.header__menu__items {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Телефон в шапке */

.phone__item a {
    color: #fff;
    font-size: 16px;
    font-family: SFPro;
    text-decoration: none;
    filter: none;
    transition: 0.2s ease;
}

@media (max-width: 768px) {
    .phone__item a {
        color: #0A0D14;
    }
}

.phone__item a,
.phone__item a svg path,
.phone__item a span {
    transition: color 0.2s ease, stroke 0.2s ease;
}

.phone__item a:hover,
.phone__item a:hover svg path,
.phone__item a:hover span {
    color: #00A1E4;
    stroke: #00A1E4;
}

.phone__item a svg:hover path {
    color: #00A1E4;
    stroke: #00A1E4;
}

.phone__item a span:hover {
    color: #00A1E4;
}

.phone__item a svg path:hover {
    stroke: #00A1E4;
}

/* --- Мобильная шапка --- */

.mobile-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 70px;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    z-index: 1000;
}

.logo {
    font-size: 20px;
    font-weight: bold;
    color: #333;
    text-decoration: none;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 8px;
}

.menu-toggle {
    border: none;
    background: none;
}

.hamburger__menu {
    padding: 10px 10px;
    border: 2px solid #e8ecf3;
    border-radius: 50%;
    box-shadow: -2px 0 10px rgba(0, 0, 0, 0.1);
}

.menu-toggle:hover span {
    background: rgb(0, 161, 228, 0.8);
}

body.menu-open {
    overflow: hidden;
}

.menu-overlay {
    position: fixed;
    top: 70px;
    left: 0;
    width: 100%;
    height: calc(100vh - 70px);
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
    z-index: 998;
}

.menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

.mobile-menu nav {
    padding: 22px 0px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.mobile-menu ul {
    padding: 0;
}

.mobile__pad__block {
    padding: 20px;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.mobile-menu__bottom {
    margin-top: auto;
}

.header__main {
    display: block;
    margin-bottom: 60px;
}

.header__mobile__version {
    display: none;
}

/* Адаптив для мобильной шапки */
@media (min-width: 768px) {
    .mobile-header {
        padding: 0 40px;
    }
}

/* ===============================
   MOBILE FULLSCREEN MENU
=============================== */

@media (max-width: 768px) {

    body.menu-open {
        overflow: hidden;
    }

    .header__mobile__version {
        display: block;
    }

    .mobile-menu {
        position: fixed;
        top: 70px;
        left: 0;
        width: 100%;
        height: calc(100vh - 70px);
        background: #fff;

        transform: translateX(100%);
        transition: transform 0.3s ease;

        z-index: 9999;
        overflow: hidden;
    }

    .mobile-menu.active {
        transform: translateX(0);
    }

    .mobile-header {
        position: sticky;
        top: 0;
        background: #fff;
        z-index: 10;
        height: 70px;
        border-bottom: 1px solid #eee;
    }

    /* крестик */
    .menu-close {
        display: none;
        font-size: 26px;
        background: none;
        border: none;
        cursor: pointer;
    }

    /* бургер */
    body.menu-open .menu-toggle {
        display: none;
    }

    body.menu-open .menu-close {
        display: block;
    }

    /* контент меню */
    .mobile__pad__block {
        padding: 24px 20px;
        overflow-y: auto;
        flex: 1;
    }
}

/* =========================
   MOBILE MENU CATEGORIES SCREEN
   1 в 1 под стили фильтра
========================= */

.mobile-menu-categories-screen {
    display: none;
    background: #FDFDFD;
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100vh;
    z-index: 1200;
    font-family: Tilda;
    flex-direction: column;
    transform: translateX(100%);
    transition: transform 0.3s ease;
}

.mobile-menu-categories-screen.is-open {
    display: flex;
    transform: translateX(0);
}

/* =========================
   HEADER
========================= */

.mobile-menu-categories-header {
    display: flex;
    align-items: center;
    justify-content: center;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 16px 20px;
    background: #F8F8F8;
    border-bottom: 1px solid #E5EAF1;
    z-index: 30;
}

.mobile-menu-categories-title {
    font-size: 18px;
    font-weight: 600;
    color: #0A0D14;
    line-height: 1.2;
}

.mobile-menu-categories-back {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.mobile-menu-categories-close {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

/* =========================
   BODY
========================= */

.mobile-menu-categories-screen .catalog-sidebar {
    display: block !important;
    padding: 72px 20px 30px;
    overflow-y: auto;
    height: 100%;
    background: #FDFDFD;
}

/* =========================
   CATEGORY ITEM
========================= */

.mobile-menu-categories-screen .catalog-sidebar__item {
    padding: 22px 0;
    border-bottom: 1px solid #E5EAF1;
}

.mobile-menu-categories-screen .catalog-sidebar__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

/* =========================
   TITLE
========================= */

.mobile-menu-categories-screen .catalog-sidebar__title {
    display: flex;
    align-items: flex-start;
    justify-content: flex-start;
    width: 100%;
    text-decoration: none;
    background: none;
    border: none;
    padding: 0;
    margin: 0;
}

.mobile-menu-categories-screen .catalog-sidebar__title-text {
    font-family: Tilda;
    font-size: 24px;
    font-weight: 500;
    line-height: 1.05;
    color: #0A0D14;
    max-width: calc(100% - 40px);
}

.mobile-menu-categories-screen .catalog-sidebar__title.is-active .catalog-sidebar__title-text {
    color: #00A1E4;
}

/* =========================
   TOGGLE
========================= */

.mobile-menu-categories-screen .catalog-sidebar__toggle {
    border: none;
    background: none;
    padding: 0;
    margin: 0;
    font-size: 30px;
    line-height: 1;
    color: #111;
    cursor: pointer;
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mobile-menu-categories-screen .catalog-sidebar__toggle-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.25s ease;
}

.mobile-menu-categories-screen .catalog-sidebar__item.is-open .catalog-sidebar__toggle-icon {
    transform: rotate(180deg);
}

/* =========================
   CHILDREN
========================= */

.mobile-menu-categories-screen .catalog-sidebar__children {
    display: none;
    padding-top: 18px;
}

.mobile-menu-categories-screen .catalog-sidebar__item.is-open .catalog-sidebar__children {
    display: block;
}

/* =========================
   SUBITEM
========================= */

.mobile-menu-categories-screen .catalog-sidebar__subitem {
    position: relative;
    margin-bottom: 18px;
}

.mobile-menu-categories-screen .catalog-sidebar__subitem:last-child {
    margin-bottom: 0;
}

/* =========================
   SUBTITLE
========================= */

.mobile-menu-categories-screen .catalog-sidebar__subtitle {
    display: block;
    width: 100%;
    text-decoration: none;
    background: none;
    border: none;
    padding: 0;
    margin: 0;
}

.mobile-menu-categories-screen .catalog-sidebar__subtitle-text {
    font-family: Tilda;
    font-size: 16px;
    font-weight: 400;
    line-height: 1.4;
    color: #4B4B4B;
    display: block;
    max-width: calc(100% - 24px);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.mobile-menu-categories-screen .catalog-sidebar__subtitle.is-active .catalog-sidebar__subtitle-text {
    color: #00A1E4;
    font-weight: 500;
}

/* =========================
   SERIES
========================= */

.mobile-menu-categories-screen .catalog-sidebar__series {
    display: none;
    padding-left: 0;
    margin-top: 8px;
}

.mobile-menu-categories-screen .catalog-sidebar__subitem:hover .catalog-sidebar__series,
.mobile-menu-categories-screen .catalog-sidebar__subitem.is-series-open .catalog-sidebar__series {
    display: block;
}

.mobile-menu-categories-screen .catalog-sidebar__series ul {
    margin: 0;
    padding-left: 16px;
    list-style: disc;
}

.mobile-menu-categories-screen .catalog-sidebar__series li {
    margin-bottom: 4px;
}

.mobile-menu-categories-screen .catalog-sidebar__series li::marker {
    color: #00A1E4;
}

.mobile-menu-categories-screen .catalog-sidebar__series-link {
    color: #98A0B4 !important;
    font-size: 14px !important;
    font-family: Tilda;
    text-decoration: none;
    line-height: 1.5;
}

.mobile-menu-categories-screen .catalog-sidebar__series-link.is-active {
    color: #00A1E4 !important;
    font-weight: 500;
}

/* =========================
   ONLY MOBILE
========================= */

@media (min-width: 769px) {
    .mobile-menu-categories-screen {
        display: none !important;
    }
}

.mobile-menu-catalog-open {
    background: none;
    border: none;
    color: #0A0D14;
    font-size: 20px;
    line-height: 50px;
}

.catalog-sidebar__subtitle {
    background: none;
    border: none;
}

.catalog-sidebar__title {
    background: none;
    border: none;
}