/* Основные стили */
html, body {
    touch-action: manipulation;
}

body {
    background-color: #F4F7F9;
    font-family: 'Inter', sans-serif;
    color: #2F2F2F;
    line-height: 1.6;
}

h1, h2, h3, h4, h5 {
    font-family: 'Playfair Display', serif;
    color: #2F2F2F;
    margin-bottom: 1rem;
}

.h1header {
  max-width: 720px;
  width: 100%;
  position: relative;
  display: inline-block;
  color: #465457;
}

.product_detail {
  color: #5C7F8B !important;
}

.divheader {
  padding-bottom: 50px;
  text-align: center;
}

a {
    color: #5C7F8B;
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: #3b5e68;
}

/* Хедер */
.header-container {
    display: flex;
    width: 100%;
    align-items: center;
}

.search-container {
    flex: 0 1 auto;
    margin-left: auto;
    margin-right: auto;
    max-width: 400px;
}

.top-menu-left {
    margin-right: auto;
}

.top-menu-right {
    margin-left: auto;
}

/* Логотип */
.logo-container {
    height: 100%;
    display: flex;
    align-items: flex-start;
    padding-top: 5px;
    margin-left: 0px;
}

.logo-img {
    height: 100px;
    max-width: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.logo-img:hover {
    transform: scale(1.05);
}

/* Верхняя часть хедера */
.top-header {
    border-bottom: 1px solid #f0f0f0;
    padding: 5px 0 0px 0;
    position: relative;
}

/* Верхнее меню */
.top-menu-left, .top-menu-right {
    padding-top: 10px;
}

.top-menu-left {
    margin-left: 0px;
}

.top-nav {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.top-nav-link {
    color: #333;
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: 500;
    transition: color 0.3s;
    white-space: nowrap;
    padding: 5px 0;
    position: relative;
}

.top-nav-link:after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: #d63384;
    transition: width 0.3s;
}

.top-nav-link:hover:after {
    width: 100%;
}

/* Иконки */
.icon-links {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-right: 25px;
}

.icon-img {
    width: 28px;
    height: 28px;
    transition: transform 0.3s;
}

.icon-link {
    display: flex;
    align-items: center;
    gap: 0px;
    text-decoration: none;
    color: #333;
    font-size: 1rem;
}

.icon-link:hover .icon-img {
    transform: scale(1.1);
}

.icon-text {
    white-space: nowrap;
}

/* Личный кабинет */
.account-links {
    display: flex;
    gap: 10px;
}

.account-link {
    color: #333;
    text-decoration: none;
    font-size: 1rem;
    white-space: nowrap;
    transition: color 0.3s;
    font-weight: 500;
}

.account-link:hover {
    color: #d63384;
}

.logout-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    font-weight: 500;
}

/* Меню категорий */
.category-menu {
    background-color: #fff;
    border-bottom: 1px solid #f0f0f0;
    margin-top: -60px;
    padding: 5px 0;
}

.category-nav {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 25px;
    padding: 12px 0;
}

.category-link {
    color: #333;
    text-decoration: none;
    font-weight: 500;
    padding: 5px 0;
    position: relative;
    white-space: nowrap;
    font-size: 1rem;
}

.category-link:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: #d63384;
    transition: width 0.3s;
}

.category-link:hover:after {
    width: 100%;
}

/* ========== ДЕСКТОПНАЯ ВЕРСИЯ ========== */
/* Поиск на десктопе */
.search-form {
    transition: all 0.3s ease;
}

.search-input {
    border-radius: 25px;
    padding: 8px 15px;
    border: 2px solid #5C7F8B;
    width: 300px;
}

/* Мобильный правый блок: поиск + корзина + гамбургер */
.mobile-header-right {
    display: none;
    position: fixed;
    top: 15px;
    right: 15px;
    z-index: 1001;
    gap: 15px;
    align-items: center;
}

/* Иконки на мобильных */
.mobile-search-icon,
.mobile-cart-icon {
    display: none;
}

/* ========== МОБИЛЬНАЯ ВЕРСИЯ ========== */
@media (max-width: 1300px) {
    /* Скрываем десктопные элементы */
    .top-menu-left.d-md-block,
    .top-menu-right.d-md-block,
    .desktop-cart {
        display: none !important;
    }

    /* Показываем мобильные элементы */
    .mobile-header-right {
        display: flex !important;
        top: 25px;
        right: 20px;
    }

    .mobile-search-icon,
    .mobile-cart-icon {
        display: block !important;
    }

    /* Мобильная версия поиска */
    .search-form {
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
        top: 60px;
        width: 90%;
        max-width: 400px;
        z-index: 1000;
        background: white;
        padding: 5px;
        border-radius: 25px;
        box-shadow: 0 2px 10px rgba(0,0,0,0.1);
        display: none; /* Скрыта по умолчанию */
    }

    .search-form.mobile-active {
        display: block !important;
        animation: slideDown 0.3s ease;
    }

    .mobile-menu-toggle {
        display: flex !important;
        flex-direction: column;
        gap: 5px;
        background: none;
        border: none;
        padding: 5px;
        cursor: pointer;
        z-index: 1001;
        position: static;
    }

    .burger-line {
        width: 26px;
        height: 3px;
        background: #333;
        border-radius: 2px;
        transition: transform .3s, opacity .3s;
    }

    /* Центрируем логотип */
    .logo-container {
        margin: 0 auto;
        padding-top: 10px;
    }

    .logo-img {
        height: 110px;
    }

    /* Скрываем иконку поиска в основном потоке */
    .icon-links .search-icon {
        display: none;
    }



    .search-input {
        width: 100%;
        border-radius: 25px;
        padding: 10px 20px;
        border: 2px solid #5C7F8B;
    }
}

/* Мобильное меню */
.mobile-menu {
    position: fixed;
    top: 45px;
    right: -100%;
    width: 80%;
    max-width: 300px;
    height: 250px;
    background: #fff;
    box-shadow: -2px 0 10px rgba(0,0,0,0.2);
    transition: right 0.3s ease;
    z-index: 2050;
    padding: 60px 20px 20px;
    overflow-y: auto;
    pointer-events: auto !important;
}

.mobile-menu.active {
    right: 0;
}

@media (max-width: 1300px) {
    .mobile-menu.active {
        right: 0;
        display: flex;
        flex-direction: row;
        justify-content: space-between;
        align-items: flex-start;
        padding: 0;
        margin: 0;
    }

    .top-menu-left,
    .top-menu-right {
        width: 50%;
    }

    .top-menu-left {
        display: flex;
        justify-content: flex-start;
        align-items: flex-start;
        padding: 0;
        margin: 0;
        margin-left: 10px;
    }

    .top-nav {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        padding: 0;
        margin: 0;
    }

    .top-nav-link {
        text-align: left;
        margin-left: 0;
        padding-left: 0;
    }

    .top-menu-right {
        display: flex;
        flex-direction: column;
        align-items: flex-end;
        padding: 0;
        margin: 0;
    }

    .icon-img {
        width: 20px;
        margin-right: 8px;
    }

    .icon-links,
    .account-links {
        display: flex;
        flex-direction: column;
        gap: 10px;
        align-items: flex-end;
        margin-right: 10px;
    }

    .logout-btn {
        background: none;
        border: none;
        padding: 0;
        color: #000;
        text-align: right;
    }

    /* Убираем корзину из мобильного меню */
    .mobile-menu .icon-links a[href*="view_cart"],
    .mobile-menu .desktop-cart {
        display: none !important;
    }

    /* ПОКАЗЫВАЕМ иконку поиска в мобильном хедере */
    .mobile-header-right .search-icon {
        display: flex !important;
    }

    /* Скрываем иконку поиска в основном потоке */
    .header-container .icon-links .search-icon {
        display: none;
    }
}

/* Оверлей */
.menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 2040;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
}

.menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Блокировка скролла */
body.menu-open {
    overflow: hidden;
}

/* Кнопка закрытия */
.close-menu-btn {
    position: fixed;
    top: 10px;
    right: 20px;
    width: 40px;
    height: 40px;
    background: rgba(255,255,255,0.9);
    border: none;
    border-radius: 50%;
    font-size: 30px;
    line-height: 40px;
    cursor: pointer;
    z-index: 1100;
    color: #333;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.close-menu-btn:hover {
    color: #d63384;
}

/* Бейдж корзины */
.cart-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background-color: #dc3545;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: bold;
}

/* Анимация для поиска */
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

/* Адаптивность для разных размеров мобильных */
@media (max-width: 992px) {
    .category-menu {
        margin-top: -30px;
    }

    .logo-img {
        height: 100px;
    }

    .search-form {
        top: 55px;
    }
}

@media (max-width: 768px) {
    .category-menu {
        margin-top: -10px;
    }

    .logo-img {
        height: 90px;
        margin-right: 15px;
    }

    .search-form {
        top: 50px;
        width: 85%;
    }

    .mobile-header-right {
        top: 20px;
        right: 15px;
        gap: 12px;
    }
}

@media (max-width: 576px) {
    .logo-img {
        height: 80px;
        margin-right: 10px;
    }

    .search-form {
        top: 45px;
        width: 80%;
    }

    .mobile-header-right {
        top: 18px;
        right: 10px;
        gap: 10px;
    }
}

@media (max-width: 400px) {
    .logo-img {
        height: 70px;
    }

    .search-form {
        top: 40px;
    }
}

/* Дополнительные стили */
.bg-footer, .bg-header {
    background-color: #5C7F8B;
    color: white;
}

.container {
    max-width: 1400px;
}

.card-header {
    background-color: #5C7F8B;
    color: white;
}


/* Категории */
.category-badge {
    background-color: #f0f4f7;
    color: #3B4C55;
    border: 1px solid #d0d9e0;
    border-radius: 16px;
    padding: 0.3rem 0.8rem;
    font-size: 0.8rem;
    margin: 0.2rem;
}

.category-badge:hover {
    background-color: #5C7F8B;
    color: white;
    border-color: #5C7F8B;
}


/* Кнопки */
.btn-main, .btn-primary {
    background-color: #5C7F8B !important;
    color: #fff;
    border-radius: 12px;
    border: none;
    padding: 0.5rem 1.5rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-main:hover, .btn-primary:hover {
    background-color: #4a6571;
    color: #fff;
    transform: translateY(-2px);
}

/* Для обычного состояния */
.btn-outline-primary {
    color: #5C7F8B;
    border-color: #5C7F8B;
    background-color: transparent;
}

/* Для состояния при наведении */
.btn-outline-primary:hover {
    color: #fff;
    background-color: #5C7F8B;
    border-color: #5C7F8B;
}

/* Для активного состояния (когда кнопка нажата или имеет класс active) */
.btn-outline-primary:active,
.btn-outline-primary:focus,
.btn-outline-primary.active {
    color: #fff;
    background-color: #5C7F8B;

}

/* Адаптивность */
@media (max-width: 768px) {

    .btn-main, .btn-primary {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }
}




/* Уменьшение расстояний в нижнем меню категорий */
.category-nav .nav-link {
    font-size: 1rem;
    padding: 0.25rem 0.75rem;
}



/* Стили формы фильтрации */

.filter-form .form-select {
    border-radius: 0 8px 8px 0 !important;
    border-left: none;
    padding-left: 0.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    background-color: #fff;
    border-color: #d0d9e0;
}

.filter-form .input-group-text {
    border-radius: 8px 0 0 8px !important;
    border-right: none;
    background-color: #fff;
    color: #5C7F8B;
    border-color: #d0d9e0;
}

.filter-form select:hover,
.filter-form select:focus {
    border-color: #5C7F8B;
    box-shadow: 0 0 0 0.2rem rgba(92, 127, 139, 0.15);
}

.filter-form .btn-primary {
    background-color: #5C7F8B;
    border: none;
    border-radius: 8px;
    padding: 0.5rem 1rem;
    transition: all 0.3s ease;
    margin-top: 20px;
}

.filter-form .btn-primary:hover {
    background-color: #4a6b77;
    transform: translateY(-2px);
}

/* Стили пагинации */
.pagination .page-link {
    color: #5C7F8B;
    border: 1px solid #d0d9e0;
    margin: 0 4px;
    border-radius: 8px !important;
    min-width: 40px;
    text-align: center;
    transition: all 0.3s ease;
}

.pagination .page-item.active .page-link {
    background-color: #5C7F8B;
    border-color: #5C7F8B;
    color: white;
}

.pagination .page-link:hover {
    background-color: #f0f4f7;
    color: #3b5e68;
    border-color: #5C7F8B;
}

.pagination .page-item.disabled .page-link {
    color: #adb5bd;
}

@media (max-width: 768px) {
    .filter-form .col-md-3,
    .filter-form .col-md-2 {
        margin-bottom: 1rem;
    }

    .filter-form .btn-primary {
        width: 100%;
    }
}


/* Уменьшенный и центрированный контейнер */
.small-container {
    transform: scale(0.9);
    transform-origin: top center;
    width: 100%; /* Изменили с 125% */
    margin: 0 auto; /* Центрирование по горизонтали */
    padding: 0 10%; /* Добавляем боковые отступы */
    margin-bottom: -5%; /* Компенсация нижнего отступа */
    position: relative;
    left: 0;
    right: 0;
}

/* Уменьшенный и центрированный контейнер */
.constructor-small-container {
    transform: scale(0.9);
    transform-origin: top center;
    width: 100%; /* Изменили с 125% */
    margin: 0 auto; /* Центрирование по горизонтали */
    padding: 0 5%; /* Добавляем боковые отступы */
    margin-bottom: -5%; /* Компенсация нижнего отступа */
    position: relative;
    left: 0;
    right: 0;
}

/* Для адаптивности на мобильных */
@media (max-width: 768px) {
    .small-container {
        transform: scale(1);
        padding: 0 15px;
        margin-bottom: 0;
    }
}


/* Стили для баннера акций */
.promotion-banner {
    background: linear-gradient(135deg, #ff6b6b, #ff8e8e);
    color: white;
    padding: 2rem;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(255, 107, 107, 0.3);
    margin-bottom: 2rem;
}

.promotion-banner h1 {
    font-weight: 700;
    margin-bottom: 1rem;
}

.promotion-banner .lead {
    font-size: 1.25rem;
    opacity: 0.9;
}


/* Стили для акции на детальной странице */
.promotion-badge-detail {
    position: absolute;
    top: 20px;
    right: 20px;
    background: #e74c3c;
    color: white;
    padding: 8px 15px;
    border-radius: 6px;
    font-weight: bold;
    z-index: 2;
    transform: rotate(15deg);
    box-shadow: 0 3px 10px rgba(0,0,0,0.2);
    font-size: 1.1rem;
    animation: pulse 2s infinite;
}

.price-block {
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #5C7F8B;
}

.promotion-info {
    border-left: 4px solid #e74c3c;
}


.construction-container {
    background: linear-gradient(135deg, #f8f9fa, #f1f8e9);
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 2rem;
}

.construction-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 3rem;
    background: white;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(146, 204, 191, 0.2);
}

.construction-title {
    color: #3B4C55;
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    background: linear-gradient(to right, #5C7F8B, #8DB8A5);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.construction-text {
    color: #5C7F8B;
}

    /* Анимированный цветок с тремя лепестками */

.flower-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 2rem 0;
    height: 200px; /* Фиксированная высота для контейнера */
    margin-top: -60px;
    margin-left: 60px;
}


/* Обертка цветка с масштабированием */
.flower-wrapper {
    transform: scale(0.7);
    transform-origin: center;
    position: relative;
    width: fit-content;
    margin: 0 auto;
}

.flower {
    position: absolute;
    width: 100%;
    height: 100%;
    animation: rotateFlower 15s infinite linear;
}

.petals {
    position: relative;
    margin: 2em 8em;
}

.petals:before,
.petals:after,
.wrapper:after {
    position: absolute;
    content: "";
    display: block;
}

.petals,
.petals:before,
.petals:after {
    width: 5em;
    height: 5em;
    background: lightcyan;
    box-shadow: 0 0 0px 10px #5C7F8B inset;
    border-radius: 50% 50% 50% 0;
    animation: petal-breathe 3s infinite ease-in-out;
}

.petals:before {
    transform: rotate(-120deg);
    transform-origin: -1em 6em;
    animation-delay: 0.3s;
}

.petals:after {
    transform: rotate(120deg);
    transform-origin: -1em 6em;
    animation-delay: 0.6s;
}

.petals:nth-child(2) {
    position: absolute;
    top: 0;
    transform: rotate(180deg);
    transform-origin: -1em 5em;
    animation-delay: 0.9s;
}

.wrapper {
    position: relative;
    margin: 4em 2em;
}

.wrapper:after {
    top: 4em;
    left: 5em;
    width: 4em;
    height: 4em;
    border-radius: 50%;
    background: #3B4C55;
    box-shadow: 0 0 0px 10px #3B4C55 inset;
    animation: center-pulse 2s infinite alternate;
}

/* Анимация дыхания лепестков */
@keyframes petal-breathe {
    0%, 100% {
        transform: rotate(var(--current-rotation)) scale(1);
        opacity: 0.9;
    }
    50% {
        transform: rotate(var(--current-rotation)) scale(1.1);
        opacity: 1;
        box-shadow: 0 0 0 12px #5C7F8B inset;
    }
}

/* Анимация пульсации центра */
@keyframes center-pulse {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 10px #3B4C55 inset;
    }
    100% {
        transform: scale(1.05);
        box-shadow: 0 0 0 15px #3B4C55 inset;
    }
}

/* Устанавливаем текущий угол поворота для каждого лепестка */
.petals { --current-rotation: 0deg; }
.petals:before { --current-rotation: -120deg; }
.petals:after { --current-rotation: 120deg; }
.petals:nth-child(2) { --current-rotation: 180deg; }


/* Стили для бейджа корзины */
.cart-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background-color: #dc3545;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 600;
    border: 2px solid white;
    line-height: 1;
}

/* Для скрытия бейджа когда корзина пуста */
.cart-badge.d-none {
    display: none !important;
}

/* Адаптивность для мобильных */
@media (max-width: 768px) {
    .cart-badge {
        width: 18px;
        height: 18px;
        font-size: 0.65rem;
        top: -6px;
        right: -6px;
    }
}

#back-button-container {
    position: relative;
    top: 10px;
    left: 20px;
}

#back-button-container button {
    background: rgba(255, 255, 255, 0.95);
    border: 2px solid #5C7F8B;
    border-radius: 12px;
    padding: 8px 12px; /* Уменьшил padding для более аккуратного вида */
    display: flex;
    align-items: center;
    gap: 6px; /* Уменьшил gap */
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
    cursor: pointer;
    font-weight: 500;
    color: #5C7F8B;
    width: auto;
    height: auto;
    font-size: 0.9rem; /* Меньший размер текста */
}

#back-button-container button:hover {
    background: #5C7F8B;
    color: white;
    transform: translateY(-2px);
}

#back-button-container button i {
    color: #5C7F8B;
    font-size: 1.2rem; /* Уменьшил размер иконки */
    transition: color 0.3s ease;
}

#back-button-container button:hover i {
    color: white;
}

/* Адаптивность для мобильных устройств */
@media (max-width: 768px) {
    #back-button-container {
        top: 15px;
        left: 15px;
    }

    #back-button-container button {
        /* Квадратная кнопка только со стрелкой */
        width: 45px;
        height: 45px;
        padding: 0;
        border-radius: 12px;
        justify-content: center;
    }

    /* Скрываем текст "Назад" на мобильных */
    #back-button-container button .back-text {
        display: none;
    }

    #back-button-container button i {
        font-size: 1.3rem;
        margin: 0;
    }
}

@media (max-width: 576px) {
    #back-button-container {
        top: 12px;
        left: 12px;
    }

    #back-button-container button {
        width: 42px;
        height: 42px;
        border-width: 1.5px;
        border-radius: 10px;
    }

    #back-button-container button i {
        font-size: 1.2rem;
    }
}

@media (max-width: 400px) {
    #back-button-container {
        top: 10px;
        left: 10px;
    }

    #back-button-container button {
        width: 40px;
        height: 40px;
        border-radius: 8px;
    }
}

/* Убедимся, что контент не перекрывается кнопкой */
main {
    position: relative;
    z-index: 1;
}

.is-invalid {
    border-color: #dc3545;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' width='12' height='12' fill='none' stroke='%23dc3545'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath stroke-linejoin='round' d='M5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='%23dc3545' stroke='none'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right calc(0.375em + 0.1875rem) center;
    background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}

.is-invalid:focus {
    box-shadow: 0 0 0 0.25rem rgba(220, 53, 69, 0.25);
}

.invalid-feedback {
    width: 100%;
    margin-top: 0.25rem;
    font-size: 0.875em;
    color: #dc3545;
}

.progress-bar {
    background-color: #5C7F8B;
}

/* Стили для поля телефона */
.phone-input {
    font-family: monospace; /* Для равномерного отображения цифр */
}

.phone-input::placeholder {
    color: #ccc;
    opacity: 1;
}

.step {
    transition: opacity 0.3s ease;
}

.time-slots .form-check-input.is-invalid {
    border-color: #dc3545;
}

.was-validated .time-slots:invalid ~ .invalid-feedback {
    display: block;
}


/* Стили для блока ошибок */
#form-errors {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    min-width: 400px;
    box-shadow: 0 0 15px rgba(0,0,0,0.2);
    opacity: 0;
    transition: opacity 0.3s ease;
}

#form-errors.show {
    opacity: 1;
}

@media (max-width: 576px) {
    #form-errors {
        min-width: 90%;
    }
}

/* Фиксируем позицию блока с временными слотами */
.time-slots {
    position: relative;
    min-height: 150px; /* Чтобы не прыгала разметка при загрузке */
}

#time-slots-content {
    transition: opacity 0.3s ease;
}

/* Стили для кнопок навигации */
.step-navigation {
    display: flex;
    justify-content: space-between;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

/* Фиксируем позицию корзины */
.order-summary {
    position: sticky;
    top: 20px;
}

/* Стили для подсказок адресов */

#address-suggestions {
    width: 100%;
    max-width: 600px;
    max-height: 300px;
    overflow-y: auto;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

#address-suggestions a {
    display: block;
    padding: 8px 12px;
    color: #333;
    text-decoration: none;
}

#address-suggestions a:hover {
    background-color: #f8f9fa;
}

.btn-telegram {
    background-color: #0088cc;
    color: white;
    transition: all 0.3s;
}
.btn-telegram:hover {
    background-color: #0077b5;
    color: white;
}

/* Agreement */

.highlight {
            background-color: #f5e6ff;
            padding: 15px;
            border-left: 4px solid #9b59b6;
            margin: 20px 0;
        }

.container_agreement {
    background: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}


.about-page {
    font-size: 1.05rem;
    line-height: 1.6;
  }

  .about-page h1 {
    color: #2c3e50;

    margin-bottom: 1.5rem;
  }

  .about-page h2 {
    color: #3498db;
    font-weight: 500;
    margin-bottom: 1rem;
  }

  .about-page .card {
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 1.5rem;
  }

  .about-page .fw-bold {
    color: #2c3e50;
  }

/* Hero Section Styles */
.hero-section {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 20px;
    margin: 20px auto;
    max-width: 95%;
}

.hero-title {
    font-family: 'Playfair Display', serif;
    font-size: 3rem;
    font-weight: 700;
    color: #2F2F2F;
    line-height: 1.2;
}

.hero-subtitle {
    font-family: 'Inter', sans-serif;
    font-size: 1.5rem;
    color: #5C7F8B;
    font-weight: 400;
}

.hero-btn {
    background: linear-gradient(45deg, #5C7F8B, #3b5e68);
    border: none;
    border-radius: 50px;
    padding: 12px 40px;
    font-size: 1.2rem;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(92, 127, 139, 0.3);
}

.hero-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(92, 127, 139, 0.4);
    background: linear-gradient(45deg, #3b5e68, #5C7F8B);
}

/* Custom Order Card */
.custom-order-card {
    background: white;
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    border-left: 4px solid #5C7F8B;
    max-width: 600px;
    margin: 0 auto;
}

.custom-order-content {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
    justify-content: center;
}

.custom-order-icon {
    font-size: 2rem;
    color: #5C7F8B;
    flex-shrink: 0;
}

.custom-order-text {
    flex: 1;
    min-width: 250px;
    text-align: left;
}

.custom-order-text p {
    color: #2F2F2F;
    font-size: 0.95rem;
    line-height: 1.4;
    margin: 0;
}

.custom-order-btn {
    border-radius: 25px;
    padding: 8px 20px;
    font-weight: 500;
    border: 2px solid #5C7F8B;
    color: #5C7F8B;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.custom-order-btn:hover {
    background-color: #5C7F8B;
    color: white;
    transform: translateY(-1px);
}

/* Декоративные элементы для .d14 */
.d14 h1 {
    display: table;
    width: auto;
    margin: 0px auto;
    letter-spacing: 2px;
    position: relative;
    padding: 10px 40px;
}

.d14 h1:before {
    content: "";
    position: absolute;
    top: -30%;
    left: -25px;
    width: 30px;
    height: 20px;
    border-top: 4px solid #5C7F8B;
    border-left: 4px solid #5C7F8B;
}

.d14 h1:after {
    content: "";
    position: absolute;
    bottom: -30%;
    right: -25px;
    width: 30px;
    height: 20px;
    border-bottom: 4px solid #5C7F8B;
    border-right: 4px solid #5C7F8B;
}

/* Адаптивность для мобильных устройств */
@media (max-width: 768px) {
    .hero-section {
        padding: 30px 15px !important;
        margin: 10px auto;
        border-radius: 15px;
    }

    .hero-title {
        font-size: 2rem;
        padding: 8px 30px;
        margin-bottom: 15px !important;
    }

    .hero-subtitle {
        font-size: 1.1rem;
        margin-bottom: 20px !important;
    }

    .hero-btn {
        padding: 10px 30px;
        font-size: 1rem;
        margin-bottom: 20px !important;
    }

    .d14 h1:before {
        top: -20%;
        left: -15px;
        width: 20px;
        height: 15px;
        border-top: 3px solid #5C7F8B;
        border-left: 3px solid #5C7F8B;
    }

    .d14 h1:after {
        bottom: -20%;
        right: -15px;
        width: 20px;
        height: 15px;
        border-bottom: 3px solid #5C7F8B;
        border-right: 3px solid #5C7F8B;
    }

    .custom-order-card {
        padding: 15px;
        margin-top: 20px !important;
    }

    .custom-order-content {
        gap: 12px;
        flex-direction: column;
        text-align: center;
    }

    .custom-order-text {
        min-width: auto;
        text-align: center;
    }

    .custom-order-text p {
        font-size: 0.9rem;
    }

    .custom-order-icon {
        font-size: 1.8rem;
    }

    .custom-order-btn {
        padding: 6px 16px;
        font-size: 0.9rem;
    }
}

@media (max-width: 576px) {
    .hero-title {
        font-size: 1.7rem;
        padding: 6px 25px;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .hero-btn {
        padding: 8px 25px;
        font-size: 0.9rem;
    }

    .custom-order-card {
        padding: 12px;
    }

    .custom-order-text p {
        font-size: 0.85rem;
    }
}

@media (max-width: 400px) {
    .hero-title {
        font-size: 1.5rem;
        padding: 5px 20px;
    }

    .d14 h1:before {
        left: -10px;
        width: 15px;
    }

    .d14 h1:after {
        right: -10px;
        width: 15px;
    }
}

#bg_shop {
    background-color: #b5c1d8 !important;
}

.btn-processing {
  position: relative;
  pointer-events: none;
  opacity: 0.8;
}
.btn-processing .spinner {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid rgba(255,255,255,0.3);
  border-radius: 50%;
  border-top-color: #fff;
  animation: spin 1s ease-in-out infinite;
  margin-right: 8px;
  vertical-align: middle;
}
@keyframes spin {
  to { transform: rotate(360deg); }
}


.cart-actions .btn {
    border: 2px solid;  /* Синий бордюр как у Bootstrap primary */
    color: #5C7F8B; /* Синий текст */
    transition: all 0.3s ease;
    margin-top: 30px;
}
.cart-actions .btn:hover {
    background-color: #5C7F8B;
    color: #FFFFFF;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}
.quantity-control {
    max-width: 500px;
}



.quantity-info {
    font-size: 13px;
    color: #666;
}


/* Основные стили для футера карточки */
#constructor .card-footer {
    padding: 0.5rem 0.75rem !important;
    margin-top: auto;
    background: transparent !important;
    border-top: none !important;
}

/* Контейнер кнопок */
#constructor .card-footer .d-flex {
    align-items: center;
    gap: 6px;
    min-height: 36px;
}

/* Стили для кнопки корзины */
#constructor .add-to-cart-btn .btn {
    width: 32px;
    height: 32px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
}

/* Стили для блока с кнопками +/- */
#constructor .quantity-control {
    display: flex;
    align-items: center;
    background-color: #f8f9fa;
    border-radius: 6px;
    height: 28px;
    padding: 0 2px;
    min-width: 72px;
    max-width: 80px;
}


#constructor .quantity-control .btn:hover {
    background-color: #e9ecef;
}

#constructor .quantity-control .cart-quantity {
    min-width: 16px;
    max-width: 24px;
    text-align: center;
    font-weight: 500;
    font-size: 0.8rem;
    padding: 0 2px;
}

/* Стили для кнопки "Подробнее" */
#constructor .card-footer .btn-outline-secondary {
    height: 32px;
    padding: 0 6px;
    min-width: 72px;
    font-size: 0.7rem;
    display: flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
}

/* Адаптация для мобильных */
@media (max-width: 768px) {
    #constructor .card-footer {
        padding: 0.5rem !important;
    }

    #constructor .quantity-control {
        min-width: 68px;
        height: 26px;
    }

    #constructor .quantity-control .btn {
        width: 20px;
        height: 20px;
    }

    #constructor .card-footer .btn-outline-secondary {
        min-width: 70px;
        font-size: 0.7rem;
        padding: 0 6px;
    }
}


.holiday-header {
    position: relative;
    margin-bottom: 1.5rem; /* Уменьшаем общий отступ */
    padding-bottom: 1.5rem; /* Добавляем внутренний отступ снизу */
}

.holiday-title {
    font-family: 'Playfair Display', serif;
    font-weight: 600;
    font-size: 2.2rem;
    color: #5C7F8B;
    margin-bottom: 1rem; /* Увеличиваем отступ снизу у заголовка */
    text-align: left;
}

.holiday-link {
    text-decoration: none;
    color: inherit;
    display: inline-flex;
    align-items: center;
    transition: all 0.3s ease;
}

.holiday-link:hover {
    color: #e74c3c;
    transform: translateX(5px);
}

.holiday-text {
    position: relative;
    display: inline-block;
}

.holiday-text::after {
        content: '';
        position: absolute;
        bottom: -8px;
        left: 0;
        right: 0;
        height: 3px;
        background: linear-gradient(to right, #e74c3c, #5C7F8B);
        border-radius: 3px;
        margin: 0 auto;
        width: 100px;
    }

.holiday-link:hover .holiday-text::after {
        background: linear-gradient(to right, #e74c3c, #5C7F8B);
    }

.holiday-arrow {
    margin-left: 10px;
    font-size: 1.8rem;
    opacity: 0;
    transition: all 0.3s ease;
}

.holiday-link:hover .holiday-arrow {
    opacity: 1;
}


.holiday-image-container {
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.holiday-image-container:hover {
    transform: translateY(-5px);
}

.holiday-image {
    transition: transform 0.5s ease;
}

.holiday-image:hover {
    transform: scale(1.03);
}

.btn-outline-secondary.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

/* Плавные переходы для кнопок */
.add-to-cart-btn, .quantity-control {
    transition: opacity 0.3s ease, display 0.3s ease;
}

/* Состояние disabled для кнопок */
.btn-outline-secondary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}


/* Поиск */
.search-form {
    max-width: 250px;
}

.search-input {
    border-radius: 20px !important;
}

.search-btn {
    border-radius: 0 20px 20px 0 !important;
}



/* Форма поиска на странице результатов */
.search-form-large {
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.search-form-large .input-group {
    margin-bottom: 10px;
}

.search-form-large .form-control {
    border-radius: 5px 0 0 5px !important;
}

.search-form-large .btn {
    border-radius: 0 5px 5px 0 !important;
}

.sticky-cart {
    align-self: flex-start; /* Для правильного позиционирования в колонке */
    position: sticky !important;
    top: 200px !important;
    z-index: 1000 !important;
    transition: top 0.3s ease;
    height: fit-content; /* Чтобы корзина не растягивалась */
    margin-top: 20px; /* Отступ сверху */
}

.category-card {
    cursor: pointer;
    transition: all 0.3s ease;
}

.category-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.category-card.border-primary {
    border: 2px solid #5C7F8B !important;
}


/* Убираем все границы у аккордеона */
.accordion {
    --bs-accordion-border-width: 2px;

}

/* Убираем границу при фокусе */
.accordion-button:focus {
    box-shadow: none !important;
}

/* Убираем границы у элементов аккордеона */
.accordion-item {

    margin-bottom: 10px;
    background-color: transparent;
}

.accordion-header {
    background-color: #5C7F8B;

    border-radius: 0.375rem !important; /* Добавляем скругление углов */
}

.accordion-button:not(.collapsed) {
    background-color: #5C7F8B;
    color: white;

}
.card {
    transition: transform 0.2s;
}


/* Стили для круглых категорий */
    .category-circle {
        width: 100px;
        height: 100px;
        border-radius: 50%;
        overflow: hidden;
        margin: 0 auto 10px;
        cursor: pointer;
        transition: all 0.3s ease;
        border: 2px solid transparent;
    }

    .category-circle:hover {
        transform: scale(1.05);
        box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    }

    .category-circle.active {
        border-color: #5C7F8B;
    }

    .category-circle img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

    .category-name {
        text-align: center;
        font-size: 0.9rem;
        margin-top: 5px;
    }

    /* Уменьшенные карточки товаров */
    .product-card-sm {
        height: 100%;
        transition: all 0.3s ease;
    }

    .product-card-sm:hover {
        transform: translateY(-5px);
        box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    }

    .product-card-sm .card-img-top {
        height: 150px;
        object-fit: cover;
    }

    .product-card-sm .card-body {
        padding: 0.75rem;
    }

    .product-card-sm .card-title {
        font-size: 0.9rem;
        margin-bottom: 0.5rem;
    }

    .product-card-sm .card-text {
        font-size: 0.85rem;
    }


/* ОСНОВНЫЕ СТИЛИ ДЛЯ КОНСТРУКТОРА БУКЕТОВ - ОБЩИЕ КЛАССЫ */
.constructor-small-container .card-img-container {
    position: relative;
    width: 100%;
    height: 200px !important;
    overflow: hidden;
    background: #f8f9fa;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Слайдер в конструкторе */
.constructor-small-container .product-image-slider {
    width: 100%;
    height: 100%;
    position: relative;
}

.constructor-small-container .slider-item {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.3s ease;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.constructor-small-container .slider-item.active {
    opacity: 1;
}

/* ИЗОБРАЖЕНИЯ - ЗАПОЛНЯЕМ ВСЮ ОБЛАСТЬ */
.constructor-small-container .slider-item img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    display: block;
}

/* Для одиночных изображений */
.constructor-small-container .single-image-container {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8f9fa;
}

.constructor-small-container .single-image-container img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
}

/* Навигация слайдера */
.constructor-small-container .slider-nav {
    position: absolute;
    bottom: 10px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: space-between;
    padding: 0 10px;
    z-index: 10;
}

.constructor-small-container .slider-prev,
.constructor-small-container .slider-next {
    width: 30px;
    height: 30px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.constructor-small-container .slider-prev:hover,
.constructor-small-container .slider-next:hover {
    background-color: white;
    transform: scale(1.1);
}

/* Бейджи */
.constructor-small-container .promotion-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #e74c3c;
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-weight: bold;
    z-index: 5;
    font-size: 0.8rem;
    animation: pulse 2s infinite;
}

.constructor-small-container .availability-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: bold;
    z-index: 5;
}

.constructor-small-container .variants-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: #0d6efd;
    color: white;
    padding: 3px 6px;
    border-radius: 3px;
    font-size: 0.7rem;
    z-index: 5;
}

/* Анимация пульсации для акционного бейджа */
@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* Адаптивность для мобильных */
@media (max-width: 768px) {
    .constructor-small-container .card-img-container {
        height: 180px !important;
    }
}

/* Стили для прогресс-бара */
.progress-steps {
    margin-bottom: 2rem;
}

.progress {
    height: 6px;
    background-color: #e9ecef;
    margin-bottom: 10px;
}

.progress-bar {
    background-color: #5C7F8B;
    transition: width 0.3s ease;
}

.step-indicators {
    position: relative;
}

#constructor .step {
    text-align: center;
    position: relative;
    z-index: 1;
}

.step span {
    display: inline-flex;
    width: 30px;
    height: 30px;
    background-color: #e9ecef;
    border-radius: 50%;
    align-items: center;
    justify-content: center;
    margin-bottom: 5px;
    color: #6c757d;
    font-weight: bold;
}

.step.active span {
    background-color: #5C7F8B;
    color: white;
}

.step p {
    margin: 0;
    font-size: 0.9rem;
    color: #6c757d;
}

.step.active p {
    color: #212529;
    font-weight: 500;
}

/* Стили для шагов конструктора */
.construction-step {
    display: none;
}

.construction-step.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

.navigation-buttons {
    display: flex;
    justify-content: space-between;
    padding: 1rem 0;
}

/* Добавьте для завершенных шагов */
.step.completed span {
    background-color: #28a745;
    color: white;
}

.step.completed p {
    color: #28a745;
}


/* Гарантируем, что контейнеры с товарами будут правильно отображаться */
#greensContainer, #decorContainer {
    display: flex;
    flex-wrap: wrap;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}


/* Обновленные стили для элементов букета */
.bouquet-item-container {
    display: flex;
    flex-direction: column;
    width: 100%;
}
.bouquet-item-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.bouquet-item-name {
    font-weight: bold;
    margin-bottom: 4px;
    word-break: break-word; /* Перенос длинных слов */
}
.bouquet-item-details {
    display: flex;
    justify-content: space-between;
    width: 100%;
}
.bouquet-item-price {
    color: #6c757d;
    font-size: 0.875rem;
}
.bouquet-item-total {
    font-weight: 500;
    margin-left: 8px;
}
.bouquet-item-actions {
    display: flex;
    align-items: center;
    margin-left: 8px;
}

/* Добавьте в main.css */
.modal {
    z-index: 1060 !important;
}

.modal.show {
    z-index: 1060 !important;
    display: block !important;
}

.modal-dialog {
    z-index: 1061 !important;
}

.modal-backdrop {
    z-index: 1050 !important;
}

/* Убедитесь, что модальное окно поверх всего */
.modal.fade.show {
    z-index: 1060 !important;
    display: block !important;
}

/* Бэкдроп должен быть под модальным окном */
.modal-backdrop.fade.show {
    z-index: 1050 !important;
}


.product-params {
    margin-bottom: 1.5rem;
}

.product-params .param {
    display: inline-flex;
    align-items: center;
    background: #f8f9fa;
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-size: 0.9rem;
    margin-right: 0.5rem;
    margin-bottom: 0.5rem;
}

.product-params .param i {
    margin-right: 0.5rem;
    color: #6c757d;
}

#product-description {
    line-height: 1.6;
    color: #6c757d;
}


/* Переопределение стилей Bootstrap для вариантов */
#product-detail .variant-selector .btn-group {
    gap: 0.5rem;
}

#product-detail .variant-selector .btn-check:checked + .btn-outline-primary,
#product-detail .variant-selector .btn-outline-primary.active {
    background-color: #5C7F8B !important;
    border-color: #5C7F8B !important;
    color: white !important;
    box-shadow: none !important;
}

#product-detail .variant-selector .btn-outline-primary {
    border: 2px solid #5C7F8B !important;
    color: #5C7F8B !important;
    background-color: white !important;
    border-radius: 8px !important;
    padding: 0.8rem 0.5rem;
    flex: 1 0 auto;
    min-width: 120px;
    transition: all 0.3s ease;
    margin: 0;
}

#product-detail .variant-selector .btn-outline-primary:hover {
    background-color: #4A6B7A !important;
    border-color: #4A6B7A !important;
    color: white !important;
}

/* Дополнительные стили (остаются без изменений) */
#product-detail .variant-selector .form-label {
    color: #5C7F8B;
    font-size: 1.1rem;
    margin-bottom: 0.8rem;
    display: block;
}

#product-detail .variant-selector .btn-outline-primary .fw-bold {
    font-size: 1.1rem;
    margin-top: 0.4rem;
    color: inherit;
}

#product-detail .variant-selector .badge {
    font-size: 0.75rem;
    font-weight: 500;
    margin-top: 0.5rem;
    width: 100%;
}

#product-detail .variant-selector .badge.bg-success {
    background-color: #E1F0F4 !important;
    color: #2A5D68;
}

#product-detail .variant-selector .badge.bg-danger {
    background-color: #F8E1E1 !important;
    color: #A04545;
}

@media (max-width: 768px) {
    #product-detail .variant-selector .btn-outline-primary {
        min-width: calc(50% - 0.5rem);
        padding: 0.6rem 0.3rem;
    }
}


.variant-item {
    transition: all 0.2s;
}

.variant-item:hover {
    background-color: #f8f9fa;
}

.select-variant-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.added-to-cart {
    animation: pulse 1s;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.03); }
    100% { transform: scale(1); }
}

/* Стили для групповых карточек */


.product-card-group {
    position: relative;
}

.grouped-flowers-container {
    position: absolute;
    left: 100%;
    top: 0;
    width: auto;
    min-width: 0;
    max-width: calc(200px * 3 + 16px);
    background: white;
    z-index: 1700 !important;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    border-radius: 0 8px 8px 0;
    padding: 8px;
    overflow: hidden;
}

.grouped-flowers-container .row {
    display: flex;
    flex-wrap: nowrap;
    width: max-content;
    gap: 8px;
}

.grouped-flowers-container .col {
    width: 200px;
    flex: 0 0 auto;
}

.variants-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background-color: #0d6efd;
    color: white;
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 0.8rem;
    z-index: 10;
}

.toggle-group {
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}


/* Базовые стили для изображений товаров */
.product-image-mobile {
    max-width: 100%;
    height: auto;
    transition: transform 0.3s ease;
}

/* Для мобильных устройств */
@media (max-width: 767.98px) {
    .product-image-mobile {
        max-height: 300px !important; /* Переопределяем другие стили */
        width: auto !important;
        margin: 0 auto; /* Центрирование */
    }

    .product-image-slider-detail .product-image-mobile {
        max-height: 250px !important;
    }

    .product-image-slider-detail {
        max-width: 100%;
        margin: 0 auto;
    }


}

/* Для очень маленьких экранов */
@media (max-width: 575.98px) {
    .product-image-mobile {
        max-height: 250px !important;
    }

    .product-image-slider-detail .product-image-mobile {
        max-height: 200px !important;
    }
}

/* Стили для контейнера вариантов */
.variants-container {
    gap: 8px;
}

.variant-option {
    flex: 0 0 auto;
}

.variants-scroll-container {
    max-width: 100%;
    overflow-x: auto;
}

.variants-row {
    min-width: max-content;
    flex-wrap: nowrap;
}

/* Увеличиваем ширину вложенных карточек */
.grouped-flowers-container .product-card {
    min-width: 200px;
    width: 200px;
}

/* Убедимся что скрытые input не влияют на верстку */
.btn-check {
    position: absolute;
    clip: rect(0, 0, 0, 0);
    pointer-events: none;
}

/* Стили для кнопок вариантов */
.variant-option .btn {
    min-width: 140px;
    white-space: normal;
    word-wrap: break-word;
    text-align: center;
    padding: 10px 8px;
    height: auto;
    min-height: 90px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

/* Активный вариант */
.btn-check:checked + .btn {
    background-color: #0d6efd;
    border-color: #0d6efd;
    color: white;
}

/* Адаптивность */
@media (max-width: 768px) {
    .variant-option .btn {
        min-width: 120px;
        padding: 8px 6px;
        min-height: 80px;
        font-size: 0.9rem;
    }
}

@media (max-width: 576px) {
    .variant-option .btn {
        min-width: 100px;
        padding: 6px 4px;
        min-height: 70px;
        font-size: 0.85rem;
    }
}

/* ===== ОПТИМИЗИРОВАННЫЕ СТИЛИ КАРТОЧЕК ТОВАРОВ ===== */

/* Базовые стили карточки */
.product-card {
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    background: white;
    border: 1px solid #e0e6eb;
    height: 100%;
    display: flex;
    flex-direction: column;
    position: relative;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    border-color: #5C7F8B;
}

.card-img-container {
    position: relative;
    width: 100%;
    height: 250px;
    overflow: hidden;
    background: #f8f9fa;
    border-radius: 8px 8px 0 0;
    flex-shrink: 0;
}

/* Общие стили для слайдера и одиночных изображений */
.product-image-slider,
.single-image-container {
    width: 100%;
    height: 100%;
    position: relative;
}

/* Слайды */
.slider-item {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.slider-item.active {
    opacity: 1;
    z-index: 2;
}

/* Изображения */
.slider-item img,
.single-image-container img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover;
    cursor: pointer;
    display: block;
}

/* Навигация слайдера */
.slider-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 32px;
    height: 32px;
    background: rgba(255, 255, 255, 0.95);
    border: none;
    border-radius: 50%;
    color: #333;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    opacity: 0;
    z-index: 20;
    font-size: 14px;
    font-weight: bold;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.slider-nav-btn:hover {
    background: white;
    transform: translateY(-50%) scale(1.1);
}

.slider-nav-btn.prev-btn {
    left: 8px;
}

.slider-nav-btn.next-btn {
    right: 8px;
}

/* Показываем кнопки при наведении на контейнер */
.card-img-container:hover .slider-nav-btn {
    opacity: 0.7;
}

.card-img-container:hover .slider-nav-btn:hover {
    opacity: 1;
}

/* Баннеры карточки */
.card-badge {
    position: absolute;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: bold;
    z-index: 5;
    white-space: nowrap;
}

/* Баннер акции - правый верхний угол */
.promotion-badge {
    top: 10px;
    right: 10px;
    background: #dc3545;
    color: white;
    animation: pulse-badge 2s infinite;
}

/* Баннер наличия - левый верхний угол */


.availability-badge.in-stock {
    background: #28a745;
}

.availability-badge.out-of-stock {
    background: #dc3545;
}

.availability-badge.expected {
    background: #ffc107;
    color: #212529;
}

/* Стили для бейджа статуса в блоке цены */
.availability-price-badge {
    position: absolute;
    top: -10px;
    left: 0;
    z-index: 20;
}

.availability-price-status {
    font-size: 14px !important;
    padding: 6px 12px !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.availability-price-status.in-stock {
    background: #28a745 !important;
    color: white !important;
}

.availability-price-status.out-of-stock {
    background: #dc3545 !important;
    color: white !important;
}

.availability-price-status.expected {
    background: #ffc107 !important;
    color: #212529 !important;
}

/* Обертка для блока цены с отступом под бейдж */
.price-block {
    position: relative;
    padding-top: 25px;
    padding-left: 15px;
    padding-right: 15px;
    background: #f8f9fa;
    border-radius: 12px;
    border: 1px solid #e9ecef;
    margin-top: 15px;
}

/* Адаптивность для мобильных */
@media (max-width: 768px) {
    .availability-price-badge {
        position: relative;
        top: 0;
        margin-bottom: 10px;
    }

    .price-block {
        padding-top: 15px;
        margin-top: 0;
    }
}

/* Баннер вариантов - заменяет баннер акции для групповых карточек */
.variants-badge {
    top: 10px;
    right: 10px;
    background: #17a2b8;
    color: white;
}

/* Убираем старые стили badge */
.bg-danger,
.bg-warning,
.bg-success,
.bg-info {
    /* Эти классы теперь не используются для позиционирования */
}

/* Анимация пульсации для акционных бейджей */
@keyframes pulse-badge {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}


/* Тело карточки */
.card-body {
    padding: 1rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.card-title {
    color: #3B4C55;
    margin-bottom: 0.3rem; /* Уменьшено с 0.5rem */
    min-height: auto; /* Убрано фиксированное значение */
    line-height: 1.3;
}

.card-price {
    color: #5C7F8B;
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.text-decoration-line-through {
    text-decoration: line-through;
    color: #6c757d;
    font-size: 0.9rem;
}

.text-danger {
    color: #dc3545 !important;
    font-weight: bold;
}

/* Контейнер кнопок - уменьшенный размер */
.card-footer {
    padding: 0.5rem 0.75rem !important;
    background: transparent !important;
    border-top: 1px solid #e9ecef !important;
    margin-top: auto;
}

.card-footer .d-flex {
    align-items: center;
    gap: 0.4rem;
    min-height: 36px; /* Уменьшено с 44px */
}

/* Кнопка добавления в корзину - уменьшенная */
.add-to-cart-btn .btn {
    width: 36px; /* Уменьшено с 44px */
    height: 36px; /* Уменьшено с 44px */
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    transition: all 0.3s ease;
    padding: 0;
}

.add-to-cart-btn .bi-cart4 {
    font-size: 1rem; /* Уменьшено с 1.2rem */
    color: #5C7F8B;
    transition: all 0.3s ease;
}

.add-to-cart-btn .btn:hover {
    background-color: #5C7F8B;
}

.add-to-cart-btn .btn:hover .bi-cart4 {
    color: white;
    transform: scale(1.1);
}

/* Кнопка "Выбрать вариант" - только текст, без иконки */
.choose-variant-btn .btn {
    padding: 0.4rem 0.6rem; /* Уменьшенный padding */
    border-radius: 6px;
    font-size: 0.8rem; /* Уменьшенный шрифт */
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 110px;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.choose-variant-btn .btn .bi-cart4 {
    display: none; /* Скрываем иконку корзины */
}

/* Управление количеством - уменьшенное */
.quantity-control {
    display: flex;
    align-items: center;
    background-color: #f8f9fa;
    border-radius: 6px;
    padding: 0.2rem;
    height: 32px;
    width: fit-content; /* Контейнер подстраивается под содержимое */
    gap: 4px; /* Отступ между элементами */
}

.quantity-control .btn {
    width: 24px;
    height: 24px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    font-size: 0.8rem;
    flex-shrink: 1;
}

.quantity-control .cart-quantity {
    min-width: 16px;
    text-align: center;
    font-weight: 500;
    font-size: 0.8rem; /* Уменьшено с 0.9rem */
}

/* Кнопка "Подробнее" - уменьшенная */
.btn-outline-secondary {
    padding: 0.4rem 0.6rem; /* Уменьшено */
    border-radius: 6px;
    font-size: 0.8rem; /* Уменьшено с 0.85rem */
    height: 36px; /* Уменьшено с 44px */
    display: flex;
    align-items: center;
    justify-content: center;
    /* min-width: 85px; /* Уменьшено с 100px */
    transition: all 0.3s ease;
}

.btn-outline-secondary:hover {
    background-color: #5C7F8B;
    color: white;
    border-color: #5C7F8B;
}

/* Адаптивность для уменьшенных кнопок */
@media (max-width: 768px) {
    .card-footer {
        padding: 0.4rem 0.5rem !important;
    }

    .card-footer .d-flex {
        min-height: 32px; /* Уменьшено */
        gap: 0.3rem;
    }

    .add-to-cart-btn .btn,
    .btn-outline-secondary,
    .choose-variant-btn .btn {
        height: 32px; /* Уменьшено */
    }

    .add-to-cart-btn .btn {
        width: 32px; /* Уменьшено */
    }

    .quantity-control {
        height: 28px; /* Уменьшено */
        min-width: 80px; /* Уменьшено */
    }

    .quantity-control .btn {
        width: 22px; /* Уменьшено */
        height: 22px; /* Уменьшено */
    }

    .choose-variant-btn .btn,
    .btn-outline-secondary {
      /*  min-width: 75px; /* Уменьшено */
        font-size: 0.75rem; /* Уменьшено */
        padding: 0.3rem 0.5rem; /* Уменьшено */
    }
}

@media (max-width: 576px) {
    .card-footer .d-flex {
        min-height: 30px;
    }

    .add-to-cart-btn .btn,
    .btn-outline-secondary,
    .choose-variant-btn .btn {
        height: 30px;
    }

    .add-to-cart-btn .btn {
        width: 30px;
    }

    .quantity-control {
        height: 26px;
        min-width: 70px;
    }

    .choose-variant-btn .btn,
    .btn-outline-secondary {
      /*  min-width: 70px;*/
        font-size: 0.7rem;
    }
}

/* Сетка товаров */
.products-grid {
    display: flex;
    flex-wrap: wrap;
    margin: 0 -0.5rem;
}

.products-grid > [class*="col-"] {
    padding: 0 0.5rem;
    margin-bottom: 1rem;
}

/* Адаптивность */
@media (max-width: 1200px) {
    .card-img-container {
        height: 220px;
    }
}

@media (max-width: 992px) {
    .card-img-container {
        height: 200px;
    }

    .card-title {
        font-size: 0.9rem;
        min-height: 2.4em;
    }

    .card-price {
        font-size: 1rem;
    }
}

@media (max-width: 768px) {
    .card-img-container {
        height: 180px;
    }

    .card-body {
        padding: 0.75rem;
    }


    .card-footer .d-flex {
        min-height: 40px;
    }


    .slider-nav-btn {
        width: 28px;
        height: 28px;
        font-size: 12px;
    }

    .badge {
        font-size: 10px;
        padding: 3px 6px;
    }
}

@media (max-width: 576px) {
    .card-img-container {
        height: 160px;
    }

    .card-title {
        font-size: 0.85rem;
        min-height: 2.2em;
    }

}

/* Стили для модального окна изображений */
.image-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 10000;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.image-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
}

.image-modal-content {
    position: relative;
    width: 90%;
    height: 90%;
    max-width: 1200px;
    background: black;
    border-radius: 12px;
    overflow: hidden;
}

.image-modal-close {
    position: absolute;
    top: 20px;
    right: 30px;
    color: white;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    z-index: 10001;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    background: rgba(0,0,0,0.5);
    border-radius: 50%;
}

.image-modal-close:hover {
    color: #ccc;
    background: rgba(0,0,0,0.7);
}

.image-modal-slider {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.modal-slides-container {
    position: relative;
    width: 100%;
    height: 100%;
}

.modal-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
}

.modal-slide.active {
    opacity: 1;
}

.modal-slide img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
}

.image-modal-prev,
.image-modal-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.5);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 20px;
    font-weight: bold;
    transition: all 0.3s ease;
    z-index: 100;
}

.image-modal-prev:hover,
.image-modal-next:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.8);
}

.image-modal-prev {
    left: 20px;
}

.image-modal-next {
    right: 20px;
}

/* Скрываем кнопки если только одно изображение */
.image-modal-slider:has(.modal-slide:only-child) .image-modal-prev,
.image-modal-slider:has(.modal-slide:only-child) .image-modal-next {
    display: none;
}

.promotion-banner {
    background: linear-gradient(135deg, #ff6b6b, #ff8e8e);
    color: white;
    padding: 2rem;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(255, 107, 107, 0.3);
    margin-bottom: 2rem;
}

.promotion-banner h1 {
    font-weight: 700;
    margin-bottom: 1rem;
}

.promotion-banner .lead {
    font-size: 1.25rem;
    opacity: 0.9;
}

/* ===== СТИЛИ ДЛЯ СТРАНИЦЫ ДЕТАЛЬНОГО ПРОСМОТРА ТОВАРА ===== */

/* ===== ИСПРАВЛЕНИЯ ДЛЯ ДЕТАЛЬНОЙ СТРАНИЦЫ ТОВАРА ===== */

/* Большая кнопка "Добавить в корзину" */
#add-to-cart-btn {
    padding: 14px 28px !important;
    font-size: 16px !important;
    height: auto !important;
    min-height: 54px;
    border-radius: 10px !important;
    background: #5C7F8B !important;
    color: white !important;
    border: none !important;
    font-weight: 600;
    transition: all 0.3s ease;
    display: flex !important;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
    width: auto;
}

#add-to-cart-btn:hover {
    background: #4a6773 !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(92, 127, 139, 0.3);
}

/* Большая кнопка "Удалить" */
#remove-from-cart-btn {
    padding: 12px 20px !important;
    font-size: 14px !important;
    height: auto !important;
    min-height: 46px;
    border-radius: 8px !important;
    border: 1px solid #dc3545 !important;
    color: #dc3545 !important;
    background: white !important;
    font-weight: 500;
    transition: all 0.3s ease;
    display: flex !important;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
    width: auto;
}

#remove-from-cart-btn:hover {
    background: #dc3545 !important;
    color: white !important;
    transform: translateY(-1px);
}

/* ===== СТИЛИ ДЛЯ КАРТОЧЕК ТОВАРОВ (МАЛЕНЬКИЕ КНОПКИ) ===== */

.product-card .quantity-control {
    display: none;
    align-items: center;
    background-color: #f8f9fa !important;
    border-radius: 6px !important;
    padding: 0.2rem !important;
    height: 32px !important;
    width: fit-content !important;
    gap: 4px !important;
    margin: 0 !important;
}

.product-card .quantity-control .btn {
    width: 24px !important;
    height: 24px !important;
    padding: 0 !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    border-radius: 4px !important;
    font-size: 0.8rem !important;
    flex-shrink: 0;
    border: 1px solid #dee2e6 !important;
    background: white !important;
}

.product-card .quantity-control .cart-quantity {
    min-width: 16px !important;
    text-align: center;
    font-weight: 500;
    font-size: 0.8rem !important;
}

/* Маленькая кнопка добавления в корзину ДЛЯ КАРТОЧЕК */
.product-card .add-to-cart-btn .btn {
    width: 36px !important;
    height: 36px !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    border-radius: 6px !important;
    transition: all 0.3s ease;
    padding: 0 !important;
    border: 1px solid #dee2e6 !important;
    background: white !important;
}

.product-card .add-to-cart-btn .bi-cart4 {
    font-size: 1rem !important;
    color: #5C7F8B;
    transition: all 0.3s ease;
}

.product-card .add-to-cart-btn .btn:hover {
    background-color: #5C7F8B !important;
}

.product-card .add-to-cart-btn .btn:hover .bi-cart4 {
    color: white !important;
    transform: scale(1.1);
}

/* Маленькая кнопка "Подробнее" ДЛЯ КАРТОЧЕК */
.product-card .btn-outline-secondary {
    padding: 0.4rem 0.6rem !important;
    border-radius: 6px !important;
    font-size: 0.8rem !important;
    height: 36px !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    border: 1px solid #dee2e6 !important;
}

.product-card .btn-outline-secondary:hover {
    background-color: #5C7F8B !important;
    color: white !important;
    border-color: #5C7F8B !important;
}
/* Исправляем отображение изображения */
.product-image-slider-detail {
    position: relative;
    width: 100%;
    height: 500px;
    overflow: hidden;
    border-radius: 12px;
    background: #f8f9fa;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-image-slider-detail .slider-item {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-image-slider-detail .slider-item.active {
    opacity: 1;
    z-index: 2;
}

.product-image-slider-detail img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
}

/* Для одиночного изображения (не слайдера) */
.single-image-container-detail {
    width: 100%;
    height: 500px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8f9fa;
    border-radius: 12px;
    overflow: hidden;
    padding: 20px;
}

.single-image-container-detail img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
}

/* Блок текущего количества в корзине */
.current-in-cart {
    margin-top: 1.5rem;
    width: 100%;
}

.current-in-cart .alert {
    border-radius: 8px;
    margin-bottom: 0;
    padding: 12px 16px;
    font-size: 14px;
}

.current-in-cart .d-flex {
    align-items: center;
    gap: 12px;
}

/* Адаптивность для мобильных */
@media (max-width: 768px) {
    .quantity-control {
        flex-direction: row !important; /* Оставляем горизонтальное расположение */
        align-items: center !important;
        height: 28px !important; /* Чуть уменьшаем высоту */
        padding: 0.15rem !important;
        gap: 3px !important;
    }

    .product-card .quantity-control .btn {
        width: 22px !important; /* Чуть уменьшаем кнопки */
        height: 22px !important;
        font-size: 0.75rem !important;
    }

    .product-card .quantity-control .cart-quantity {
        min-width: 14px !important;
        font-size: 0.75rem !important;
    }

    /* Также уменьшаем другие кнопки в карточке для consistency */
    .product-card .add-to-cart-btn .btn {
        width: 32px !important;
        height: 32px !important;
    }

    .product-card .add-to-cart-btn .bi-cart4 {
        font-size: 0.9rem !important;
    }

    .product-card .btn-outline-secondary {
        padding: 0.3rem 0.5rem !important;
        font-size: 0.75rem !important;
        height: 32px !important;
    }

    #add-to-cart-btn {
        width: 100%;
        margin-left: 0 !important;
    }

    .current-in-cart .d-flex {
        flex-direction: column;
        align-items: stretch;
    }

    #remove-from-cart-btn {
        width: 100%;
        margin-left: 0 !important;
        margin-top: 8px;
    }

    .product-image-slider-detail,
    .single-image-container-detail {
        height: 350px;
    }
}

@media (max-width: 576px) {
    .product-image-slider-detail,
    .single-image-container-detail {
        height: 280px;
    }

    #add-to-cart-btn {
        padding: 12px 20px !important;
        font-size: 14px !important;
        min-height: 48px;
    }
}

/* Контейнер страницы */
.small-container {
    max-width: 1200px;
    margin: 0 auto;
}

/* Для очень маленьких экранов */
@media (max-width: 480px) {
    .product-card .quantity-control {
        height: 26px !important;
        padding: 0.1rem !important;
    }

    .product-card .quantity-control .btn {
        width: 20px !important;
        height: 20px !important;
        font-size: 0.7rem !important;
    }

    .product-card .quantity-control .cart-quantity {
        font-size: 0.7rem !important;
        min-width: 12px !important;
    }

    .product-card .add-to-cart-btn .btn {
        width: 30px !important;
        height: 30px !important;
    }

    .product-card .btn-outline-secondary {
        height: 30px !important;
        font-size: 0.7rem !important;
        padding: 0.25rem 0.4rem !important;
    }
}

/* Кнопки навигации для детального слайдера - ВСЕГДА ВИДИМЫЕ */
.product-image-slider-detail .slider-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.95);
    border: 2px solid rgba(92, 127, 139, 0.3);
    color: #5C7F8B;
    display: flex !important; /* Важно: всегда показываем */
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 20;
    font-size: 20px;
    font-weight: bold;
    border-radius: 50%;
    opacity: 1 !important; /* Важно: всегда непрозрачные */
    visibility: visible !important; /* Важно: всегда видимые */
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.product-image-slider-detail .slider-nav-btn:hover {
    background: white;
    border-color: #5C7F8B;
    color: #5C7F8B;
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.product-image-slider-detail .slider-nav-btn.prev-btn {
    left: 20px;
}

.product-image-slider-detail .slider-nav-btn.next-btn {
    right: 20px;
}

/* Убираем эффект скрытия для детального слайдера */
.product-image-slider-detail:hover .slider-nav-btn {
    opacity: 1 !important; /* Отменяем любые эффекты скрытия */
}

/* Для мобильных устройств делаем кнопки немного меньше */
@media (max-width: 768px) {
    .product-image-slider-detail .slider-nav-btn {
        width: 44px;
        height: 44px;
        font-size: 18px;
    }

    .product-image-slider-detail .slider-nav-btn.prev-btn {
        left: 15px;
    }

    .product-image-slider-detail .slider-nav-btn.next-btn {
        right: 15px;
    }
}

@media (max-width: 576px) {
    .product-image-slider-detail .slider-nav-btn {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }

    .product-image-slider-detail .slider-nav-btn.prev-btn {
        left: 10px;
    }

    .product-image-slider-detail .slider-nav-btn.next-btn {
        right: 10px;
    }
}

/* Убедимся, что кнопки не перекрываются бейджами */
.product-image-slider-detail .promotion-badge,
.product-image-slider-detail .availability-badge {
    z-index: 15; /* Бейджи под кнопками */
}

.product-image-slider-detail .slider-nav-btn {
    z-index: 25; /* Кнопки поверх всего */
}

/* Бейджи для детальной страницы */
.availability-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    padding: 5px 5px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: bold;
    z-index: 5;
    color: white;
}

.promotion-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 5px 5px;
    background: #dc3545;
    color: white;
    border-radius: 6px;
    font-size: 11px;
    font-weight: bold;
    z-index: 5;
    animation: pulse-badge 2s infinite;
}

/* Мобильные устройства (до 768px) */
@media (max-width: 768px) {
    .availability-badge {
        top: 5px;
        left: 5px;
        padding: 3px 4px;
        border-radius: 4px;
        font-size: 9px;
        font-weight: 600;
    }

    .promotion-badge {
        top: 5px;
        right: 5px;
        padding: 3px 4px;
        border-radius: 4px;
        font-size: 9px;
        font-weight: 600;
    }
}

/* Очень маленькие экраны (до 480px) */
@media (max-width: 480px) {
    .availability-badge {
        top: 3px;
        left: 3px;
        padding: 2px 3px;
        border-radius: 3px;
        font-size: 8px;
        font-weight: 600;
    }

    .promotion-badge {
        top: 3px;
        right: 3px;
        padding: 2px 3px;
        border-radius: 3px;
        font-size: 8px;
        font-weight: 600;
    }
}

/* Блок с параметрами товара */
.product-params {
    margin-bottom: 1.5rem;
}

.param {
    display: inline-flex;
    align-items: center;
    background: #f8f9fa;
    padding: 8px 12px;
    border-radius: 8px;
    margin-right: 8px;
    margin-bottom: 8px;
    font-size: 14px;
}

.param i {
    margin-right: 6px;
    color: #5C7F8B;
}

/* Блок цены и статуса */
.price-block {
    margin-bottom: 1.5rem;
}

#current-price {
    font-size: 2rem;
    font-weight: bold;
    color: #dc3545;
}

#original-price {
    font-size: 1.2rem;
    color: #6c757d;
}

#discount-badge {
    font-size: 0.9rem;
    padding: 4px 8px;
}

/* Управление количеством для детальной страницы */
/* Контейнер управления количеством ТОЛЬКО на детальной странице */
#quantity-control.quantity-control {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    background: none !important;
    border-radius: 0 !important;
    padding: 0 !important;
    height: auto !important;
    width: auto !important;
}

/* Большие кнопки +/- ТОЛЬКО на детальной странице */
#quantity-control .decrease-qty,
#quantity-control .increase-qty {
    width: 50px !important;
    height: 50px !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    border: 1px solid #dee2e6 !important;
    background: white !important;
    font-size: 18px !important;
    border-radius: 8px !important;
    transition: all 0.3s ease;
}

#quantity-control .decrease-qty:hover,
#quantity-control .increase-qty:hover {
    background: #f8f9fa !important;
    border-color: #5C7F8B !important;
}

/* Большое поле ввода количества ТОЛЬКО на детальной странице */
#quantity-control .quantity-input {
    width: 80px !important;
    height: 50px !important;
    text-align: center;
    font-size: 16px;
    font-weight: 600;
    border: 1px solid #dee2e6;
    border-radius: 8px;
}


/* Кнопка добавления в корзину для детальной страницы */
.btn-main {
    background: #5C7F8B;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-main:hover {
    background: #4a6773;
    color: white;
    transform: translateY(-2px);
}

/* Блок текущего количества в корзине */
.current-in-cart {
    margin-top: 1rem;
}

.current-in-cart .alert {
    border-radius: 8px;
    margin-bottom: 0;
}

/* Варианты товара */
.variants-container {
    gap: 10px;
}

.variant-option .btn {
    min-width: 140px;
    height: auto;
    padding: 12px;
    border-radius: 8px;
    text-align: center;
    white-space: normal;
}

.variant-option .btn-check:checked + .btn {
    background: #5C7F8B;
    color: white;
    border-color: #5C7F8B;
}


/* Стили для кнопки "Выбрать вариант" в карточках */
.product-card .choose-variant-btn .btn {
    padding: 0.3rem 0.5rem !important;
    border-radius: 6px !important;
    font-size: 0.7rem !important;
    height: 34px !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    border: 1px solid #5C7F8B !important;
    color: #5C7F8B !important;
    background: white !important;
    text-decoration: none !important;
    width: 100% !important;
    min-width: 70px !important;
}

.product-card .choose-variant-btn .btn:hover {
    background-color: #5C7F8B !important;
    color: white !important;
    border-color: #5C7F8B !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(92, 127, 139, 0.3);
}

/* Для контейнера кнопки выбора варианта */
.product-card .cart-control.choose-variant-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
}

/* Адаптивность для мобильных */
@media (max-width: 768px) {
    .product-card .choose-variant-btn .btn {
        font-size: 0.75rem !important;
        padding: 0.35rem 0.5rem !important;
        height: 34px !important;
        min-width: 70px !important;
    }
}

@media (max-width: 576px) {
    .product-card .choose-variant-btn .btn {
        font-size: 0.7rem !important;
        padding: 0.3rem 0.4rem !important;
        height: 32px !important;
        min-width: 60px !important;
    }
}

/* Состав букета */
#bouquet-composition {
    background: #f8f9fa !important;
    border-radius: 12px;
    border: none;
}

#bouquet-composition h4 {
    color: #3B4C55;
    font-weight: 600;
}

#bouquet-composition h5 {
    color: #28a745;
    font-weight: 600;
}

/* Принудительные стили для скрытия/показа элементов */
.add-to-cart-btn[style*="display: block"] {
    display: block !important;
}

.add-to-cart-btn[style*="display: none"] {
    display: none !important;
}

.quantity-control[style*="display: flex"] {
    display: flex !important;
}

.quantity-control[style*="display: none"] {
    display: none !important;
}


.cookie-consent {
    animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
    from {
        transform: translateY(100%);
    }
    to {
        transform: translateY(0);
    }
}

.cookie-consent a:hover {
    color: #2980b9 !important;
}

@media (max-width: 768px) {
    .cookie-consent .container {
        padding: 0 15px;
    }
    .cookie-consent .btn {
        margin-top: 10px;
        width: 100%;
    }
}

.page-description-block {
    border-left: 4px solid #dc3545;
}

.description-text {
    line-height: 1.6;
    color: #495057;
}

.description-text p {
    margin-bottom: 1rem;
}


.steps .step {
    margin-bottom: 2rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 8px;
}
.advantages .advantage-item {
    margin-bottom: 1.5rem;
}
.faq .faq-item {
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #eee;
}
.cta-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 3rem;
    border-radius: 15px;
}

#confirmModal {
    z-index: 9999 !important;
}

#confirmModal.show {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    opacity: 1 !important;
    visibility: visible !important;
    background-color: rgba(0,0,0,0.5) !important;
}

#confirmModal .modal-dialog {
    z-index: 10000 !important;
    position: relative !important;
}

#confirmModal .modal-content {
    z-index: 10001 !important;
    position: relative !important;
}

/* Убираем стандартный бэкдроп */
.modal-backdrop {
    display: none !important;
}

/* Убедимся, что конструктор не перекрывает модальное окно */
.constructor-small-container {
    position: relative !important;
    z-index: auto !important;
}

/* Исправляем body */
body.modal-open {
    overflow: hidden !important;
    padding-right: 0px !important;
}