/* Hebrew production RTL normalization: applies only to layouts with lang="he". */
html[lang="he"],
html[lang="he"] body.dm-hebrew {
    direction: rtl;
}
html[lang="he"] body.dm-hebrew {
    text-align: right;
    unicode-bidi: plaintext;
}

/* Fixed desktop navigation stays cleanly on the right edge. */
html[lang="he"] .menu {
    right: 0;
    left: auto;
    direction: rtl;
}
html[lang="he"] .menu ul,
html[lang="he"] .menufooter {
    padding-right: 0;
    padding-left: 0;
}
html[lang="he"] .menu ul li {
    margin-right: 0;
    margin-left: 0;
}
html[lang="he"] .tooltip-right,
html[lang="he"] .tooltip-left {
    direction: rtl;
}

/* Mobile menu enters from the right, with right-aligned Hebrew items. */
html[lang="he"] #hamburger {
    right: 15px;
    left: auto;
}
html[lang="he"] #bg-menu-mobile {
    right: -100%;
    left: auto;
}
html[lang="he"] .mobul {
    right: 0;
    left: auto;
    padding-right: 0;
    padding-left: 0;
    text-align: right;
    direction: rtl;
}
html[lang="he"] .mobul li {
    right: -100%;
    left: auto;
    margin-right: 20px;
    margin-left: 0;
    text-align: right;
}

/* Content, prose, lists and inline legacy alignments. */
html[lang="he"] .content,
html[lang="he"] .services,
html[lang="he"] .servicesbox,
html[lang="he"] .case-information,
html[lang="he"] .post,
html[lang="he"] .footer_text,
html[lang="he"] .portfolio-next-step,
html[lang="he"] .container-popup {
    direction: rtl;
    text-align: right;
}
html[lang="he"] .servicesbox .list,
html[lang="he"] .servicesbox li,
html[lang="he"] .post li,
html[lang="he"] .post p,
html[lang="he"] [style*="text-align: left"] {
    text-align: right !important;
}
html[lang="he"] .servicesbox ul,
html[lang="he"] .post ul,
html[lang="he"] .post ol,
html[lang="he"] .ulchec {
    padding-right: 1em;
    padding-left: 0;
}

/* Nao inputs: text, label origin and underline animation are mirrored. */
html[lang="he"] .input,
html[lang="he"] .input__field,
html[lang="he"] .textarea-input,
html[lang="he"] textarea,
html[lang="he"] .telinput {
    direction: rtl;
    text-align: right;
}
html[lang="he"] .input__label--nao,
html[lang="he"] .input__label-content--nao {
    right: 0;
    left: auto;
    text-align: right;
    -webkit-transform-origin: 100% 0;
    transform-origin: 100% 0;
}
html[lang="he"] .input__field--nao:focus ~ .graphic--nao,
html[lang="he"] .input--filled .graphic--nao {
    -webkit-transform: translate3d(66.6%, 0, 0);
    transform: translate3d(66.6%, 0, 0);
}
html[lang="he"] input[type="email"],
html[lang="he"] input[type="tel"],
html[lang="he"] input[name="phone"],
html[lang="he"] input[name="email"] {
    direction: ltr;
    text-align: left;
}
html[lang="he"] .iti {
    direction: ltr;
    margin-right: 1em;
    margin-left: 0;
}
html[lang="he"] .iti input {
    direction: ltr;
    text-align: left;
}

/* Hebrew Brief and secondary form controls. */
html[lang="he"] .bifh1,
html[lang="he"] .formbox,
html[lang="he"] .lichec,
html[lang="he"] .checkbox {
    text-align: right;
}
html[lang="he"] textarea,
html[lang="he"] .textarea-input {
    margin-right: 1em;
    margin-left: 0;
}
html[lang="he"] .checkbox .checkbox-label {
    float: right;
    margin-right: 0;
    margin-left: 20px;
}
html[lang="he"] .checkbox .checkbox-label::after {
    right: -2px;
    left: auto;
}
html[lang="he"] .checkbox .checkbox-input:checked ~ label::after {
    right: 20px;
    left: auto;
}
html[lang="he"] .divine-captcha,
html[lang="he"] #result {
    direction: ltr;
    text-align: center;
}
html[lang="he"] .divine-captcha > * {
    margin-right: auto;
    margin-left: auto;
}

/* Cards and components preserve intentional centered visual hierarchy. */
html[lang="he"] .work-list,
html[lang="he"] .work__info,
html[lang="he"] .work__infotable,
html[lang="he"] .work__infocell,
html[lang="he"] .border-title,
html[lang="he"] .hed-title-div,
html[lang="he"] .hed-title-div-port,
html[lang="he"] .portfolio-next-step-actions,
html[lang="he"] .social-btn-1s {
    direction: rtl;
}
html[lang="he"] .work__title,
html[lang="he"] .work__subtitle,
html[lang="he"] .border-title,
html[lang="he"] .hed-title-div,
html[lang="he"] .hed-title-div-port,
html[lang="he"] .portfolio-next-step {
    text-align: center;
}
html[lang="he"] .work-categories {
    direction: rtl;
}
html[lang="he"] .case-information-header,
html[lang="he"] .case-information-card,
html[lang="he"] .case-information-value,
html[lang="he"] .taurl {
    text-align: right;
}
html[lang="he"] .case-information-link {
    direction: rtl;
}

/* Keep non-Hebrew technical or social controls naturally ordered. */
html[lang="he"] .g-recaptcha,
html[lang="he"] .social-btn-1s,
html[lang="he"] .footerend,
html[lang="he"] .pagination,
html[lang="he"] .fancybox-container {
    direction: ltr;
}
html[lang="he"] .menufooter {
    direction: rtl;
}
html[lang="he"] .menufooter li {
    float: right;
}

@media (max-width: 767px) {
    html[lang="he"] .mobul li {
        font-size: clamp(23px, 7vw, 30px);
    }
    html[lang="he"] .menufooter li {
        float: none;
        display: inline-block;
    }
    html[lang="he"] .textarea-input {
        width: calc(100% - 2em);
    }
}


/* Sidebar hover labels: Hebrew rail is on the right, so labels must expand left. */
html[lang="he"] .menu .tooltip-right .inner {
    left: auto;
    right: 100%;
    direction: rtl;
    text-align: right;
}
html[lang="he"] .menu .tooltip-right:hover .inner {
    left: auto;
    right: 120%;
}
html[lang="he"] .menu .tooltip-right .inner:before {
    left: 0;
    right: auto;
}


/* User-screenshot frontend repair: centred rail, unobstructed titles and centred form action. */
/* Centre the full desktop icon rail vertically inside the fixed right sidebar. */
html[lang="he"] .menu ul {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    margin: 0;
    padding: 0;
}
html[lang="he"] .menu ul li {
    flex: 0 0 auto;
    width: 44px;
    margin: 0 0 30px;
}
html[lang="he"] .menu ul li:last-child { margin-bottom: 0; }
/* Use a real flex heading divider. Lines sit beside the Hebrew title, never through glyphs. */
html[lang="he"] .border-title {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    overflow: hidden;
    text-align: center;
}
html[lang="he"] .border-title::before,
html[lang="he"] .border-title::after {
    position: static;
    flex: 1 1 auto;
    width: auto;
    min-width: 18px;
    height: 4px;
    margin: 0;
}
html[lang="he"] .border-title h1,
html[lang="he"] .border-title h3 {
    position: relative;
    z-index: 1;
    flex: 0 0 auto;
    margin: 0;
    padding: 0;
    line-height: 1.2;
}
/* CAPTCHA and submit form one centred vertical action group. */
html[lang="he"] .divine-captcha,
html[lang="he"] form[data-request="onMailFormContact"] .divine-captcha,
html[lang="he"] form[data-request="emptyForm::onFormSubmit"] .divine-captcha {
    justify-content: center !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
}
html[lang="he"] #result {
    display: flex;
    justify-content: center;
    width: 100%;
    text-align: center;
    direction: rtl;
}
html[lang="he"] #result button,
html[lang="he"] form[data-request="onMailFormContact"] #result button,
html[lang="he"] form[data-request="emptyForm::onFormSubmit"] #result button {
    display: inline-block;
    margin: 0 !important;
}


/* User-screenshot follow-up: centre logo and icon rail as one group. */
html[lang="he"] .menu {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}
html[lang="he"] .menu .logo {
    flex: 0 0 auto;
    margin: 0 0 28px;
    width: 100%;
    text-align: center;
}
html[lang="he"] .menu ul {
    flex: 0 0 auto;
    height: auto;
    margin: 0;
}


/* Keep the original mobile hamburger navigation below the base 700px breakpoint. */
@media (max-width: 700px) {
    html[lang="he"] .menu { display: none !important; }
}




html[lang="he"] .hed .iconpok span {
    position: absolute;
    top: 112px;
    left: 50%;
    width: 120px;
    transform: translateX(-50%);
    display: block;
    color: #fff;
    text-align: center;
    direction: rtl;
}

/* Hebrew UI: right rail matches RU/EN spacing; language content remains RTL. */
@media (min-width: 701px) {
    html[lang="he"] .menu {
        right: 0;
        left: auto;
        direction: rtl;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: flex-start;
    }
    html[lang="he"] .menu .logo {
        width: 100%;
        margin: 60px 0 28px;
        text-align: center;
    }
    html[lang="he"] .menu ul {
        display: flex;
        flex: 0 0 auto;
        flex-direction: column;
        align-items: center;
        gap: 30px;
        height: auto;
        margin: 0;
        padding: 0;
    }
    html[lang="he"] .menu ul li {
        flex: 0 0 44px;
        width: 44px;
        margin: 0;
    }
}
html[lang="he"] #trigger-overlay {
    left: 15px;
    right: auto;
}

/* Hebrew footer copyright stays centred with the shared social row. */
html[lang="he"] .footer_text,
html[lang="he"] .footer_text p { text-align: center; }
html[lang="he"] .footer_text a { display: inline-block; }


/* Hebrew hero: each label is anchored to its own centered icon, matching RU. */
html[lang="he"] .hed-title-div .iconpok {
    position: relative;
    display: inline-block;
    height: 100px;
    line-height: normal;
}
html[lang="he"] .hed-title-div .iconpok span {
    position: absolute !important;
    top: 112px !important;
    left: 50% !important;
    right: auto !important;
    display: block !important;
    width: max-content !important;
    margin: 0 !important;
    transform: translateX(-50%) !important;
    font-size: 14px;
    line-height: 1.2;
    white-space: nowrap;
}
@media (max-width: 700px) {
    html[lang="he"] .hed-title-div .iconpok { width: 84px; height: 84px; }
    html[lang="he"] .hed-title-div .iconpok span { top: 92px !important; font-size: 12px; }
}


/* Hebrew home: keep the image after the companies block visible even if parallax falls behind the page. */
html[lang="he"] .god {
    background-image: url("../img/god.jpg") !important;
    background-repeat: no-repeat;
    background-position: center center;
    background-size: cover;
}


/* Keep the native red services CTA and centre it without changing its component display. */
html[lang="he"] .services > .container > .button--btn {
    display: inline;
    width: auto;
    margin: 40px 0;
    position: relative;
    left: 50%;
    transform: translateX(-50%);
}


/* Hebrew desktop hero artwork follows the approved vertical alignment. */
@media (min-width: 701px) {
    html[lang="he"] .hed-title-div .iconpok > img {
        margin-top: 20px;
    }
}


/* Hebrew services CTA stays centered inside its own content column. */
html[lang="he"] .services > .container {
    text-align: center;
}
html[lang="he"] .services > .container > .button--btn {
    display: inline-block;
    position: static;
    left: auto;
    transform: none;
    margin: 40px 0;
}


/* Hebrew desktop uses the mirrored content canvas: navigation rail stays on the right. */
@media (min-width: 701px) {
    html[lang="he"] .content {
        margin-left: 0;
        margin-right: 115px;
    }
}

/* Centre the artwork inside every red hero circle without moving its label. */
html[lang="he"] .hed-title-div .iconpok {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
@media (min-width: 701px) {
    html[lang="he"] .hed-title-div .iconpok > img {
        margin-top: 0;
    }
}

/* Centre each social glyph within its 90px square. */
html[lang="he"] #footer .social-btn-1s a.btn-1 {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}
html[lang="he"] #footer .social-btn-1s a.btn-1 > i {
    display: block;
    line-height: 1;
    vertical-align: baseline;
}


/* Decorative parallax and button artwork must never create horizontal scrolling in HE. */
html[lang="he"],
html[lang="he"] body.dm-hebrew {
    max-width: 100%;
    overflow-x: hidden;
    overflow-x: clip;
}


/* HE footer remains within the viewport on phones and preserves usable touch targets. */
@media (max-width: 700px) {
    html[lang="he"] #footer .container,
    html[lang="he"] #footer .footerend {
        box-sizing: border-box;
        width: 100%;
        max-width: 100%;
        margin-left: 0;
        margin-right: 0;
        padding-left: 16px;
        padding-right: 16px;
    }
    html[lang="he"] #footer .menufooter {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 8px 16px;
        width: 100%;
        margin: 24px 0;
        padding: 0;
    }
    html[lang="he"] #footer .menufooter li,
    html[lang="he"] #footer .footer-menu {
        width: auto;
        margin: 0;
    }
    html[lang="he"] #footer .social-btn-1s {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 12px;
        width: 100%;
        margin: 0;
        padding: 0;
    }
    html[lang="he"] #footer .social-btn-1s a.btn-1 {
        flex: 0 0 44px;
        width: 44px;
        height: 44px;
        margin: 0;
    }
}


/* Keep decorative children from expanding the HE page beyond its viewport. */
html[lang="he"] .content {
    contain: paint;
}
