.blog-categority .card-img-top { height: 180px; object-fit: cover; width: 100%; }
.alert { margin-top: 1rem; }
.blog-detail-contain img { max-width: 100%; height: auto; }

/* Home blog: keep card type inside .home-blog / .blog-categority; do not leak into features. */
.home-blog {
    padding-top: 2.5rem;
    padding-bottom: 0;
}

.home-blog .title {
    margin-bottom: 1.25rem;
}

.home-blog__head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 0.75rem 1.25rem;
    flex-wrap: wrap;
}

.home-blog__head h2 {
    margin-bottom: 0;
}

.home-blog__all {
    font-family: Rubik, sans-serif;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.2;
    color: var(--theme-color, #465bd0);
    text-decoration: underline;
    text-underline-offset: 0.15em;
    white-space: nowrap;
    padding-bottom: 16px;
}

.home-blog__all:hover,
.home-blog__all:focus-visible {
    color: var(--theme-color, #465bd0);
    opacity: 0.85;
}

.home-blog .blog-categority .card-body h5 {
    font-size: 14px;
    font-weight: 400;
    color: var(--theme-color, #465bd0);
    margin-bottom: 6px;
}

.home-blog .blog-categority .card-body h2,
.home-blog .blog-categority .card-body h2.card-title {
    font-size: 16px;
    font-weight: 500;
    line-height: 1.3;
    margin-bottom: 0;
    color: #212529;
    font-family: Rubik, sans-serif;
    letter-spacing: normal;
    text-transform: none;
}

.home-extra {
    padding-top: 0;
    padding-bottom: 0;
}

.cookie-banner {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1080;
    background: #1d1d1d;
    color: #fff;
    padding: 1rem 1.25rem;
    padding-left: calc(1.25rem + env(safe-area-inset-left, 0px));
    padding-right: calc(1.25rem + env(safe-area-inset-right, 0px));
    box-shadow: 0 -4px 20px rgba(0,0,0,.2);
}
.cookie-banner__inner {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    gap: 1rem;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
}
.cookie-banner a { color: #fff; text-decoration: underline; }
.cookie-banner__actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.cookie-banner__ghost {
    color: #fff;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.55);
    min-height: 44px;
}
.cookie-banner__ghost:hover,
.cookie-banner__ghost:focus-visible {
    color: #fff;
    background: rgba(255, 255, 255, 0.12);
}

.location-map {
    min-height: 400px;
    width: 100%;
    margin: 0 auto 2rem;
    background: #f4f4f4;
}
.location-map iframe,
.location-map ymaps {
    width: 100% !important;
}

/* Desktop: hide mobile accordion markers so the theme chevron stays after «Услуги». */
@media (min-width: 1200px) {
    header .main-navbar .nav-menu > li > a .according-menu {
        display: none;
    }
}

body .bg-overlay {
    z-index: 1050;
}

body.nav-open {
    overflow: hidden;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.header-call {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--theme-color, #e22454);
    color: #fff !important;
    font-size: 1.05rem;
}

.header-call:hover,
.header-call:focus-visible {
    color: #fff !important;
    opacity: 0.92;
}

.footer-action-link {
    text-decoration: underline;
    text-underline-offset: 0.15em;
}

.home-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    margin-top: 1rem;
    position: relative;
    z-index: 1;
}

.home-hero-actions .btn {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
}

/*
 * Theme .btn-solid-default uses ::before (z-index: -1) as the fill, then
 * .btn-solid-default:hover::before { opacity: 0 } so the parent becomes an outline.
 * That is correct on the white header (.header-book). Inside .collection-banner
 * (overflow: hidden, photo behind the label) the faded ::before leaves a ghost
 * «Подробнее» on the dark image. Do not target header buttons.
 *
 * Overlay buttons therefore use a real background and disable ::before entirely.
 * Hero pair: primary «Записаться» is solid; secondary «Позвонить» is opaque white.
 */
.btn.btn-on-dark,
.home-hero-actions .btn.btn-solid-default,
.collection-banner .btn.btn-solid-default,
.cookie-banner .btn.btn-solid-default {
    isolation: isolate;
    overflow: hidden;
    background-color: var(--theme-color, #465bd0);
    color: #fff;
    border-color: var(--theme-color, #465bd0);
}

.home-hero-actions .btn.btn-on-dark-secondary {
    isolation: isolate;
    overflow: hidden;
    background-color: #fff;
    color: var(--theme-color, #465bd0);
    border: 1px solid #fff;
}

.btn.btn-on-dark::before,
.home-hero-actions .btn::before,
.collection-banner .btn::before,
.banner-style-2 .btn::before,
.offer-banner .btn::before,
.cookie-banner .btn.btn-solid-default::before {
    content: none !important;
    display: none !important;
}

.home-hero-actions a.btn.btn-solid-default:hover,
.home-hero-actions a.btn.btn-solid-default:focus,
.home-hero-actions a.btn.btn-solid-default:focus-visible,
.home-hero-actions a.btn.btn-on-dark:hover,
.home-hero-actions a.btn.btn-on-dark:focus,
.banner-style-2 a.btn:hover,
.banner-style-2 a.btn:focus,
.banner-style-2 a.btn:focus-visible,
.offer-banner a.btn:hover,
.offer-banner a.btn:focus,
.collection-banner a.btn:hover,
.collection-banner a.btn:focus,
.collection-banner a.btn:focus-visible,
.cookie-banner .btn.btn-solid-default:hover,
.cookie-banner .btn.btn-solid-default:focus,
a.btn.btn-on-dark:hover,
a.btn.btn-on-dark:focus,
a.btn.btn-on-dark:focus-visible,
button.btn.btn-on-dark:hover,
button.btn.btn-on-dark:focus {
    color: var(--theme-color, #465bd0) !important;
    background: #fff !important;
    background-color: #fff !important;
    border-color: var(--theme-color, #465bd0) !important;
}

.home-hero-actions a.btn.btn-on-dark-secondary:hover,
.home-hero-actions a.btn.btn-on-dark-secondary:focus,
.home-hero-actions a.btn.btn-on-dark-secondary:focus-visible {
    color: #fff !important;
    background: var(--theme-color, #465bd0) !important;
    background-color: var(--theme-color, #465bd0) !important;
    border-color: #fff !important;
}

.overlay-copy {
    color: #fff !important;
    text-shadow:
        0 0 3px rgba(0, 0, 0, 0.9),
        0 1px 2px rgba(0, 0, 0, 0.95),
        0 8px 22px rgba(0, 0, 0, 0.45);
    -webkit-text-stroke: 0.45px rgba(0, 0, 0, 0.55);
    paint-order: stroke fill;
    text-wrap: balance;
}

.home-style-2 .left-content {
    position: relative;
}

.home-style-2 .left-content::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background: linear-gradient(90deg, rgba(8, 10, 14, 0.62) 0%, rgba(8, 10, 14, 0.32) 42%, rgba(8, 10, 14, 0.08) 70%, transparent 100%);
}

.home-style-2 .left-content .home-content {
    position: relative;
    z-index: 1;
}

.home-style-2 .left-content .home-content h1 {
    font-size: clamp(1.2rem, 0.85rem + 1.2vw, 2rem);
    line-height: 1.18;
    color: #fff;
    max-width: 22em;
    margin-bottom: 0.75rem;
}

.collection-banner::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background: linear-gradient(90deg, rgba(8, 10, 14, 0.6) 0%, rgba(8, 10, 14, 0.28) 46%, rgba(8, 10, 14, 0.06) 72%, transparent 100%);
}

.collection-banner.p-right::after,
.collection-banner.text-right::after {
    background: linear-gradient(270deg, rgba(8, 10, 14, 0.6) 0%, rgba(8, 10, 14, 0.28) 46%, rgba(8, 10, 14, 0.06) 72%, transparent 100%);
}

.collection-banner .banner-text {
    z-index: 2;
}

.collection-banner .banner-content .btn {
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
}

:root {
    --bs-breadcrumb-divider: '/';
}

.cms-breadcrumbs .breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    row-gap: 0.2rem;
    margin-bottom: 0;
    font-size: 0.92rem;
    list-style: none;
}

.cms-breadcrumbs .breadcrumb-item,
.cms-breadcrumbs .breadcrumb-item.active {
    display: inline-flex;
    align-items: center;
    color: #3a3a3a;
}

.cms-breadcrumbs .breadcrumb-item + .breadcrumb-item::before {
    content: var(--bs-breadcrumb-divider, "/");
    float: none;
    padding: 0 0.5rem;
    color: #8a8a8a;
}

.cms-breadcrumbs .breadcrumb-item a {
    color: var(--theme-color, #465bd0);
    text-decoration: underline;
    text-underline-offset: 0.12em;
}

.blog-detail-contain h1.card-title {
    line-height: 1.25;
    letter-spacing: -0.015em;
    text-wrap: balance;
    overflow-wrap: anywhere;
}

.blog-details .blog-detail-contain p,
.blog-details .blog-detail-contain .cms-content p {
    text-align: start;
    letter-spacing: normal;
}

.cms-prices tbody tr:nth-child(even) td {
    background: #f7f8fb;
}

.service-cta,
.contact-quick {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    margin: 1rem 0 1.25rem;
}

.service-cta .btn,
.contact-quick .btn,
.btn-submit-block {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.service-cta .btn-solid-default {
    background-color: var(--theme-color, #e22454);
    color: #fff;
    border-color: var(--theme-color, #e22454);
    z-index: 1;
}

.service-price-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem 1.25rem;
    margin: 0.35rem 0 1.5rem;
}

.service-index-list {
    list-style: none;
    padding-left: 0;
    margin: 1.25rem 0 0;
}

.service-index-list li {
    display: list-item;
    margin: 0.4rem 0;
}

.service-index-list a {
    color: var(--theme-color, #465bd0);
}

.popular-image.is-current h5 {
    color: var(--theme-color, #465bd0);
    font-weight: 600;
}

@media (min-width: 1200px) {
    header .main-navbar .nav-menu > li .mega-menu-container.poster-bg-image {
        background-position: 78% center;
        background-repeat: no-repeat;
        background-size: cover;
        padding: 1.5rem 42% 1.35rem 1rem;
    }

    header .main-navbar .nav-menu > li .mega-menu-container .mega-menu-columns {
        width: 100%;
        max-width: none;
        margin-left: 0;
        margin-right: 0;
        --bs-gutter-x: 0.75rem;
    }

    header .main-navbar .nav-menu > li .mega-menu-container .mega-box {
        flex: 1 1 0;
        width: auto;
        max-width: none;
        min-width: 0;
        overflow: hidden;
        padding-right: 0.65rem;
    }

    header .main-navbar .nav-menu > li .mega-menu-container .mega-box .link-section .submenu-content.opensubmegamenu {
        padding: 0 0.35rem 0 0;
    }
}

header .main-navbar .nav-menu > li .mega-menu-container .mega-box .link-section .submenu-title h5 {
    letter-spacing: normal;
}

header .main-navbar .nav-menu > li .mega-menu-container .mega-box .link-section .submenu-content ul li a.mega-menu-link {
    white-space: normal;
    overflow-wrap: anywhere;
    word-break: break-word;
    letter-spacing: normal;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    overflow: hidden;
    max-width: 100%;
    padding-right: 0.25rem;
}

.mobile-utility {
    display: none;
}

.mobile-menu__call,
.mobile-menu a .fa {
    display: block;
    margin: 0 auto;
    font-size: 1.15rem;
    line-height: 24px;
    height: 24px;
}

.mobile-menu__call {
    color: var(--theme-color) !important;
    font-weight: 600;
}

@media (max-width: 1199px) {
    header.header-style-2 {
        position: sticky;
        top: 0;
        z-index: 1060;
        background: #fff;
        box-shadow: 0 1px 8px rgba(0, 0, 0, 0.08);
        padding-top: env(safe-area-inset-top, 0px);
    }

    header .main-menu {
        padding-top: 8px;
        padding-bottom: 8px;
        padding-left: env(safe-area-inset-left, 0px);
        padding-right: env(safe-area-inset-right, 0px);
    }

    .toggle-nav {
        display: inline-flex !important;
        align-items: center;
        justify-content: center;
        width: 44px;
        height: 44px;
        padding: 0;
        margin: 0;
        border: 0;
        background: transparent;
        color: #212529;
        font-size: 1.35rem;
        cursor: pointer;
        flex-shrink: 0;
    }

    .header-style-2 .main-menu nav {
        margin-left: auto;
        margin-right: 0.35rem;
    }

    header .main-navbar .nav-menu {
        z-index: 1075;
        padding-bottom: calc(72px + env(safe-area-inset-bottom, 0px));
    }

    header .category-dropdown {
        z-index: 1075;
        padding-bottom: calc(72px + env(safe-area-inset-bottom, 0px));
    }

    .mobile-utility {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 0.5rem;
        padding: 0.4rem 0.85rem;
        padding-left: calc(0.85rem + env(safe-area-inset-left, 0px));
        padding-right: calc(0.85rem + env(safe-area-inset-right, 0px));
        background: #111;
        color: #fff;
        font-size: 0.8rem;
        line-height: 1.2;
    }

    .mobile-utility a {
        color: #fff;
        text-decoration: none;
        font-weight: 600;
        white-space: nowrap;
    }

    .mobile-utility__hours {
        color: rgba(255, 255, 255, 0.82);
        min-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .mobile-utility__map {
        text-decoration: underline;
        text-underline-offset: 0.12em;
    }
}

@media (max-width: 991px) {
    .header-book {
        display: none;
    }

    .cookie-banner {
        bottom: calc(64px + env(safe-area-inset-bottom, 0px));
        padding: 0.8rem 1rem;
        padding-left: calc(1rem + env(safe-area-inset-left, 0px));
        padding-right: calc(1rem + env(safe-area-inset-right, 0px));
    }

    .cookie-banner__inner {
        flex-direction: column;
        align-items: stretch;
        gap: 0.75rem;
    }

    .cookie-banner__text {
        font-size: 0.9rem;
        line-height: 1.4;
    }

    .cookie-banner__actions {
        width: 100%;
    }

    .cookie-banner__actions .btn {
        flex: 1 1 auto;
        min-height: 44px;
    }

    .mobile-menu {
        z-index: 1070;
        padding-bottom: calc(8px + env(safe-area-inset-bottom, 0px));
        padding-left: env(safe-area-inset-left, 0px);
        padding-right: env(safe-area-inset-right, 0px);
    }

    .mobile-menu ul li a {
        min-height: 48px;
        padding: 4px 0;
        -webkit-tap-highlight-color: transparent;
    }

    footer.footer-sm-space {
        margin-bottom: calc(72px + env(safe-area-inset-bottom, 0px));
    }

    .location-map {
        min-height: 260px;
    }

    .btn-submit-block {
        width: 100%;
        min-height: 48px;
    }

    .service-cta .btn,
    .contact-quick .btn {
        flex: 1 1 140px;
    }

    .collection-banner .banner-text .banner-content,
    .banner-title .banner-text .banner-content {
        width: 100%;
        max-width: none;
        padding: 1rem;
    }

    .collection-banner::after,
    .collection-banner.p-right::after,
    .collection-banner.text-right::after {
        background: linear-gradient(180deg, rgba(8, 10, 14, 0.08) 22%, rgba(8, 10, 14, 0.72) 100%);
    }

    .collection-banner .banner-text {
        align-items: flex-end;
        background: none;
    }

    .collection-banner .banner-content h2,
    .collection-banner .banner-content h3 {
        color: #fff;
    }
}

@media (max-width: 575px) {
    header .main-navbar .nav-menu {
        width: 100% !important;
        max-width: 100% !important;
        right: -100%;
        left: auto;
    }

    header .category-dropdown {
        width: 100% !important;
        max-width: 100% !important;
        left: -100%;
    }

    header .brand-logo h2 {
        font-size: 1.25rem;
        white-space: nowrap;
    }

    .home-section.home-style-2 .home-slider,
    .home-style-2 .home-slider {
        height: 340px;
    }

    .home-style-2 .left-content::after {
        background: linear-gradient(180deg, rgba(8, 10, 14, 0.12) 18%, rgba(8, 10, 14, 0.7) 100%);
    }

    .home-style-2 .left-content .home-content {
        align-items: flex-end;
        padding: 1rem 1rem 1.15rem;
        position: relative;
        z-index: 1;
    }

    .home-style-2 .left-content .home-content h1 {
        font-size: 1.2rem !important;
        line-height: 1.2 !important;
        margin-bottom: 0.35rem;
        max-width: 20em;
        color: #fff;
    }

    .form-control,
    .form-select,
    .custome-form-select {
        min-height: 44px;
        font-size: 16px;
    }

    .form-check-input {
        width: 1.2rem;
        height: 1.2rem;
        margin-top: 0.2rem;
    }

    .collection-banner .banner-content h2 {
        font-size: 1.15rem;
        line-height: 1.3;
    }

    .brand-logo h2 {
        font-size: 1.35rem;
    }

    header .brand-logo h2 {
        font-size: 1.25rem;
    }

    .cms-content,
    .cms-content--wide {
        max-width: 100%;
        overflow-wrap: anywhere;
    }

    .cms-content table,
    .cms-content .cms-table,
    .cms-prices table {
        font-size: 0.85rem;
    }

    .blog-detail-contain .card-title.fs-1 {
        font-size: 1.55rem !important;
        line-height: 1.25;
    }
}

@media (max-width: 400px) {
    .mobile-utility {
        flex-wrap: wrap;
        row-gap: 0.2rem;
    }

    .mobile-utility__hours {
        display: block;
        flex: 1 1 100%;
        order: 3;
        text-align: center;
        font-size: 0.75rem;
        overflow: visible;
        text-overflow: unset;
    }
}
