.hw-header {
    --hw-header-blue: #428bca;
    --hw-header-blue-dark: #3577af;
    --hw-header-blue-deep: #0a4b84;
    --hw-header-blue-soft: #e0f1ff;
    --hw-header-border: #e6e4e2;
    --hw-header-muted: #77808a;
    --hw-header-text: #1a2530;
    position: relative;
    z-index: 5000;
    border-bottom: 1px solid var(--hw-header-border);
    background: #ffffff;
    color: var(--hw-header-text);
    font-family: "Noto Sans", sans-serif;
    box-shadow: 0 1px 3px rgba(10, 75, 132, 0.04);
}

.hw-header.is-compact {
    position: fixed;
    top: 0;
    right: 0;
    left: 0;
}

.hw-header__spacer {
    display: none;
}

.hw-header.is-compact + .hw-header__spacer {
    display: block;
}

.hw-header,
.hw-header * {
    box-sizing: border-box;
}

.hw-header button,
.hw-header input {
    font-family: inherit;
}

.hw-header__container {
    position: relative;
}

.hw-header__bar {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 64px;
    transition: min-height 0.2s ease;
}

.hw-header__logo {
    flex: 0 0 auto;
}

.hw-header__logo a {
    display: flex;
    align-items: center;
    height: 44px;
    text-decoration: none;
}

.hw-header__logo .logo {
    display: block;
    width: auto;
    max-width: 156px;
    height: 26px;
    max-height: 26px;
}

.hw-header__search {
    flex: 1 1 auto;
    min-width: 220px;
}

.hw-header__search form {
    margin: 0;
}

.hw-header .header-char_search_form {
    position: relative;
    top: auto;
    display: flex;
    align-items: center;
    width: 100%;
    max-width: none;
    height: 44px;
    padding: 0;
    border: 1px solid #d6d4d4;
    border-radius: 12px;
    background: #f7f7f7;
    transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.hw-header .header-char_search_form:focus-within {
    border-color: var(--hw-header-blue);
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(66, 139, 202, 0.16);
}

.hw-header .header-char_search_form input {
    flex: 1 1 auto;
    width: 100%;
    min-width: 0;
    height: 42px;
    padding: 0 88px 0 16px;
    border: 0;
    border-radius: 12px;
    outline: 0;
    background: transparent;
    color: var(--hw-header-text);
    font-size: 15px;
    line-height: 42px;
}

.hw-header .header-char_search_form input:focus {
    border: 0;
}

.hw-header .header-handwriting-search_button,
.hw-header .header-char_search_form_submit {
    position: absolute;
    top: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    padding: 0;
    border: 0;
    border-radius: 9px;
    outline: 0;
    font-size: 16px;
    line-height: 34px;
    cursor: pointer;
}

.hw-header .header-handwriting-search_button {
    right: 42px;
    color: #777777;
    background: transparent;
}

.hw-header .header-handwriting-search_button:hover,
.hw-header .header-handwriting-search_button:focus {
    color: var(--hw-header-blue-deep);
    background: #eaf2f9;
}

.hw-header .header-char_search_form_submit {
    right: 4px;
    color: #ffffff;
    background: var(--hw-header-blue);
    background-image: none;
}

.hw-header .header-char_search_form_submit:hover,
.hw-header .header-char_search_form_submit:focus {
    color: #ffffff;
    background: var(--hw-header-blue-dark);
}

.hw-header #hanzi-search_result {
    top: 50px;
    right: 0;
    left: 0;
    z-index: 20;
    width: auto;
    max-height: 320px;
    margin: 0;
    padding: 6px;
    overflow-y: auto;
    border: 1px solid var(--hw-header-border);
    border-radius: 14px;
    background: #ffffff;
    box-shadow: 0 12px 32px rgba(10, 75, 132, 0.1);
}

.hw-header #hanzi-search_result > li {
    margin: 0;
    padding: 0;
}

.hw-header #hanzi-search_result > li > a {
    display: block;
    padding: 9px 12px;
    border-radius: 9px;
    color: var(--hw-header-muted);
    font-size: 13px;
    line-height: 1.4;
    text-decoration: none;
}

.hw-header #hanzi-search_result > li > a:hover,
.hw-header #hanzi-search_result > li > a:focus {
    color: var(--hw-header-text);
    background: #f3f8fc;
}

.hw-header #hanzi-search_result .search-hanzi_text {
    display: inline-block;
    min-width: 34px;
    color: var(--hw-header-text);
    font-family: "Noto Sans", sans-serif;
    font-size: 21px;
    font-weight: 500;
    text-align: center;
}

.hw-header__search-toggle {
    display: none;
}

.hw-header__slot,
.hw-header__user,
.hw-header__pro,
.hw-header__language {
    flex: 0 0 auto;
}

.hw-header__pro .getpro_link {
    float: none;
    width: auto;
    height: auto;
    padding: 0;
    border: 0;
    background: transparent;
}

.hw-header__pro .getpro_link #getpro {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-width: 92px;
    height: 40px;
    margin: 0;
    padding: 0 14px;
    border-radius: 10px;
    color: #ffffff;
    background: var(--hw-header-blue);
    font-size: 13px;
    font-weight: 700;
    line-height: 1;
    text-align: center;
    transition: background 0.15s ease;
}

.hw-header__pro .getpro_link #getpro:hover,
.hw-header__pro .getpro_link #getpro:focus {
    color: #ffffff;
    background: var(--hw-header-blue-dark);
}

.hw-header__pro .getpro_link #getpro.pro_timer {
    min-width: 210px;
    color: var(--hw-header-blue-deep);
    background: var(--hw-header-blue-soft);
}

.hw-header__pro .getpro_link #getpro.pro_timer:hover,
.hw-header__pro .getpro_link #getpro.pro_timer:focus {
    color: var(--hw-header-blue-deep);
    background: #d2eafc;
}

.hw-header__pro #clockdiv {
    display: flex;
    align-items: center;
    gap: 5px;
    color: inherit;
    font-variant-numeric: tabular-nums;
}

.hw-header__pro #clockdiv .pro_days,
.hw-header__pro #clockdiv .pro_time,
.hw-header__pro #unlimited {
    margin: 0;
    color: inherit;
    font-size: 12px;
    font-weight: 600;
    line-height: 1;
    white-space: nowrap;
}

.hw-header__pro #clockdiv .pro_time {
    min-width: 58px;
}

.hw-header__pro #unlimited {
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
}

.hw-header__language #languages-block-top {
    position: relative;
    float: none;
    width: auto;
    border: 0;
}

.hw-header__language #languages-block-top .current {
    display: flex;
    align-items: center;
    gap: 6px;
    height: 44px;
    margin: 0;
    padding: 0 10px;
    border: 0;
    border-radius: 10px;
    outline: 0;
    color: #515151;
    background: transparent;
    font-size: 13px;
    line-height: 1;
    cursor: pointer;
}

.hw-header__language #languages-block-top .current:after {
    display: none;
}

.hw-header__language #languages-block-top .current:hover,
.hw-header__language #languages-block-top .current:focus,
.hw-header__language #languages-block-top .current.active {
    background: #f3f7fb;
}

.hw-header__language #languages-block-top img {
    display: block;
    width: 21px;
    min-width: 21px;
    height: 14px;
    margin: 0;
    border-radius: 2px;
    object-fit: cover;
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.1);
}

.hw-header__language #languages-block-top .current.active .icon-angle-down {
    transform: rotate(180deg);
}

.hw-header__language #languages-block-top .icon-angle-down {
    transition: transform 0.15s ease;
}

.hw-header__language #languages-block-top ul {
    top: 48px;
    right: 0;
    left: auto;
    width: 160px;
    padding: 6px;
    border: 1px solid var(--hw-header-border);
    border-radius: 12px;
    background: #ffffff;
    box-shadow: 0 12px 30px rgba(10, 75, 132, 0.12);
}

.hw-header__language #languages-block-top ul li {
    font-size: 13px;
    line-height: 1.3;
}

.hw-header__language #languages-block-top ul li a,
.hw-header__language #languages-block-top ul li > span,
.hw-header__language #languages-block-top .selected .lang_class {
    display: block;
    padding: 9px 10px;
    border-radius: 8px;
    color: var(--hw-header-text);
}

.hw-header__language #languages-block-top ul li:hover a {
    color: var(--hw-header-text);
    background: #f3f8fc;
}

.hw-header__language .lang_class {
    display: flex;
    align-items: center;
    gap: 8px;
}

.hw-header__user .header_user_info {
    position: relative;
    float: none;
    width: auto;
}

.hw-header__user .header_user_info > p {
    display: flex;
    align-items: center;
    gap: 7px;
    min-width: 44px;
    height: 40px;
    margin: 0;
    padding: 0 13px;
    border: 1px solid #b9d4ea;
    border-radius: 10px;
    color: var(--hw-header-blue-deep);
    background: #ffffff;
    font-size: 13px;
    font-weight: 600;
    line-height: 1;
    white-space: nowrap;
}

.hw-header__user .header_user_info > p:before {
    content: "\f007";
    font-family: "FontAwesome";
    font-size: 14px;
    font-weight: normal;
}

.hw-header__user .header_user_info > p.account {
    border-color: transparent;
    background: #f3f7fb;
}

.hw-header__user .header_user_info > p:hover,
.hw-header__user .header_user_info > p:focus {
    color: var(--hw-header-blue-deep);
    background: #eaf2f9;
}

.hw-header__user #account_modal {
    top: 48px;
    right: 0;
    z-index: 30;
    width: 220px;
    padding: 6px;
    border: 1px solid var(--hw-header-border);
    border-radius: 12px;
    background: #ffffff;
    box-shadow: 0 12px 30px rgba(10, 75, 132, 0.12);
}

.hw-header__user #account_modal ul {
    margin: 0;
}

.hw-header__user #account_modal ul li {
    line-height: 1.3;
}

.hw-header__user #account_modal ul li a {
    display: block;
    padding: 9px 10px;
    border-radius: 8px;
    color: var(--hw-header-text);
    text-decoration: none;
}

.hw-header__user #account_modal ul li a:hover,
.hw-header__user #account_modal ul li a:focus {
    color: var(--hw-header-text);
    background: #f3f8fc;
}

.hw-header__menu-toggle,
.hw-header__search-toggle {
    align-items: center;
    justify-content: center;
    height: 44px;
    padding: 0 12px;
    border: 0;
    border-radius: 10px;
    outline: 0;
    color: #26313b;
    background: transparent;
    font-size: 14px;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
}

.hw-header__menu-toggle {
    display: flex;
    gap: 9px;
    flex: 0 0 auto;
}

.hw-header__menu-toggle:hover,
.hw-header__menu-toggle:focus,
.hw-header__search-toggle:hover,
.hw-header__search-toggle:focus,
.hw-header.is-menu-open .hw-header__menu-toggle,
.hw-header.is-search-open .hw-header__search-toggle {
    color: var(--hw-header-blue-deep);
    background: #eaf2f9;
}

.hw-header__menu-icon {
    position: relative;
    display: block;
    width: 20px;
    height: 16px;
}

.hw-header__menu-icon span {
    position: absolute;
    left: 0;
    display: block;
    width: 20px;
    height: 2px;
    border-radius: 1px;
    background: currentColor;
    transition: top 0.18s ease, transform 0.18s ease, opacity 0.18s ease;
}

.hw-header__menu-icon span:nth-child(1) {
    top: 1px;
}

.hw-header__menu-icon span:nth-child(2) {
    top: 7px;
}

.hw-header__menu-icon span:nth-child(3) {
    top: 13px;
}

.hw-header.is-menu-open .hw-header__menu-icon span:nth-child(1) {
    top: 7px;
    transform: rotate(45deg);
}

.hw-header.is-menu-open .hw-header__menu-icon span:nth-child(2) {
    opacity: 0;
}

.hw-header.is-menu-open .hw-header__menu-icon span:nth-child(3) {
    top: 7px;
    transform: rotate(-45deg);
}

.hw-header__panel {
    position: absolute;
    top: 100%;
    right: 0;
    left: 0;
    z-index: 15;
    max-height: calc(100vh - 64px);
    overflow-y: auto;
    visibility: hidden;
    border-top: 1px solid #f0eeec;
    border-bottom: 1px solid var(--hw-header-border);
    background: #ffffff;
    opacity: 0;
    box-shadow: 0 18px 36px rgba(10, 75, 132, 0.08);
    transform: translateY(-8px);
    pointer-events: none;
    transition: opacity 0.15s ease, transform 0.15s ease, visibility 0.15s ease;
}

.hw-header.is-menu-open .hw-header__panel {
    visibility: visible;
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.hw-header__panel-container {
    padding-top: 14px;
    padding-bottom: 18px;
}

.hw-main-menu__list {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 4px 12px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.hw-main-menu__list > li {
    position: relative;
    float: none;
    min-width: 0;
    margin: 0;
    padding: 0;
    background: transparent;
}

.hw-main-menu__list > li:before,
.hw-main-menu__list > li:after {
    display: none;
    content: none;
}

.hw-main-menu__list > li > a,
.hw-main-menu__list > li > span {
    display: block;
    min-height: 42px;
    padding: 11px 13px;
    border: 0;
    border-radius: 10px;
    color: var(--hw-header-text);
    background: transparent;
    font-size: 14px;
    font-weight: 600;
    line-height: 20px;
    text-decoration: none;
}

.hw-main-menu__list > li > a:hover,
.hw-main-menu__list > li > a:focus,
.hw-main-menu__list > li.sfHoverForce > a {
    color: var(--hw-header-blue-deep);
    background: #f3f8fc;
}

.hw-main-menu__list li ul {
    position: static;
    display: block;
    width: auto;
    margin: 0 10px 8px;
    padding: 0 0 0 12px;
    border: 0;
    background: transparent;
    box-shadow: none;
    list-style: none;
}

.hw-main-menu__list li ul li a {
    display: block;
    padding: 6px 4px;
    color: var(--hw-header-muted);
    font-size: 13px;
    line-height: 1.4;
    text-decoration: none;
}

.hw-main-menu__list li ul li a:hover,
.hw-main-menu__list li ul li a:focus {
    color: var(--hw-header-blue-deep);
}

.hw-main-menu__search {
    grid-column: 1 / -1;
}

.hw-main-menu__search p {
    margin: 0;
}

.hw-main-menu__search input[type="text"] {
    width: 100%;
    height: 40px;
    padding: 0 12px;
    border: 1px solid #d6d4d4;
    border-radius: 9px;
    outline: 0;
}

.hw-main-menu__search input[type="text"]:focus {
    border-color: var(--hw-header-blue);
}

.hw-header__utilities {
    display: flex;
    align-items: center;
    gap: 18px;
    min-height: 0;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid #f0eeec;
}

.hw-header__utilities:empty {
    display: none;
}

.hw-header__mobile-pro,
.hw-header__mobile-language {
    display: none;
}

.hw-header__contact #contact-link,
.hw-header__contact .shop-phone,
.hw-header__currencies #currencies-block-top {
    position: relative;
    float: none;
    width: auto;
    margin: 0;
    padding: 0;
    border: 0;
}

.hw-header__contact .hw-header__service-links {
    display: flex;
    align-items: center;
    flex-wrap: nowrap;
    gap: 4px;
}

.hw-header__contact #contact-link a,
.hw-header__contact .shop-phone,
.hw-header__currencies #currencies-block-top .current {
    display: flex;
    align-items: center;
    min-height: 36px;
    padding: 0 10px;
    border-radius: 8px;
    color: var(--hw-header-muted);
    background: transparent;
    font-size: 13px;
    line-height: 1.3;
    text-decoration: none;
}

.hw-header__contact #contact-link a:hover,
.hw-header__contact #contact-link a:focus,
.hw-header__currencies #currencies-block-top .current:hover {
    color: var(--hw-header-blue-deep);
    background: #f3f8fc;
}

.hw-header__contact #contact-link .contact-link-text {
    display: inline;
}

.hw-header__contact #contact-link a:after {
    display: none;
}

.hw-header__currencies #currencies-block-top ul {
    top: 40px;
    right: 0;
    left: auto;
    z-index: 20;
}

.hw-header.is-compact .hw-header__bar {
    min-height: 52px;
}

.hw-header.is-compact .hw-header__logo .logo {
    height: 24px;
    max-height: 24px;
}

.hw-header.is-compact .header-char_search_form {
    height: 38px;
    border-radius: 10px;
}

.hw-header.is-compact .header-char_search_form input {
    height: 36px;
    font-size: 14px;
    line-height: 36px;
}

.hw-header.is-compact .header-handwriting-search_button,
.hw-header.is-compact .header-char_search_form_submit {
    top: 3px;
    width: 30px;
    height: 30px;
    border-radius: 8px;
    line-height: 30px;
}

.hw-header.is-compact .header-handwriting-search_button {
    right: 38px;
}

.hw-header.is-compact .header-char_search_form input {
    padding-right: 78px;
}

.hw-header.is-compact .hw-header__language {
    display: none;
}

.hw-header.is-compact .hw-header__pro .getpro_link #getpro.pro_timer {
    min-width: 118px;
}

.hw-header.is-compact .hw-header__pro #clockdiv .pro_time {
    display: none !important;
}

@media (max-width: 1199px) {
    .hw-header__bar {
        gap: 8px;
    }

    .hw-header__logo .logo {
        max-width: 100%;
        height: 24px;
        max-height: 24px;
    }

    .hw-header__language #languages-block-top .current span,
    .hw-header__language #languages-block-top .current .icon-angle-down,
    .hw-header__menu-label {
        display: none;
    }

    .hw-header__language #languages-block-top .current,
    .hw-header__menu-toggle {
        width: 44px;
        padding: 0;
    }

    .hw-header__pro .getpro_link #getpro.pro_timer {
        min-width: 118px;
    }

    .hw-header__pro #clockdiv .pro_time {
        display: none !important;
    }

    .hw-header__user .header_user_info > p {
        max-width: 120px;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .hw-main-menu__list {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 991px) {
    .hw-header__logo .logo {
        max-width: 100%;
    }

    .hw-header__search {
        min-width: 180px;
    }

    .hw-header__user .header_user_info > p {
        width: 44px;
        padding: 0;
        justify-content: center;
    }

    .hw-header__user .header_user_info > p span {
        display: none;
    }

    .hw-main-menu__list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 767px) {
    .hw-header__container {
        width: 100%;
        padding-right: 12px;
        padding-left: 12px;
    }

    .hw-header__bar,
    .hw-header.is-compact .hw-header__bar {
        flex-wrap: wrap;
        gap: 4px;
        min-height: 56px;
        padding: 6px 0;
    }

    .hw-header__logo {
        margin-right: auto;
    }

    .hw-header__logo .logo,
    .hw-header.is-compact .hw-header__logo .logo {
        max-width: 100%;
        height: 24px;
        max-height: 24px;
    }

    .hw-header__search-toggle {
        display: flex;
        flex: 0 0 42px;
        width: 42px;
        height: 42px;
        padding: 0;
    }

    .hw-header__search {
        display: none;
        flex: 0 0 100%;
        order: 10;
        min-width: 0;
        padding: 4px 0 2px;
    }

    .hw-header.is-search-open .hw-header__search {
        display: block;
    }

    .hw-header .header-char_search_form,
    .hw-header.is-compact .header-char_search_form {
        height: 44px;
        border-radius: 12px;
    }

    .hw-header .header-char_search_form input,
    .hw-header.is-compact .header-char_search_form input {
        height: 42px;
        padding-right: 88px;
        border-radius: 12px;
        font-size: 15px;
        line-height: 42px;
    }

    .hw-header .header-handwriting-search_button,
    .hw-header .header-char_search_form_submit,
    .hw-header.is-compact .header-handwriting-search_button,
    .hw-header.is-compact .header-char_search_form_submit {
        top: 4px;
        width: 34px;
        height: 34px;
        border-radius: 9px;
        line-height: 34px;
    }

    .hw-header .header-handwriting-search_button,
    .hw-header.is-compact .header-handwriting-search_button {
        right: 42px;
    }

    .hw-header__slot--pro,
    .hw-header__slot--language {
        display: none;
    }

    .hw-header__user .header_user_info > p {
        width: 42px;
        min-width: 42px;
        height: 42px;
    }

    .hw-header__menu-toggle {
        width: 42px;
        height: 42px;
    }

    .hw-header__menu-icon {
        width: 19px;
    }

    .hw-header__menu-icon span {
        width: 19px;
    }

    .hw-header__panel {
        max-height: calc(100vh - 56px);
    }

    .hw-header__panel-container {
        width: 100%;
        padding: 12px;
    }

    .hw-header__mobile-pro,
    .hw-header__mobile-language {
        display: block;
    }

    .hw-header__mobile-pro:not(:empty) {
        margin-bottom: 10px;
        padding-bottom: 10px;
        border-bottom: 1px solid #f0eeec;
    }

    .hw-header__mobile-pro .hw-header__pro .getpro_link #getpro,
    .hw-header__mobile-pro .hw-header__pro .getpro_link #getpro.pro_timer {
        width: 100%;
        min-width: 0;
    }

    .hw-header__mobile-pro .hw-header__pro .getpro_link {
        width: 100%;
    }

    .hw-header__mobile-pro .hw-header__pro #clockdiv .pro_time {
        display: block !important;
    }

    .hw-main-menu__list {
        grid-template-columns: 1fr;
        gap: 2px;
    }

    .hw-main-menu__list > li > a,
    .hw-main-menu__list > li > span {
        min-height: 44px;
        padding: 12px;
    }

    .hw-header__utilities {
        align-items: stretch;
        flex-direction: column;
        gap: 4px;
    }

    .hw-header__mobile-language .hw-header__language #languages-block-top .current {
        justify-content: flex-start;
        width: 100%;
        padding: 0 10px;
    }

    .hw-header__mobile-language .hw-header__language #languages-block-top .current span,
    .hw-header__mobile-language .hw-header__language #languages-block-top .current .icon-angle-down {
        display: inline-block;
    }

    .hw-header__mobile-language .hw-header__language #languages-block-top .current .icon-angle-down {
        margin-left: auto;
    }

    .hw-header__mobile-language .hw-header__language #languages-block-top ul,
    .hw-header__currencies #currencies-block-top ul {
        position: static;
        width: 100%;
        margin-top: 4px;
        box-shadow: none;
    }

    .hw-header__contact #contact-link a,
    .hw-header__contact .shop-phone,
    .hw-header__currencies #currencies-block-top .current {
        min-height: 44px;
    }

    .hw-header__contact .hw-header__service-links {
        align-items: stretch;
        flex-direction: column;
        gap: 0;
        width: 100%;
    }

    .hw-header__user #account_modal {
        position: fixed;
        top: 62px;
        right: 12px;
        width: calc(100vw - 24px);
        max-width: 260px;
    }
}

@media (max-width: 379px) {
    .hw-header__container {
        padding-right: 8px;
        padding-left: 8px;
    }

    .hw-header__logo .logo,
    .hw-header.is-compact .hw-header__logo .logo {
        max-width: 100%;
    }

    .hw-header__search-toggle,
    .hw-header__menu-toggle,
    .hw-header__user .header_user_info > p {
        width: 40px;
        min-width: 40px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .hw-header__bar,
    .hw-header__panel,
    .hw-header__menu-icon span {
        transition: none;
    }
}
