.footer-middle {
    padding-top: 2.25rem;
    padding-bottom: 2.25rem;
}
.text-right{
    text-align: right;
}
.pt-90 {
    padding-top: 90px !important;
}

/* Мобилка/узкие экраны: фиксированный хедер выше из-за строки поиска */
@media (max-width: 991.98px) {
    .pt-90 {
        padding-top: 140px !important;
    }
}

/* Fix breadcrumb divider showing template demo URL */
:root {
    --bs-breadcrumb-divider: "/";
}

/* Уведомления (alert): читаемый размер текста на цветном фоне */
.alert {
    font-size: 20px;
}
.alert .alert-link {
    font-size: inherit;
}
.alert-success .alert-link {
    color: rgba(255, 255, 255, 1);
    text-decoration: underline;
}
.alert-success .alert-link:hover {
    color: rgba(255, 255, 255, 1);
}

/* Десктоп: отступ под шапку с двумя рядами (меню + строка поиска), чтобы контент не наезжал на поиск */
@media (min-width: 992px) {
    .pt-90 {
        padding-top: 145px !important;
    }
}

/* Высота главного слайдера и видео на всю ширину экрана */
.slideshow {
    height: 35rem !important;
    overflow-x: hidden;
}
/* Мобилка: слайдер не выше 50% экрана */
@media (max-width: 767.98px) {
    .slideshow {
        height: 50vh !important;
        max-height: 50vh;
    }
    .slideshow .swiper-container,
    .slideshow .swiper-wrapper,
    .slideshow .swiper-slide {
        height: 100% !important;
    }
}
@media (min-width: 992px) {
    .slideshow {
        height: 35rem !important;
    }
}
.slideshow #video-bg {
    width: 100vw !important;
    max-width: none;
    left: 50% !important;
    transform: translateX(-50%);
}
.slideshow #myVideo {
    width: 100% !important;
    min-width: 100% !important;
    object-fit: cover;
}
.my-account__address-list {
    display: flex;
    gap: 1.625rem;
}

.form-floating>.form-control,
.form-floating>.form-select {
    height: 48px;
}

/* На мобильной версии магазина кнопка «В корзину» всегда видна (без hover) */
@media (max-width: 991.98px) {
    .shop-main .product-card .pc__atc.anim_appear-bottom,
    .shop-main .product-card .pc__img-wrapper .pc__atc {
        opacity: 1;
        visibility: visible;
        bottom: 0.625rem;
    }
}

/* Десктоп: строка поиска на всю ширину контейнера (как .container), симметричные отступы */
@media (min-width: 992px) {
    .header-desk__search-bar {
        --header-search-gutter: var(--bs-gutter-x, 0.9375rem);
        width: calc(100% + 2 * var(--header-search-gutter));
        margin-left: calc(-1 * var(--header-search-gutter));
        margin-right: calc(-1 * var(--header-search-gutter));
        padding: 0.625rem var(--header-search-gutter) 0.875rem;
        border-top: 1px solid rgba(0, 0, 0, 0.12);
        background-color: #f5f5f5;
        border-radius: 0 0 0.25rem 0.25rem;
    }
    .header-desk__search-bar .search-field {
        width: 100%;
    }
    .header-desk__search-bar .search-field > div.position-relative {
        width: 100%;
    }
    .header-desk__search-bar .search-field__input {
        width: 100%;
        max-width: none;
        padding: 0.625rem 3rem 0.625rem 1rem;
        font-size: 1rem;
        background-color: #fff;
        border: 1px solid rgba(0, 0, 0, 0.15);
        box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    }
    .header-desk__search-bar .search-field__input::placeholder {
        color: #495057;
    }
    .header.header-transparent-bg:not(.header_sticky-active) .header-desk__search-bar {
        border-top-color: rgba(255, 255, 255, 0.25);
        background-color: rgba(255, 255, 255, 0.95);
    }
    .header.header-transparent-bg:not(.header_sticky-active) .header-desk__search-bar .search-field__input {
        background: #fff;
        border-color: rgba(0, 0, 0, 0.12);
        color: #212529;
    }
    .header.header-transparent-bg:not(.header_sticky-active) .header-desk__search-bar .search-field__input::placeholder {
        color: #6c757d;
    }
}

/* Сайдбар магазина: те же горизонтальные отступы, что и у строки поиска */
@media (min-width: 992px) {
    #shopFilter,
    .shop-sidebar.side-sticky {
        padding-left: 0.75rem;
        padding-right: 0.75rem;
    }
}

/* Мобильный хедер: строка поиска сразу под главным меню, всегда видна */
@media (max-width: 991.98px) {
    .header-mobile {
        display: flex;
        flex-direction: column;
        height: auto;
        min-height: 3.75rem;
    }
    .header-mobile .container.d-flex.align-items-center.h-100 {
        flex: 0 0 auto;
        min-height: 3.75rem;
    }
    .header-mobile__search-bar {
        flex: 0 0 auto;
        padding: 0.5rem 0.75rem 0.75rem;
        border-top: 1px solid rgba(0, 0, 0, 0.08);
        background-color: #fff;
    }
    .header-mobile__search-bar .search-field__input {
        padding: 0.5rem 2.5rem 0.5rem 0.75rem;
        font-size: 1rem;
    }
    .header-mobile_sticky .header-mobile__navigation {
        top: 100%;
    }
}

/* Уведомления: колокольчик «Заказы ждут подтверждения» */
.header-tools__notif {
    position: relative;
}
.header-tools__notif .header-tools__notif-icon {
    animation: header-notif-blink 1.5s ease-in-out infinite;
}
@keyframes header-notif-blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}
.header-tools__notif .header-tools__notif-badge {
    position: absolute;
    top: calc(0.25rem + 1em);
    left: calc(0.5rem + 1.4em);
    min-width: 1rem;
    height: 1rem;
    padding: 0 0.25rem;
    border-radius: 100%;
    background: #b9a16b;
    color: #fff;
    font-size: 0.625rem;
    line-height: 1rem;
    text-align: center;
}

/* Избранное: бейдж с количеством как у корзины */
.header-tools__wishlist {
    position: relative;
}
.header-tools__wishlist .wishlist-amount {
    top: calc(0.25rem + 1em);
    left: calc(0.5rem + 1.4em);
    width: 1rem;
    height: 1rem;
    border-radius: 100%;
    background: #b9a16b;
    color: #ffffff;
    font-size: 0.625rem;
    line-height: 1rem;
    text-align: center;
}

/* Сердечко «В избранном» — полностью залито красным, без обводки */
.pc__btn-wl.active .pc__btn-wl-icon,
.pc__btn-wl.active svg,
.pc__btn-wl.active .heart-fill,
path.heart-fill {
    fill: #d6001c !important;
    stroke: none !important;
}
.pc__btn-wl.active {
    color: #d6001c !important;
}

/* Карточка товара в магазине: блок под фото всегда виден (не только по hover) */
.pc__img-wrapper .anim_appear-bottom {
    bottom: 0.625rem !important;
    opacity: 1 !important;
    visibility: visible !important;
}

/* Карточка товара в магазине: блок «В корзину» вынесен под изображение (после .pc__img-wrapper) */
.product-card .pc__atc-form_with-qty {
    width: 100%;
    margin: 0;
    overflow: visible;
}
.product-card .pc__atc-form_with-qty .pc__atc-with-qty {
    overflow: visible;
    position: relative;
    z-index: 3;
    left: 0;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    min-height: 2.75rem;
    padding-left: 0.75rem;
    padding-right: 12px;
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
    white-space: nowrap;
    gap: 0.75rem;
    box-sizing: border-box;
}
/* Резерв под иконку корзины с количеством (иконка увеличена на 50%) */
.product-card .pc__atc-form_in-cart .pc__atc-with-qty {
    padding-right: 2.5rem;
}
.product-card .pc__atc-form_with-qty .pc__atc-btn-text {
    flex: 1 1 0;
    min-width: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    background: transparent !important;
    color: inherit;
    text-align: center;
    padding: 0 0.5rem;
    font-size: inherit;
    overflow: hidden;
    text-overflow: ellipsis;
}
.product-card .pc__atc-form_with-qty .pc__atc-btn-text:hover {
    background: transparent !important;
    filter: brightness(0.95);
}
.product-card .pc__atc-form_with-qty .pc__atc-btn-text_in-cart {
    color: #0d6b0d;
    font-weight: 600;
}
.product-card .pc__atc-form_with-qty .qty-control {
    flex-shrink: 0;
    min-width: 5.5rem;
    height: 2rem;
}
.product-card .pc__atc-form_with-qty .qty-control__number {
    width: 100%;
    padding: 0.25rem 2rem;
    font-size: 0.875rem;
    text-align: center;
    box-sizing: border-box;
}
.product-card .pc__atc-form_with-qty .qty-control__reduce,
.product-card .pc__atc-form_with-qty .qty-control__increase {
    width: 1.75rem;
    min-width: 1.75rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1rem;
    text-align: center;
    line-height: 1;
}
.product-card .pc__atc-form_with-qty .qty-control__reduce {
    left: 0;
}
.product-card .pc__atc-form_with-qty .qty-control__increase {
    right: 0;
}
/* Иконка корзины на прежнем месте, треугольник с количеством заезжает на фото */
.product-card .pc__atc-cart-badge {
    position: absolute;
    top: 50%;
    right: 0.5rem;
    transform: translateY(-50%);
    display: inline-flex;
    flex-shrink: 0;
    width: 2.25rem;
    height: 2.25rem;
    align-items: center;
    justify-content: center;
    z-index: 2;
}
.product-card .pc__atc-cart-badge__icon {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    color: #000;
    display: block;
}
/* Бейдж — форма «домик» перевёрнутая на 180° (плоский верх, остриё вниз), полностью красная */
.product-card .pc__atc-cart-badge__qty {
    position: absolute;
    left: 50%;
    top: calc(-0.6rem - 20px);
    transform: translateX(-50%);
    width: 2.47rem;
    height: 2.35rem;
    padding: 0.5rem 0.75rem 1rem;
    box-sizing: border-box;
    clip-path: polygon(0% 0%, 100% 0%, 100% 58%, 50% 100%, 0% 58%);
    background-color: #d6001c;
    color: #fff;
    font-size: 0.875rem;
    font-weight: 600;
    line-height: 1.2;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 1;
}
.product-card .pc__atc-cart-badge__num {
    display: block;
    line-height: 1.1;
}
.product-card .pc__atc-cart-badge__unit {
    display: block;
    font-size: 0.6em;
    line-height: 1.1;
    margin-top: 0.1rem;
}
@media (min-width: 768px) {
    .product-card .pc__atc-cart-badge__qty {
        font-size: 1rem;
        width: 2.72rem;
        height: 2.5rem;
        padding: 0.55rem 0.85rem 1.1rem;
    }
    .product-card .pc__atc-cart-badge__unit {
        margin-top: 0.15rem;
    }
}
@media (max-width: 767.98px) {
    .product-card .pc__atc-form_with-qty .pc__atc-with-qty {
        padding: 0.5rem 0.625rem;
        font-size: 0.75rem;
        min-height: 2.5rem;
    }
    .product-card .pc__atc-form_with-qty .qty-control {
        min-width: 4.75rem;
        height: 1.75rem;
    }
    .product-card .pc__atc-form_with-qty .qty-control__number {
        padding: 0.2rem 1.5rem;
    }
    .product-card .pc__atc-form_with-qty .qty-control__reduce,
    .product-card .pc__atc-form_with-qty .qty-control__increase {
        width: 1.5rem;
        min-width: 1.5rem;
    }
}

/* Карточки товаров на главной (Горячие предложения, Рекомендуемые) — те же стили, что в каталоге */
main .hot-deals .product-card .pc__img-wrapper,
main .products-grid.container .product-card .pc__img-wrapper {
    aspect-ratio: 330/400;
    overflow: hidden;
}
main .hot-deals .product-card .pc__img-wrapper .pc__img,
main .products-grid.container .product-card .pc__img-wrapper .pc__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
main .hot-deals .pc__btn-wl_shop .pc__btn-wl-icon,
main .products-grid.container .pc__btn-wl_shop .pc__btn-wl-icon {
    display: block;
    color: #767676;
}
main .hot-deals .pc__btn-wl_shop.pc__btn-wl_filled .pc__btn-wl-icon,
main .products-grid.container .pc__btn-wl_shop.pc__btn-wl_filled .pc__btn-wl-icon {
    color: #d6001c;
}
main .hot-deals .js-wishlist-cell,
main .products-grid.container .js-wishlist-cell {
    min-width: 24px;
    min-height: 24px;
}
main .hot-deals .product-card__price .price-old,
main .products-grid.container .product-card__price .price-old {
    margin-right: 0;
    margin-left: 0.625rem;
}
main .hot-deals .pc__atc-form_in-cart .pc__atc,
main .products-grid.container .pc__atc-form_in-cart .pc__atc {
    width: 100%;
}
main .hot-deals .pc__atc-form_in-cart .pc__atc-btn-text,
main .products-grid.container .pc__atc-form_in-cart .pc__atc-btn-text {
    display: none !important;
}
main .hot-deals .pc__atc-form:not(.pc__atc-form_in-cart) .pc__atc,
main .products-grid.container .pc__atc-form:not(.pc__atc-form_in-cart) .pc__atc {
    width: 100%;
}
main .hot-deals .pc__atc-form:not(.pc__atc-form_in-cart) .pc__atc-btn-text,
main .products-grid.container .pc__atc-form:not(.pc__atc-form_in-cart) .pc__atc-btn-text {
    height: 2.25rem;
    border: 1px solid #e4e4e4;
    border-radius: 0.25rem;
    background: #fff;
    color: #222;
    padding: 0 0.75rem;
    min-width: 0;
}
main .hot-deals .pc__atc-form:not(.pc__atc-form_in-cart) .pc__atc-btn-text:hover,
main .products-grid.container .pc__atc-form:not(.pc__atc-form_in-cart) .pc__atc-btn-text:hover {
    background: #f5f5f5;
    border-color: #ddd;
}
main .hot-deals .pc__qty,
main .products-grid.container .pc__qty {
    display: flex;
    order: -1;
    flex: 1;
    min-width: 0;
    margin-right: 0.5rem;
    border: 1px solid #e4e4e4;
    border-radius: 0.25rem;
    background: #fff;
}
main .hot-deals .pc__qty-btn,
main .products-grid.container .pc__qty-btn {
    width: 2.25rem;
    height: 2.25rem;
    flex-shrink: 0;
    border: 0;
    background: 0;
    font-size: 1.1rem;
    color: #222;
    cursor: pointer;
    line-height: 1;
    padding: 0;
}
main .hot-deals .pc__qty-minus,
main .products-grid.container .pc__qty-minus {
    border-right: 1px solid #e4e4e4;
    border-radius: 0.2rem 0 0 0.2rem;
}
main .hot-deals .pc__qty-input,
main .products-grid.container .pc__qty-input {
    flex: 1;
    min-width: 2rem;
    height: 2.25rem;
    border: 0;
    border-right: 1px solid #e4e4e4;
    padding: 0 0.25rem;
    font-weight: 600;
    text-align: center;
    -moz-appearance: textfield;
}
main .hot-deals .pc__qty-input::-webkit-outer-spin-button,
main .hot-deals .pc__qty-input::-webkit-inner-spin-button,
main .products-grid.container .pc__qty-input::-webkit-outer-spin-button,
main .products-grid.container .pc__qty-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}
main .hot-deals .pc__qty-plus,
main .products-grid.container .pc__qty-plus {
    border-radius: 0 0.2rem 0.2rem 0;
}

/* Горячие предложения: левая колонка (обратный отсчёт) поверх правой (товары), чтобы не залазила под карусель */
.hot-deals .row > .col-md-6.col-lg-4.col-xl-20per {
    position: relative;
    z-index: 2;
    min-width: 0; /* позволить колонке сжиматься по ширине row */
    overflow: hidden;
}
.hot-deals .row > .col-md-6.col-lg-8.col-xl-80per {
    position: relative;
    z-index: 1;
}

/* Обратный отсчёт не выходит за границы левой колонки: перенос на следующую строку при нехватке места */
.hot-deals .col-xl-20per .js-countdown,
.hot-deals .col-lg-4 .js-countdown {
    max-width: 100%;
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem 0.5rem;
    justify-content: flex-start;
    align-items: center;
}
.hot-deals .col-xl-20per .js-countdown .countdown-unit,
.hot-deals .col-lg-4 .js-countdown .countdown-unit {
    flex: 0 0 auto;
}
@media (max-width: 1199.98px) {
    .hot-deals .js-countdown .countdown-unit {
        font-size: 0.95rem;
        padding-right: 0.5rem;
    }
    .hot-deals .js-countdown .countdown-word {
        font-size: 0.75rem;
    }
}
@media (max-width: 991.98px) {
    .hot-deals .js-countdown .countdown-unit {
        font-size: 0.875rem;
        padding-right: 0.4rem;
    }
    .hot-deals .js-countdown .countdown-word {
        font-size: 0.7rem;
    }
}

/* Блок «То что Вам нужно» — карусель категорий: единая высота слайдов, обрезка названий */
.category-carousel__slide {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 200px;
}
.category-carousel__img-wrap,
.category-carousel__placeholder {
    flex-shrink: 0;
    width: 124px;
    height: 124px;
    margin-left: auto;
    margin-right: auto;
}
.category-carousel__img-wrap img {
    width: 124px;
    height: 124px;
    object-fit: cover;
    display: block;
}
.category-carousel__placeholder {
    line-height: 124px;
}
.category-carousel__title {
    max-width: 100%;
    word-wrap: break-word;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.category-carousel__children {
    line-height: 1.4;
}
.category-carousel__children a:hover {
    text-decoration: underline !important;
}
@media (max-width: 767.98px) {
    .category-carousel__slide {
        min-height: 180px;
    }
}

/* Избранное: ссылка «В корзине» в одном стиле, hover */
.wishlist-cart-link {
    transition: color 0.2s ease;
}
.wishlist-cart-link:hover {
    color: var(--bs-primary, #222) !important;
}
.wishlist-cart-link:hover .text-dark {
    color: var(--bs-primary, #222) !important;
}

/* Корзина: таблица пошире, цена и сумма в одну строку */
@media (min-width: 992px) {
    .shopping-cart .cart-table__wrapper {
        flex: 1 1 68%;
        min-width: 0;
    }
    .shopping-cart__totals-wrapper {
        flex: 0 0 auto;
    }
    .shopping-cart .cart-table {
        min-width: 36rem;
    }
    .shopping-cart .cart-table tbody td:nth-child(3) .shopping-cart__product-price,
    .shopping-cart .cart-table tbody td:nth-child(5) .shopping-cart__subtotal {
        white-space: nowrap;
    }
    .shopping-cart .cart-table th:nth-child(3),
    .shopping-cart .cart-table td:nth-child(3) {
        white-space: nowrap;
        width: 1%;
    }
    .shopping-cart .cart-table th:nth-child(5),
    .shopping-cart .cart-table td:nth-child(5) {
        white-space: nowrap;
        width: 1%;
    }
}

/* Cookie banner (Ozon-style) */
.cookie-banner {
    position: fixed;
    bottom: 1.5rem;
    left: 1.5rem;
    right: 1.5rem;
    max-width: 420px;
    z-index: 9999;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.12);
    padding: 1.25rem 1.5rem;
    transform: translateY(calc(100% + 2rem));
    opacity: 0;
    visibility: hidden;
    transition: transform 0.3s ease, opacity 0.3s ease, visibility 0.3s ease;
}
.cookie-banner.cookie-banner--visible {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
}
.cookie-banner__inner {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}
.cookie-banner__title {
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
    line-height: 1.3;
}
.cookie-banner__text {
    font-size: 0.875rem;
    color: #555;
    line-height: 1.5;
    margin: 0;
}
.cookie-banner__text p {
    margin: 0 0 0.35em;
}
.cookie-banner__text p:last-child {
    margin-bottom: 0;
}
.cookie-banner__text a {
    color: var(--bs-primary, #0d6efd);
    text-decoration: underline;
}
.cookie-banner__text a:hover {
    text-decoration: none;
}
.cookie-banner__btn {
    align-self: flex-start;
    padding: 0.5rem 1.25rem;
    font-size: 0.9rem;
    font-weight: 500;
}
@media (min-width: 576px) {
    .cookie-banner {
        left: auto;
        right: 1.5rem;
        bottom: 1.5rem;
    }
}

/* Режим обслуживания — заглушка поверх всего сайта */
.maintenance-overlay {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.85);
    padding: 1.5rem;
}
.maintenance-overlay__box {
    max-width: 480px;
    background: #fff;
    border-radius: 12px;
    padding: 2rem;
    text-align: center;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}
.maintenance-overlay__icon {
    font-size: 3rem;
    color: #f0ad4e;
    margin-bottom: 1rem;
}
.maintenance-overlay__title {
    font-size: 1.35rem;
    font-weight: 600;
    margin: 0 0 0.75rem;
}
.maintenance-overlay__message {
    font-size: 1rem;
    line-height: 1.5;
    margin: 0;
    color: #444;
    white-space: pre-line;
}