.theme-header {
    width: 100%;
    background: #fff;
    border-bottom: 1px solid #dbe1ea;
    font-family: "Lato-Regular", sans-serif;
}

.theme-header__inner {
    width: min(1360px, calc(100% - 32px));
    margin: 0 auto;
}

.theme-header__top {
    background: #12233f;
    color: #fff;
    font-size: 12px;
    line-height: 1;
}

.theme-header__top-inner {
    min-height: 30px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.theme-topnav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 18px;
    margin: 0;
    padding: 0;
    list-style: none;
    flex: 1 1 auto;
    min-width: 0;
    justify-content: center;
}

.theme-topnav__item {
    margin: 0;
    padding: 0;
}

.theme-topnav__link,
.theme-header__top-link {
    color: #fff;
    text-decoration: none;
    opacity: 0.95;
}

.theme-topnav__link:hover,
.theme-header__top-link:hover {
    opacity: 1;
    text-decoration: underline;
}

.theme-header__top-link--ev {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: #ffd000;
    font-weight: 700;
}

.theme-header__ev-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 12px;
    height: 12px;
    font-size: 12px;
    line-height: 1;
}

.theme-header__top-right {
    display: flex;
    align-items: center;
    gap: 12px;
    white-space: nowrap;
    flex: 0 0 auto;
}

.theme-header__divider {
    width: 1px;
    height: 14px;
    background: rgba(255, 255, 255, 0.35);
    display: inline-block;
}

.theme-switcher {
    display: inline-flex;
    align-items: stretch;
    border: 1px solid rgba(255, 255, 255, 0.16);
    background: rgba(255, 255, 255, 0.06);
    border-radius: 4px;
    overflow: hidden;
}

.theme-switcher__item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border: 0;
    background: transparent;
    color: #fff;
    font-size: 12px;
    padding: 6px 10px;
    text-decoration: none;
    cursor: pointer;
}

.theme-switcher__flag {
    width: 18px;
    height: 12px;
    display: inline-block;
    background-size: cover;
    background-position: center;
    border-radius: 1px;
}

.theme-switcher__flag--uk {
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 60 40'><rect width='60' height='40' fill='%23012169'/><path d='M0 0h7l18 12V0h10v12L53 0h7v6L41 20l19 14v6h-7L35 28v12H25V28L6 40H0v-6l19-14L0 6z' fill='%23fff'/><path d='M0 0h5l20 14h10L55 0h5v4L39 20 60 36v4h-5L35 26H25L5 40H0v-4l21-16L0 4z' fill='%23cf142b'/><rect x='24' width='12' height='40' fill='%23fff'/><rect y='14' width='60' height='12' fill='%23fff'/><rect x='26' width='8' height='40' fill='%23cf142b'/><rect y='16' width='60' height='8' fill='%23cf142b'/></svg>");
}

.theme-switcher__flag--us {
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 60 40'><rect width='60' height='40' fill='%23b22234'/><g fill='%23fff'><rect y='3' width='60' height='3'/><rect y='9' width='60' height='3'/><rect y='15' width='60' height='3'/><rect y='21' width='60' height='3'/><rect y='27' width='60' height='3'/><rect y='33' width='60' height='3'/></g><rect width='24' height='21' fill='%23005283'/><g fill='%23fff'><circle cx='4' cy='4' r='1.2'/><circle cx='9' cy='4' r='1.2'/><circle cx='14' cy='4' r='1.2'/><circle cx='19' cy='4' r='1.2'/><circle cx='6.5' cy='8' r='1.2'/><circle cx='11.5' cy='8' r='1.2'/><circle cx='16.5' cy='8' r='1.2'/><circle cx='21' cy='8' r='1.2'/><circle cx='4' cy='12' r='1.2'/><circle cx='9' cy='12' r='1.2'/><circle cx='14' cy='12' r='1.2'/><circle cx='19' cy='12' r='1.2'/><circle cx='6.5' cy='16' r='1.2'/><circle cx='11.5' cy='16' r='1.2'/><circle cx='16.5' cy='16' r='1.2'/><circle cx='21' cy='16' r='1.2'/></g></svg>");
}

.theme-switcher__item.is-active {
    background: rgba(255, 255, 255, 0.12);
}

.theme-header__main {
    background: #fff;
}

.theme-header__main-inner {
    min-height: 88px;
    display: grid;
    grid-template-columns: 220px minmax(320px, 1fr) auto;
    align-items: center;
    gap: 20px;
    padding: 12px 0;
}

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

.theme-logo__link {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
}

.theme-logo__img {
    display: block;
    width: 150px;
    max-width: 100%;
    height: auto;
}

.theme-header__search {
    min-width: 0;
}

.theme-header__search .customSearch {
    width: 100%;
    max-width: 560px;
    margin: 0 auto;
}

.theme-header__search .block-search,
.theme-header__search .block.block-search,
.theme-header__search .block-content {
    width: 100%;
}

.theme-header__search .search-category {
    right: 44px !important;
}

.theme-header__search .desktop-category {
    max-width: 150px;
}

.theme-header__search .search input.input-text {
    border-color: #d0d7e3;
    border-radius: 4px;
    height: 46px;
}

.theme-header__search .action.search {
    background: #1f4b9b;
    border-color: #1f4b9b;
    border-radius: 0 4px 4px 0;
    height: 46px;
}

.theme-header__actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 14px;
    flex-wrap: nowrap;
}

.theme-action,
.theme-quote-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: #00255d;
}

.theme-action--phone {
    gap: 10px;
    padding-right: 6px;
}

.theme-action__icon {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    color: #6a7688;
    font-size: 18px;
}

.theme-action__icon img {
    display: block;
    max-width: 100%;
    max-height: 100%;
}

.theme-action--phone .theme-action__icon {
    width: 28px;
    height: 28px;
}

.theme-action__text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    line-height: 1.1;
}

.theme-action__text strong {
    font-size: 18px;
    color: #00255d;
    font-weight: 700;
}

.theme-action__text small {
    font-size: 11px;
    color: #7c879a;
}

.theme-action__label {
    font-size: 12px;
    color: #00255d;
    font-weight: 600;
}

.theme-action--catalogue,
.theme-action--account {
    flex-direction: column;
    gap: 4px;
    min-width: 58px;
}

.theme-action--cart {
    min-width: 58px;
}

.theme-action--cart .theme-action__label {
    display: block;
    text-align: center;
}

.theme-action--cart .minicart-wrapper {
    display: flex;
    align-items: center;
}

.theme-action--cart .action.showcart {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    text-decoration: none;
}

.theme-action--cart .theme-action__icon {
    color: #6a7688;
}

.theme-action--cart .counter.qty {
    position: absolute;
    top: -4px;
    right: -6px;
    min-width: 16px;
    height: 16px;
    padding: 0 4px;
    border-radius: 999px;
    background: #ef233c;
    color: #fff;
    font-size: 10px;
    line-height: 16px;
    text-align: center;
}

.theme-action--cart .counter.qty.empty {
    display: inline-flex;
}

.theme-action--cart .counter-number {
    display: inline-block;
    min-width: 8px;
}

.theme-quote-btn {
    background: #ffcf18;
    color: #00255d;
    font-weight: 700;
    border-radius: 6px;
    padding: 0 16px;
    height: 42px;
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.03) inset;
}

.theme-quote-btn:hover {
    background: #f6c700;
    text-decoration: none;
}

.theme-quote-btn i {
    font-size: 14px;
}

.theme-quote-btn img {
    width: 16px;
    height: 16px;
    display: block;
}

.theme-quote-btn span {
    font-size: 14px;
}

.theme-action--cart .block-minicart {
    right: 0;
    left: auto;
}

@media (max-width: 1199px) {
    .theme-header__main-inner {
        grid-template-columns: 180px minmax(280px, 1fr);
    }

    .theme-header__actions {
        grid-column: 1 / -1;
        justify-content: space-between;
        padding-top: 8px;
        flex-wrap: wrap;
    }
}

@media (max-width: 991px) {
    .theme-header__top-inner,
    .theme-header__main-inner {
        width: calc(100% - 24px);
    }

    .theme-header__top-inner {
        flex-direction: column;
        align-items: flex-start;
        padding: 8px 0;
    }

    .theme-topnav {
        justify-content: flex-start;
    }

    .theme-header__top-right {
        flex-wrap: wrap;
        gap: 12px;
    }

    .theme-header__main-inner {
        grid-template-columns: 1fr;
    }

    .theme-header__logo,
    .theme-header__search {
        justify-self: center;
    }

    .theme-header__actions {
        justify-content: center;
    }
}

@media (max-width: 767px) {
    .theme-topnav {
        gap: 12px;
        justify-content: flex-start;
        overflow-x: auto;
        white-space: nowrap;
        flex-wrap: nowrap;
        scrollbar-width: none;
    }

    .theme-topnav::-webkit-scrollbar {
        display: none;
    }

    .theme-header__actions {
        gap: 10px;
    }

    .theme-action--phone .theme-action__text,
    .theme-action__label {
        display: none;
    }

    .theme-quote-btn {
        padding: 0 12px;
    }
}
