/* Decorative zone backgrounds must not intercept clicks */
.zone .zone-bg {
    pointer-events: none;
}

.zone > header,
.zone > .container {
    position: relative;
    z-index: 1;
    pointer-events: auto;
}

/* Header zone (data-zone="18249") */
#zone1.blk-middle {
    position: sticky;
    top: 0;
    z-index: 25;
}

#zone1 #header {
    position: relative;
    z-index: 2;
    pointer-events: auto;
}

#zone1 a,
#zone1 button,
#zone1 .order-sertificate-button a {
    pointer-events: auto;
    cursor: pointer;
}

/* Max/Viber + cost form zone — visible only on main page in original CSS */
body.home #zone24,
body.mainpage #zone24 {
    display: block !important;
}

/* Replace WhatsApp glyph (obj-type-8) with Max icon */
ul.soc_bar li.obj-type-8 > a,
ul.soc_bar li.obj-type-max > a {
    background: none !important;
    position: relative !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

ul.soc_bar li.obj-type-8 > a:before,
ul.soc_bar li.obj-type-max > a:before {
    content: '' !important;
    color: transparent !important;
    background: url('../images/max.svg') center / contain no-repeat !important;
    width: 32px !important;
    height: 32px !important;
    border-radius: 8px;
    font-size: 0 !important;
    display: block !important;
    margin: auto !important;
    position: absolute !important;
    inset: 0 !important;
}

/* Wide Max/Viber buttons on homepage form: icon on the left, not centered in the bar */
#zone24 ul.soc_bar li.obj-type-8 > a,
#zone24 ul.soc_bar li.obj-type-max > a,
#block72 ul.soc_bar li.obj-type-8 > a,
#block72 ul.soc_bar li.obj-type-max > a {
    justify-content: flex-start !important;
}

#zone24 ul.soc_bar li.obj-type-8 > a:before,
#zone24 ul.soc_bar li.obj-type-max > a:before,
#block72 ul.soc_bar li.obj-type-8 > a:before,
#block72 ul.soc_bar li.obj-type-max > a:before {
    inset: auto !important;
    top: 0 !important;
    left: 0 !important;
    right: auto !important;
    bottom: auto !important;
    margin: 0 !important;
    width: 45px !important;
    height: 45px !important;
    background-size: 32px 32px !important;
    background-position: center !important;
}

@media screen and (max-width: 1279px) and (min-width: 781px) {
    #zone24 ul.soc_bar li.obj-type-8 > a:before,
    #zone24 ul.soc_bar li.obj-type-max > a:before,
    #block72 ul.soc_bar li.obj-type-8 > a:before,
    #block72 ul.soc_bar li.obj-type-max > a:before {
        width: 40px !important;
        height: 40px !important;
        background-size: 28px 28px !important;
    }
}

@media screen and (max-width: 780px) {
    #zone24 ul.soc_bar li.obj-type-8 > a:before,
    #zone24 ul.soc_bar li.obj-type-max > a:before,
    #block72 ul.soc_bar li.obj-type-8 > a:before,
    #block72 ul.soc_bar li.obj-type-max > a:before {
        width: 33px !important;
        height: 33px !important;
        background-size: 24px 24px !important;
    }
}

/* Footer zone (18246) sits inside #main — drop duplicate sidebar offset */
#zone10,
section[data-zone="18246"],
#zone6,
section[data-zone="18245"],
#zone23,
section[data-zone="18428"],
#zone11,
section[data-zone="18250"] {
    margin-left: 0 !important;
}

/* Inner pages: listing should not stretch to full viewport */
body.innerpage #content {
    min-height: 0 !important;
}

body.innerpage .zone.zone5 .container-zone:empty {
    display: none;
}

/* Inner pages: match homepage content width (container_100) */
body:not(.mainpage) #center,
body:not(.mainpage) #center > .centerwrap {
    width: 100% !important;
    max-width: none !important;
}

body:not(.mainpage) #center > .centerwrap.container_12,
body:not(.mainpage) #center .container_12:not(.centerwrap) {
    width: 100% !important;
    max-width: none !important;
}

body:not(.mainpage) #content.grid_12 {
    display: block !important;
    width: 100% !important;
    max-width: none !important;
    float: none !important;
}

body:not(.mainpage) #zone10 .container.container_100,
body:not(.mainpage) #zone6 .container.container_100 {
    width: 100% !important;
    max-width: none !important;
}

@media screen and (min-width: 780px) {
    .innerpage .zone.zone3.cb {
        margin-top: 30px;
    }
}

body.innerpage #content,
body.innerpage .zone-title,
body.innerpage .zone-content,
body.innerpage .news-textfull {
    text-align: left;
}

/* Original CSS hides #block69/#block70 on inner pages unless body has subdiv-uslugi */
body.subdiv-uslugi #zone11,
body.subdiv-uslugi #zone11 .container,
body.subdiv-uslugi section#block69,
body.subdiv-uslugi section#block70,
body.show-cooperation-zone #zone11,
body.show-cooperation-zone #zone11 .container,
body.show-cooperation-zone section#block69,
body.show-cooperation-zone section#block70 {
    display: block !important;
}

body.subdiv-uslugi #zone11 .container.container_12,
body.show-cooperation-zone #zone11 .container.container_12 {
    width: 100%;
    max-width: none;
    height: auto;
}

#header .tel_lnk_btn {
    display: none !important;
}

#zone10 .nice-select.select-style .list,
#zone10 .nice-select .list {
    display: none !important;
}

#zone10 .nice-select.select-style::after,
#zone10 .nice-select.select-style:after {
    display: none !important;
    content: none !important;
}

/* MegaFon callback widget attribution after footer */
.itlcb-bottom-txt,
.itlcb-bottom-txt-block,
#itlcb-wrapper .itlcb-auth-link,
#itlcb-wrapper .itlcb-megafon-link,
#itlcb-wrapper a[href*="megafon"],
#itlcb-wrapper a[href*="multifon"] {
    display: none !important;
}

/* CMS admin controls from imported static markup */
.bc_zone_btn,
.bc_blk_btn,
.bc_buttons,
.block-edit-content,
.block-edit-obj-btn,
.zone-edit,
#adm {
    display: none !important;
}

#notification {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 100000;
    max-width: 420px;
    pointer-events: none;
}

#notification .alert {
    pointer-events: auto;
}

#notification .alert.none {
    display: none !important;
}

#сonfirm-actions {
    display: none !important;
}

#pmexpert-modal-callme,
#pmexpert-modal-feedback {
    display: none;
}

#lightcase-case.callme .callForm,
#lightcase-case.modal-form .callForm,
#lightcase-case.feedback .callForm {
    padding: 8px 6px 16px;
}

#lightcase-case.callme .userline {
    margin-bottom: 12px;
}

#lightcase-case.feedback .userline {
    margin-bottom: 12px;
}

#lightcase-case.callme .input-line-time .input-line-title {
    margin-bottom: 10px;
    line-height: 1.4;
}

#lightcase-case.callme .input-line-time .input-field-standart {
    display: inline-block;
    width: 46%;
    margin: 0 2% 0 0;
    vertical-align: top;
}

@media screen and (max-width: 780px) {
    #mobile-menu.active {
        left: 0 !important;
    }
}

/* Show news card dates (bc_custom hides .template-1 .news-date) */
.template-1 .news-item .news-date {
    display: block !important;
    position: absolute;
    left: 0;
    top: 10px;
    z-index: 2;
    background: linear-gradient(45deg, #e95137, #fc831b);
    padding: 5px 10px;
    border-radius: 0 3px 3px 0;
}

.template-1 .news-item .news-date > *,
.template-1 .news-item .date-type-1 span {
    background: transparent !important;
    color: #fff !important;
    font-size: 13px;
    padding: 0;
}

.template-1 .news-item .news-body {
    position: relative;
}

/* Uniform homepage news cards only — do not affect service listings */
#zone22 .news-items .news-item .news-body {
    display: flex;
    flex-direction: column;
    height: 100%;
    position: relative;
}

#zone22 .news-items.owl-carousel .owl-item {
    display: flex;
    height: auto;
}

#zone22 .news-items .news-item {
    display: flex;
    height: 100%;
}

#zone22 .news-items .image-default.image-cover {
    display: block;
    min-height: 150px;
    overflow: hidden;
}

#zone22 .news-items .image-default.image-cover a {
    display: block;
    min-height: 150px;
}

#zone22 .news-items .image-default.image-cover img {
    display: block;
    width: 100%;
    height: 150px;
    object-fit: cover;
}

#zone22 .news-items .news-data {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
}

#zone22 .news-items .news-name {
    line-height: 1.35;
    min-height: calc(1.35em * 2);
    margin-bottom: 6px;
}

#zone22 .news-items .news-name a {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    line-height: 1.35;
    min-height: calc(1.35em * 2);
}

#zone22 .news-items .news-text {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    overflow: hidden;
    line-height: 1.4;
    min-height: calc(1.4em * 3);
    max-height: calc(1.4em * 3);
}

/* Homepage service cards — keep original #block48 layout, make whole card clickable */
#zone16 .news-body {
    position: relative;
}

#zone16 .news-card-hit {
    position: absolute;
    inset: 0;
    z-index: 5;
}

#block48 .news-item .news-data,
#zone16 .news-item .news-data {
    position: static !important;
}

#block48 .news-item .news-name a,
#zone16 .news-item .news-name a {
    position: static !important;
    left: auto !important;
    right: auto !important;
    bottom: auto !important;
    top: auto !important;
    width: auto !important;
    height: auto !important;
    min-height: 0 !important;
    padding: 8px 16px 48px !important;
    display: block;
}

@media screen and (max-width: 780px) {
    #zone22 .news-items .image-default.image-cover,
    #zone22 .news-items .image-default.image-cover a {
        min-height: 120px;
    }

    #zone22 .news-items .image-default.image-cover img {
        height: 120px;
    }
}

#lightcase-case.callme .soglas_main_container {
    margin: 12px 0;
    font-size: 13px;
}

#lightcase-case.callme .modal_button_main {
    margin-top: 12px;
    text-align: center;
}
