/*
 * Premium brand banner and mobile header. The logo file is unchanged.
 */

#smart-head.smart-head-main .smart-head-mid {
    --head-h: 80px;
    height: auto;
}

#smart-head.smart-head-main .smart-head-mid .inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: auto;
    min-height: 0;
    padding-top: 7px;
    padding-bottom: 7px;
}

#smart-head.smart-head-main .bw-editorial-banner .items-left {
    display: none;
}

#smart-head.smart-head-main .bw-editorial-banner .items-center {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    width: auto;
    flex: 0 1 auto;
    padding: 0;
}

#smart-head.smart-head-main .bw-editorial-banner .items-right {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    width: auto;
    flex: 0 0 auto;
    margin-left: auto;
    padding: 0;
}

.bw-child-ticker .tick + .tick {
    box-shadow: inset 1px 0 0 #e4e7ee;
}

#smart-head.smart-head-main .bw-editorial-banner .logo-link,
#smart-head-mobile .logo-link {
    display: inline-flex;
    align-items: center;
    background: transparent;
    padding: 0;
    line-height: 0;
}

#smart-head.smart-head-main .bw-editorial-banner .logo-link h1,
#smart-head-mobile .logo-link span {
    margin: 0;
    display: flex;
}

#smart-head .ts-logo .logo-image-dark,
#smart-head-mobile .ts-logo .logo-image-dark {
    display: none;
}

#smart-head .ts-logo .logo-image:not(.logo-image-dark),
#smart-head-mobile .ts-logo .logo-image:not(.logo-image-dark) {
    display: block;
}

.site-s-dark #smart-head .ts-logo .logo-image-dark,
.site-s-dark #smart-head-mobile .ts-logo .logo-image-dark {
    display: block;
}

.site-s-dark #smart-head .ts-logo .logo-image-dark ~ .logo-image,
.site-s-dark #smart-head-mobile .ts-logo .logo-image-dark ~ .logo-image {
    display: none;
}

#smart-head.smart-head-main .smart-head-mid .logo img,
#smart-head.smart-head-main .smart-head-mid img.logo-image {
    width: auto;
    height: auto;
    max-width: min(320px, 46vw);
    max-height: 64px;
}

.bw-offcanvas-subscribe:focus-visible {
    outline: 2px solid #8eb4ff;
    outline-offset: 3px;
}

#smart-head-mobile .logo img,
#smart-head-mobile img.logo-image {
    width: auto;
    height: auto;
    max-width: min(180px, 46vw);
    max-height: 42px;
}

#smart-head-mobile .items-right {
    gap: 2px;
}

.bw-offcanvas-subscribe {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 44px;
    margin: 4px 0 8px;
    padding: 0 18px;
    border: 1px solid #4aa3ff;
    border-radius: 8px;
    box-shadow: 0 0 16px rgba(40, 130, 255, 0.28);
    color: inherit;
    font-family: Barlow, "Segoe UI", sans-serif;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.14em;
    line-height: 1;
    text-decoration: none;
    text-transform: uppercase;
}

.bw-offcanvas-subscribe::before {
    content: "";
    width: 18px;
    height: 18px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='1.7'%3E%3Crect x='3' y='5' width='18' height='14' rx='2'/%3E%3Cpath d='M4 7l8 6 8-6'/%3E%3C/svg%3E") center / contain no-repeat;
}

.bw-offcanvas-subscribe:hover,
.bw-offcanvas-subscribe:focus {
    background: rgba(74, 163, 255, 0.16);
    color: inherit;
}

@media (min-width: 941px) {
    .bw-offcanvas-subscribe-wrap {
        display: none;
    }
}

@media (max-width: 1100px) {
    #smart-head.smart-head-main .smart-head-mid .inner {
        padding-top: 7px;
        padding-bottom: 7px;
    }
}

@media (max-width: 430px) {
    #smart-head-mobile .logo img,
    #smart-head-mobile img.logo-image {
        max-width: min(150px, 40vw);
        max-height: 38px;
    }

    #smart-head-mobile .bw-masthead-tools {
        gap: 8px;
    }
}

.bw-masthead-tools {
    display: inline-flex;
    align-items: center;
    gap: 14px;
    color: #18212b;
    font-family: Barlow, "Segoe UI", sans-serif;
}

.bw-lang {
    position: relative;
}

#smart-head .bw-lang-button,
#smart-head-mobile .bw-lang-button,
#smart-head .scheme-switcher .toggle,
#smart-head-mobile .scheme-switcher .toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    box-sizing: border-box;
    width: auto;
    min-width: 34px;
    height: 34px;
    min-height: 34px;
    margin: 0;
    padding: 0 8px;
    border: 1px solid #e6e9ed;
    border-radius: 4px;
    background: transparent;
    color: #18212b;
    font: 600 12px/1 Barlow, "Segoe UI", sans-serif;
    letter-spacing: 0.04em;
    cursor: pointer;
}

#smart-head .bw-lang-button:hover,
#smart-head-mobile .bw-lang-button:hover,
#smart-head .scheme-switcher .toggle:hover,
#smart-head-mobile .scheme-switcher .toggle:hover,
#smart-head .bw-lang-button:focus-visible,
#smart-head-mobile .bw-lang-button:focus-visible,
#smart-head .scheme-switcher .toggle:focus-visible,
#smart-head-mobile .scheme-switcher .toggle:focus-visible {
    border-color: #00a9e8;
    color: #00a9e8;
}

.bw-lang-globe,
.scheme-switcher svg {
    width: 16px;
    height: 16px;
    flex: 0 0 16px;
}

.bw-lang-chevron {
    width: 0;
    height: 0;
    border-left: 3px solid transparent;
    border-right: 3px solid transparent;
    border-top: 4px solid #65717c;
}

.bw-lang-menu {
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    z-index: 40;
    min-width: 148px;
    margin: 0;
    padding: 6px;
    list-style: none;
    border: 1px solid #e4e7ec;
    border-radius: 6px;
    background: #ffffff;
    color: #1c2128;
    box-shadow: 0 8px 20px rgba(16, 24, 40, 0.08);
}

.bw-lang-menu li {
    padding: 8px 10px;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 600;
}

.bw-lang-button:focus-visible,
.scheme-switcher .toggle:focus-visible {
    outline: 2px solid #1f8a4c;
    outline-offset: 3px;
}

.scheme-switcher {
    width: auto;
    height: 34px;
}

#smart-head .scheme-switcher .toggle,
#smart-head-mobile .scheme-switcher .toggle {
    width: 34px;
    padding: 0;
}

@media (prefers-reduced-motion: reduce) {
    .bw-offcanvas-subscribe,
    .bw-footer-editorial .smart-head-social .link,
    .scheme-switcher .toggle {
        transition: none;
    }
}
