        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }

        body {
            font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Helvetica Neue', Helvetica, Arial, sans-serif;
            background: 
                repeating-linear-gradient(
                    45deg,
                    transparent,
                    transparent 2px,
                    rgba(255, 215, 0, 0.1) 2px,
                    rgba(255, 215, 0, 0.1) 4px
                ),
                repeating-linear-gradient(
                    -45deg,
                    transparent,
                    transparent 2px,
                    rgba(255, 215, 0, 0.05) 2px,
                    rgba(255, 215, 0, 0.05) 4px
                ),
                radial-gradient(circle at 20% 50%, rgba(120, 119, 198, 0.3) 0%, transparent 50%),
                radial-gradient(circle at 80% 20%, rgba(255, 119, 198, 0.3) 0%, transparent 50%),
                radial-gradient(circle at 40% 80%, rgba(120, 119, 198, 0.2) 0%, transparent 50%),
                linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            background-size: 100% 100%, 100% 100%, 100% 100%, 100% 100%, 100% 100%, 100% 100%;
            min-height: 100vh;
            margin: 0;
            padding: 0;
            display: flex;
            align-items: center;
            justify-content: center;
            position: relative;
        }


        /* Базовые стили для всех устройств */
        .phone-container {
            position: relative;
            width: 420px;
            height: min(812px, 100vh - 40px);
            background: #000;
            border-radius: 40px;
            padding: 12px;
            box-shadow: 0 20px 60px rgba(0,0,0,0.3);
            overflow: hidden;
            display: flex;
            flex-direction: column;
            max-height: 100vh;
        }

        .phone-notch {
            position: absolute;
            top: 0;
            left: 50%;
            transform: translateX(-50%);
            width: 180px;
            height: 25px;
            background: #000;
            border-radius: 0 0 15px 15px;
            z-index: 10;
        }

        .phone-screen {
            width: 100%;
            height: 100%;
            background: #0a0a0a;
            border-radius: 30px;
            overflow: hidden;
            position: relative;
            display: flex;
            flex-direction: column;
        }

        .chat-container {
            flex: 1;
            background: #8393dccc;
            display: flex;
            flex-direction: column;
            min-height: 0;
        }

        .chat-messages {
            flex: 1;
            padding: 20px;
            padding-top: 60px; /* Добавляем отступ сверху для первого сообщения */
            overflow-y: auto;
            display: flex;
            flex-direction: column;
            gap: 12px;
            -webkit-overflow-scrolling: touch;
            min-height: 0;
            scroll-behavior: smooth;
            scroll-padding-bottom: 20px;
            background: 
                repeating-linear-gradient(
                    45deg,
                    transparent,
                    transparent 30px,
                    rgba(255, 182, 193, 0.1) 30px,
                    rgba(255, 182, 193, 0.1) 60px
                ),
                repeating-linear-gradient(
                    -45deg,
                    transparent,
                    transparent 30px,
                    rgba(255, 182, 193, 0.05) 30px,
                    rgba(255, 182, 193, 0.05) 60px
                ),
                #8393dccc;
            position: relative;
        }

        .chat-messages::before {
            content: '🌸';
            position: absolute;
            top: 20px;
            left: 20px;
            font-size: 16px;
            opacity: 0.1;
            animation: float 6s ease-in-out infinite;
        }

        .chat-messages::after {
            content: '🌺';
            position: absolute;
            top: 60px;
            right: 30px;
            font-size: 14px;
            opacity: 0.08;
            animation: float 8s ease-in-out infinite reverse;
        }

        @keyframes float {
            0%, 100% { transform: translateY(0px) rotate(0deg); }
            50% { transform: translateY(-10px) rotate(5deg); }
        }

        /* Бургер меню - только квадратная кнопка над chat-input-container */
        .burger-button {
            position: absolute;
            bottom: 100px;
            right: 20px;
            background: #2C2C2E;
            border: none;
            color: #FFFFFF;
            padding: 12px;
            border-radius: 12px;
            cursor: pointer;
            transition: all 0.2s ease;
            display: flex;
            align-items: center;
            justify-content: center;
            width: 48px;
            height: 48px;
            box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
            z-index: 1001;
        }

        .burger-button:hover {
            background: #3A3A3C;
            transform: translateY(-2px);
            box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
        }

        /* Кнопка остановки генерации в инпуте */
        .stop-generation-button {
            position: absolute;
            right: 8px;
            bottom: 8px; /* Фиксируем к нижнему краю инпута */
            width: 32px;
            height: 32px;
            background: rgba(255, 59, 48, 0.15); /* Полупрозрачный красный */
            backdrop-filter: blur(10px); /* Эффект размытия стекла */
            border: 1px solid rgba(255, 59, 48, 0.3); /* Красная граница */
            border-radius: 18px;
            display: none; /* Скрыта по умолчанию */
            align-items: center;
            justify-content: center;
            cursor: pointer;
            transition: all 0.3s ease;
            flex-shrink: 0;
            z-index: 10;
            box-shadow:
                inset 0 1px 2px rgba(255, 255, 255, 0.3), /* Внутренний свет сверху */
                inset 0 -1px 2px rgba(0, 0, 0, 0.2), /* Внутренняя тень снизу */
                0 2px 8px rgba(255, 59, 48, 0.3), /* Внешняя тень */
                0 0 0 1px rgba(255, 255, 255, 0.1); /* Тонкое свечение */
            animation: stopButtonBlink 2s infinite;
        }

        .stop-generation-button:hover {
            background: rgba(255, 69, 58, 0.25); /* Более яркий красный при наведении */
            border-color: rgba(255, 59, 48, 0.4);
            box-shadow:
                inset 0 1px 3px rgba(255, 255, 255, 0.4), /* Более яркий внутренний свет */
                inset 0 -1px 3px rgba(0, 0, 0, 0.25), /* Более глубокая внутренняя тень */
                0 4px 12px rgba(255, 59, 48, 0.4), /* Более выраженная внешняя тень */
                0 0 0 1px rgba(255, 255, 255, 0.2); /* Более яркое свечение */
            transform: translateY(-1px); /* Легкий подъем при наведении */
        }

        .stop-generation-button:active {
            background: rgba(215, 0, 21, 0.2); /* Более темный красный при нажатии */
            transform: translateY(0); /* Возврат в исходное положение */
            box-shadow:
                inset 0 2px 4px rgba(0, 0, 0, 0.3), /* Внутренняя тень при нажатии */
                inset 0 -1px 2px rgba(255, 255, 255, 0.1), /* Свет снизу */
                0 1px 4px rgba(255, 59, 48, 0.2); /* Меньшая внешняя тень */
        }

        /* Иконка кнопки стоп генерации */
        .stop-generation-button svg {
            width: 16px;
            height: 16px;
            stroke: rgba(255, 255, 255, 0.95); /* Белая иконка */
            fill: none; /* Убираем заливку, используем только stroke */
            filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.3)); /* Тень для иконки */
        }

        /* Кнопка показать всё */
        .show-all-button {
            position: absolute;
            bottom: 100px;
            right: 80px; /* Слева от бургера (100px - 20px = 80px) */
            background: #3A3A3C;
            border: none;
            color: #FFFFFF;
            padding: 12px;
            border-radius: 12px;
            cursor: pointer;
            transition: all 0.2s ease;
            display: flex;
            align-items: center;
            justify-content: center;
            width: 48px;
            height: 48px;
            box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
            z-index: 1001;
        }

        .show-all-button:hover {
            background: #4A4A4C;
            transform: translateY(-2px);
            box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
        }

        /* Активное состояние автопрокрутки */
        .show-all-button.active {
            opacity: 1;
        }

        .show-all-button.active:hover {
            opacity: 0.9;
        }

        /* Неактивное состояние автопрокрутки */
        .show-all-button.inactive {
            opacity: 0.4;
        }

        .show-all-button.inactive:hover {
            opacity: 0.6;
        }

        @keyframes stopButtonBlink {
            0%, 100% { 
                opacity: 0.8;
                transform: scale(1);
            }
            50% { 
                opacity: 0.6;
                transform: scale(0.98);
            }
        }

        /* Кнопка корзины в инпуте */
        .cart-button {
            position: absolute;
            right: 8px; /* По умолчанию максимально справа */
            bottom: 8px; /* Фиксируем к нижнему краю инпута */
            width: 32px;
            height: 32px;
            background: rgba(255, 255, 255, 0.15); /* Полупрозрачный белый */
            backdrop-filter: blur(10px); /* Эффект размытия стекла */
            border: 1px solid rgba(255, 255, 255, 0.2); /* Тонкая светлая граница */
            border-radius: 18px;
            display: none; /* Скрыта по умолчанию */
            align-items: center;
            justify-content: center;
            cursor: pointer;
            transition: all 0.3s ease;
            flex-shrink: 0;
            z-index: 10;
            box-shadow:
                inset 0 1px 2px rgba(255, 255, 255, 0.3), /* Внутренний свет сверху */
                inset 0 -1px 2px rgba(0, 0, 0, 0.1), /* Внутренняя тень снизу */
                0 2px 8px rgba(0, 0, 0, 0.15), /* Внешняя тень */
                0 0 0 1px rgba(255, 255, 255, 0.1); /* Тонкое свечение */
        }

        /* Когда есть кнопка отправки - корзина рядом с ней */
        .cart-button.with-send-button {
            right: 50px; /* Справа от кнопки отправки */
        }

        .cart-button.visible {
            display: flex;
        }

        .cart-button:hover {
            background: rgba(255, 255, 255, 0.25); /* Более яркий стеклянный эффект */
            border-color: rgba(255, 255, 255, 0.3);
            box-shadow:
                inset 0 1px 3px rgba(255, 255, 255, 0.4), /* Более яркий внутренний свет */
                inset 0 -1px 3px rgba(0, 0, 0, 0.15), /* Более глубокая внутренняя тень */
                0 4px 12px rgba(0, 0, 0, 0.2), /* Более выраженная внешняя тень */
                0 0 0 1px rgba(255, 255, 255, 0.2); /* Более яркое свечение */
            transform: translateY(-1px); /* Легкий подъем при наведении */
        }

        .cart-button:active {
            background: rgba(255, 255, 255, 0.1); /* Более темный при нажатии */
            transform: translateY(0); /* Возврат в исходное положение */
            box-shadow:
                inset 0 2px 4px rgba(0, 0, 0, 0.2), /* Внутренняя тень при нажатии */
                inset 0 -1px 2px rgba(255, 255, 255, 0.1), /* Свет снизу */
                0 1px 4px rgba(0, 0, 0, 0.1); /* Меньшая внешняя тень */
        }

        /* Иконка корзины */
        .cart-button svg {
            width: 16px;
            height: 16px;
            stroke: rgba(255, 255, 255, 0.9); /* Полупрозрачная белая иконка */
            fill: none; /* Убираем заливку, используем только stroke */
            filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.2)); /* Тень для иконки */
        }

        .cart-count {
            position: absolute;
            top: -6px;
            right: -6px;
            background: #007AFF;
            color: white;
            font-size: 10px;
            font-weight: 600;
            min-width: 16px;
            height: 16px;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            padding: 0 2px;
            box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
        }


        /* Модальные окна */
        .modal-overlay {
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: rgba(0, 0, 0, 0.5);
            display: none;
            align-items: center;
            justify-content: center;
            z-index: 2000;
            opacity: 0;
            transition: opacity 0.3s ease;
        }

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

        .modal {
            background: #2C2C2E;
            border-radius: 16px;
            box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
            padding: 0;
            min-width: 320px;
            max-width: 400px;
            max-height: 80vh;
            transform: scale(0.9);
            transition: transform 0.2s ease;
        }

        .modal-overlay.active .modal {
            transform: scale(1);
        }

        .modal-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 20px 20px 16px 20px;
            border-bottom: 1px solid #3A3A3C;
        }

        .modal-title {
            color: #FFFFFF;
            font-size: 18px;
            font-weight: 600;
        }

        .modal-close {
            background: none;
            border: none;
            color: #A0A0A0;
            cursor: pointer;
            padding: 6px;
            border-radius: 6px;
            transition: color 0.2s;
        }

        .modal-close:hover {
            color: #FFFFFF;
        }

        .modal-content {
            max-height: 60vh;
            overflow-y: auto;
            padding: 0;
        }

        .modal-item {
            padding: 12px 20px;
            color: #FFFFFF;
            cursor: pointer;
            transition: background 0.2s ease;
            font-size: 14px;
            border-bottom: 1px solid #3A3A3C;
        }

        .modal-item:last-child {
            border-bottom: none;
        }

        .modal-item:hover {
            background: rgba(255, 255, 255, 0.1);
        }

        /* Стили для корзины в модалке */
        .cart-empty {
            padding: 32px 20px;
            text-align: center;
            color: #A0A0A0;
            font-size: 14px;
        }

        .cart-item {
            display: flex;
            align-items: center;
            padding: 12px 20px;
            border-bottom: 1px solid #3A3A3C;
        }

        .cart-item:last-child {
            border-bottom: none;
        }

        .cart-item-image {
            width: 40px;
            height: 40px;
            object-fit: cover;
            border-radius: 8px;
            margin-right: 12px;
        }

        .cart-item-info {
            flex: 1;
            margin-right: 12px;
        }

        .cart-item-name {
            color: #FFFFFF;
            font-size: 14px;
            font-weight: 500;
            margin-bottom: 4px;
        }

        .cart-item-price {
            color: #A0A0A0;
            font-size: 12px;
        }

        .cart-item-quantity {
            display: flex;
            align-items: center;
            gap: 8px;
        }

        .quantity-btn {
            background: #3A3A3C;
            border: none;
            color: #FFFFFF;
            width: 24px;
            height: 24px;
            border-radius: 4px;
            cursor: pointer;
            font-size: 12px;
            transition: background 0.2s;
        }

        .quantity-btn:hover {
            background: #4A4A4C;
        }

        .quantity-input {
            background: #3A3A3C;
            border: none;
            color: #FFFFFF;
            width: 40px;
            height: 24px;
            text-align: center;
            border-radius: 4px;
            font-size: 12px;
        }

        .remove-item {
            background: #FF3B30;
            border: none;
            color: #FFFFFF;
            width: 24px;
            height: 24px;
            border-radius: 4px;
            cursor: pointer;
            font-size: 12px;
            transition: background 0.2s;
        }

        .remove-item:hover {
            background: #FF453A;
        }

        .cart-footer {
            padding: 20px;
            border-top: 1px solid #3A3A3C;
        }

        .cart-total {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 12px;
        }

        .cart-total-text {
            color: #A0A0A0;
            font-size: 14px;
        }

        .cart-total-amount {
            color: #FFFFFF;
            font-size: 16px;
            font-weight: 600;
        }

        .checkout-btn {
            width: 100%;
            background: #007AFF;
            border: none;
            color: #FFFFFF;
            padding: 12px;
            border-radius: 8px;
            font-size: 14px;
            font-weight: 600;
            cursor: pointer;
            transition: background 0.2s;
        }

        .checkout-btn:hover:not(:disabled) {
            background: #0056D6;
        }

        .checkout-btn:disabled {
            background: #3A3A3C;
            cursor: not-allowed;
        }

        .chat-input-container {
            padding: 0 20px 20px;
            background: #1C1C1E;
            border-top: 1px solid #2C2C2E;
            display: flex;
            align-items: flex-end; /* Выравниваем по нижнему краю */
            gap: 8px;
            min-height: 80px;
            margin-top: 3px;
            width: 100%; /* Полная ширина контейнера */
            max-width: 100%; /* Не выходим за границы */
            box-sizing: border-box; /* Учитываем padding в ширине */
            overflow: hidden; /* Скрываем переполнение */
        }

        /* Обертка для инпута и кнопки отправки */
        .input-wrapper {
            flex: 1;
            position: relative;
            display: flex;
            align-items: flex-end; /* Выравниваем по нижнему краю */
            min-width: 0; /* Позволяем сжиматься */
            max-width: calc(100% - 96px); /* Учитываем кнопки скрепки и микрофона (40px + 40px + 16px gap) */
        }

        /* Кнопка прикрепления файла */
        .attach-button {
            background: transparent;
            border: none;
            color: #8E8E93;
            cursor: pointer;
            padding: 8px;
            border-radius: 18px;
            display: flex;
            align-items: center;
            justify-content: center;
            transition: all 0.2s ease;
            flex-shrink: 0;
            width: 40px; /* Фиксированная ширина */
            height: 40px; /* Фиксированная высота */
            align-self: flex-end; /* Прижимаем к нижнему краю */
        }

        .attach-button:hover {
            background: rgba(255, 255, 255, 0.1);
            color: #007AFF;
        }

        .attach-button:active {
            transform: scale(0.95);
        }

        /* Кнопка микрофона */
        .mic-button {
            background: transparent;
            border: none;
            color: #8E8E93;
            cursor: pointer;
            padding: 8px;
            border-radius: 18px;
            display: flex;
            align-items: center;
            justify-content: center;
            transition: all 0.2s ease;
            flex-shrink: 0;
            width: 40px; /* Фиксированная ширина */
            height: 40px; /* Фиксированная высота */
            align-self: flex-end; /* Прижимаем к нижнему краю */
        }

        .mic-button:hover {
            background: rgba(255, 255, 255, 0.1);
            color: #007AFF;
        }

        .mic-button:active {
            transform: scale(0.95);
        }

        /* Состояние записи микрофона */
        .mic-button.recording {
            color: #FF3B30;
            background: rgba(255, 59, 48, 0.1);
            animation: pulse 1s infinite;
        }

        @keyframes pulse {
            0%, 100% { opacity: 1; }
            50% { opacity: 0.5; }
        }

        /* Стили сообщений */
        .message {
            max-width: 95%;
            border-radius: 18px;
            font-size: 14px;
            line-height: 1.4;
            padding: 12px 16px;
            animation: messageSlideIn 0.3s ease-out;
        }

        .message.user {
            background: #ff00ea;
            color: white;
            align-self: flex-end;
            border-bottom-right-radius: 4px;
        }

        .message.bot {
            background: #2C2C2E;
            color: white;
            align-self: flex-start;
            border-bottom-left-radius: 4px;
            display: flex;
            flex-direction: column;
            gap: 8px;
        }

        .message.bot .avatar {
            flex-shrink: 0;
            width: 32px;
            height: 32px;
            background: linear-gradient(135deg, #FF69B4, #FF1493);
            border-radius: 16px;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 16px;
            box-shadow: 0 2px 8px rgba(255, 105, 180, 0.4);
        }

        .message.bot .content {
            flex: 1;
            transition: none;
            will-change: auto;
        }

        /* Плавное обновление контента при печати */
        .message.bot .content * {
            transition: none;
        }

        .message.bot .content h1,
        .message.bot .content h2,
        .message.bot .content h3,
        .message.bot .content h4,
        .message.bot .content p,
        .message.bot .content ul,
        .message.bot .content li,
        .message.bot .content strong,
        .message.bot .content em {
            transition: none;
        }

        .message-actions {
            display: none;
            flex-direction: row;
            gap: 8px;
            margin-top: 8px;
            margin-left: 44px; /* Отступ от аватара */
            transition: all 0.3s ease;
        }

        .message-actions.visible {
            display: flex;
        }

        .message-action-btn {
            width: 32px;
            height: 32px;
            background: rgba(255, 255, 255, 0.1);
            border: none;
            border-radius: 8px;
            color: #FFFFFF;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            transition: all 0.2s ease;
            font-size: 14px;
        }

        .message-action-btn:hover {
            background: rgba(255, 255, 255, 0.2);
            transform: scale(1.05);
        }

        .message-action-btn:active {
            transform: scale(0.95);
        }

        .message.typing {
            background: #2C2C2E;
            color: #8E8E93;
            align-self: flex-start;
            border-bottom-left-radius: 4px;
        }

        .typing-indicator {
            display: flex;
            gap: 4px;
            padding: 8px 0;
        }

        .typing-dot {
            width: 6px;
            height: 6px;
            background: #8E8E93;
            border-radius: 50%;
            animation: typing 1.4s infinite ease-in-out;
        }

        .typing-dot:nth-child(2) { animation-delay: 0.2s; }
        .typing-dot:nth-child(3) { animation-delay: 0.4s; }

        .chat-input {
            flex: 1;
            background: #2C2C2E;
            border: none;
            border-radius: 20px;
            padding: 10px 14px; /* Уменьшаем padding */
            padding-right: 50px; /* Место для кнопки отправки */
            padding-left: 20px; /* Место для кнопки скрепки */
            color: white;
            font-size: 13px; /* Уменьшаем размер шрифта */
            outline: none;
            resize: none;
            min-height: 18px; /* Уменьшаем минимальную высоту */
            max-height: 120px;
            overflow-y: auto;
            line-height: 1.9; /* Уменьшаем межстрочный интервал */
            font-family: -apple-system, BlinkMacSystemFont, sans-serif;
            min-width: 0;
            margin-top: 3px;
        }

        /* Когда есть кнопка корзины - увеличиваем padding справа */
        .chat-input.with-cart-button {
            padding-right: 90px; /* Место для кнопки отправки + корзины */
        }

        .chat-input::placeholder {
            color: #8E8E93;
            font-size: 14px; /* Уменьшаем размер шрифта плейсхолдера */
            font-weight: 400;
        }

        .send-button {
            position: absolute;
            right: 8px;
            bottom: 8px; /* Фиксируем к нижнему краю инпута */
            width: 32px;
            height: 32px;
            background: rgba(255, 255, 255, 0.15); /* Полупрозрачный белый */
            backdrop-filter: blur(10px); /* Эффект размытия стекла */
            border: 1px solid rgba(255, 255, 255, 0.2); /* Тонкая светлая граница */
            border-radius: 18px;
            display: none; /* Скрыта по умолчанию */
            align-items: center;
            justify-content: center;
            cursor: pointer;
            transition: all 0.3s ease;
            flex-shrink: 0;
            z-index: 10;
            box-shadow:
                inset 0 1px 2px rgba(255, 255, 255, 0.3), /* Внутренний свет сверху */
                inset 0 -1px 2px rgba(0, 0, 0, 0.1), /* Внутренняя тень снизу */
                0 2px 8px rgba(0, 0, 0, 0.15), /* Внешняя тень */
                0 0 0 1px rgba(255, 255, 255, 0.1); /* Тонкое свечение */
        }

        .send-button.visible {
            display: flex;
        }

        .send-button:hover {
            background: rgba(255, 255, 255, 0.25); /* Более яркий стеклянный эффект */
            border-color: rgba(255, 255, 255, 0.3);
            box-shadow:
                inset 0 1px 3px rgba(255, 255, 255, 0.4), /* Более яркий внутренний свет */
                inset 0 -1px 3px rgba(0, 0, 0, 0.15), /* Более глубокая внутренняя тень */
                0 4px 12px rgba(0, 0, 0, 0.2), /* Более выраженная внешняя тень */
                0 0 0 1px rgba(255, 255, 255, 0.2); /* Более яркое свечение */
            transform: translateY(-1px); /* Легкий подъем при наведении */
        }

        .send-button:active {
            background: rgba(255, 255, 255, 0.1); /* Более темный при нажатии */
            transform: translateY(0); /* Возврат в исходное положение */
            box-shadow:
                inset 0 2px 4px rgba(0, 0, 0, 0.2), /* Внутренняя тень при нажатии */
                inset 0 -1px 2px rgba(255, 255, 255, 0.1), /* Свет снизу */
                0 1px 4px rgba(0, 0, 0, 0.1); /* Меньшая внешняя тень */
        }

        .send-button svg {
            width: 18px;
            height: 18px;
            stroke: rgba(255, 255, 255, 0.9); /* Полупрозрачная белая иконка */
            fill: none; /* Убираем заливку, используем только stroke */
            filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.2)); /* Тень для иконки */
        }

        /* Анимации */
        @keyframes messageSlideIn {
            from {
                opacity: 0;
                transform: translateY(20px);
            }
            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        @keyframes typing {
            0%, 60%, 100% {
                transform: translateY(0);
            }
            30% {
                transform: translateY(-10px);
            }
        }

        /* Мобильные устройства - полный экран */
        @media (max-width: 768px) {
            .phone-container {
                width: 100vw;
                height: 100vh;
                border-radius: 0;
                padding: 0;
                box-shadow: none;
                max-height: 100vh;
            }

            .phone-screen {
                border-radius: 0;
            }

            .chat-messages {
                padding: 16px;
                padding-top: 50px; /* Отступ сверху для мобильных */
            }

            .chat-input-container {
                padding: 16px;
                align-items: flex-end; /* Выравниваем по нижнему краю на мобильных */
                width: 100%;
                max-width: 100%;
                box-sizing: border-box;
            }

            .phone-notch {
                display: none;
            }
        }

        /* Планшеты и десктопы - центрированный телефон */
        @media (min-width: 769px) {
            body {
                padding: 20px;
            }

            .phone-container {
                width: 420px;
                height: min(812px, 100vh - 40px);
                border-radius: 40px;
                padding: 12px;
                box-shadow: 0 20px 60px rgba(0,0,0,0.3);
                max-height: calc(100vh - 40px);
                resize: horizontal;
                overflow: auto;
                min-width: 420px;
                max-width: 800px;
                position: relative;
            }

            .phone-container::after {
                content: '⋮⋮';
                position: absolute;
                right: 2px;
                top: 50%;
                transform: translateY(-50%);
                width: 12px;
                height: 40px;
                background: linear-gradient(45deg, #007AFF, #5AC8FA);
                border-radius: 6px 0 0 6px;
                opacity: 0.6;
                transition: all 0.3s ease;
                display: flex;
                align-items: center;
                justify-content: center;
                font-size: 8px;
                color: white;
                font-weight: bold;
                letter-spacing: 1px;
                cursor: ew-resize;
                z-index: 10;
            }

            .phone-container::before {
                content: '⋮⋮';
                position: absolute;
                left: 2px;
                top: 50%;
                transform: translateY(-50%);
                width: 12px;
                height: 40px;
                background: linear-gradient(45deg, #FF3B30, #FF9500);
                border-radius: 0 6px 6px 0;
                opacity: 0.6;
                transition: all 0.3s ease;
                display: flex;
                align-items: center;
                justify-content: center;
                font-size: 8px;
                color: white;
                font-weight: bold;
                letter-spacing: 1px;
                cursor: ew-resize;
                z-index: 10;
            }

            .phone-container:hover::after {
                opacity: 1;
                background: linear-gradient(45deg, #0056CC, #007AFF);
                transform: translateY(-50%) scale(1.1);
            }

            .phone-container:hover::before {
                opacity: 1;
                background: linear-gradient(45deg, #D70015, #FF6B00);
                transform: translateY(-50%) scale(1.1);
            }

            .phone-screen {
                border-radius: 30px;
            }

            .phone-notch {
                display: block;
            }

            .chat-input-container {
                padding: 0 20px 20px;
                min-height: 80px;
            }
        }

        /* Планшетный режим - когда телефон растянут */
        .phone-container.tablet-mode {
            width: 600px !important;
            max-width: 800px;
            border-radius: 20px;
        }

        .phone-container.tablet-mode .phone-screen {
            border-radius: 15px;
        }

        .phone-container.tablet-mode .phone-notch {
            display: none;
        }

        /* Планшетный режим - 3 ряда товаров */
        .phone-container.tablet-mode .products-grid {
            grid-template-columns: repeat(3, 1fr);
            gap: 12px;
        }

        .phone-container.tablet-mode .product-card {
            min-height: 120px;
        }

        .phone-container.tablet-mode .product-image {
            height: 60px;
        }

        .phone-container.tablet-mode .product-name {
            font-size: 12px;
            line-height: 1.3;
        }

        .phone-container.tablet-mode .product-price {
            font-size: 14px;
        }

        /* Планшетный режим - корзина */
        .phone-container.tablet-mode .cart-items {
            grid-template-columns: repeat(3, 1fr);
            gap: 12px;
        }

        .phone-container.tablet-mode .cart-item {
            min-height: 100px;
        }

        .phone-container.tablet-mode .cart-item-image {
            height: 50px;
        }

        .phone-container.tablet-mode .cart-item-name {
            font-size: 12px;
        }

        .phone-container.tablet-mode .cart-item-price {
            font-size: 14px;
        }

        /* Индикатор для сжатия обратно в телефон */
        .phone-container.tablet-mode::after {
            content: '⋮⋮';
            background: linear-gradient(45deg, #FF3B30, #FF9500);
            opacity: 0.8;
        }

        .phone-container.tablet-mode:hover::after {
            background: linear-gradient(45deg, #D70015, #FF6B00);
            transform: translateY(-50%) scale(1.1);
        }

        /* Большие экраны */
        @media (min-width: 1440px) {
            body {
                padding: 40px;
            }

            .phone-container {
                width: 480px;
                height: min(900px, 100vh - 80px);
                border-radius: 50px;
                padding: 16px;
                box-shadow: 0 30px 80px rgba(0,0,0,0.4);
                max-height: calc(100vh - 80px);
            }

            .phone-screen {
                border-radius: 40px;
            }

            .phone-notch {
                width: 200px;
                height: 30px;
            }

            .chat-input-container {
                padding: 0 20px 20px;
                min-height: 80px;
            }
        }

        /* iOS оптимизации */
        @supports (-webkit-touch-callout: none) {
            .chat-input-container {
                transform: translateZ(0);
                -webkit-transform: translateZ(0);
            }

            .chat-input:focus {
                font-size: 15px !important; /* Уменьшаем размер при фокусе */
            }

            .send-button {
                backdrop-filter: blur(10px);
                -webkit-backdrop-filter: blur(10px);
            }

            .cart-button {
                backdrop-filter: blur(10px);
                -webkit-backdrop-filter: blur(10px);
            }

            .stop-generation-button {
                backdrop-filter: blur(10px);
                -webkit-backdrop-filter: blur(10px);
            }
        }

        /* Поддержка для устройств без backdrop-filter */
        @supports not (backdrop-filter: blur(10px)) {
            .send-button {
                background: rgba(255, 255, 255, 0.2) !important;
                border: 1px solid rgba(255, 255, 255, 0.3);
            }

            .send-button:hover {
                background: rgba(255, 255, 255, 0.3) !important;
            }

            .send-button:active {
                background: rgba(255, 255, 255, 0.1) !important;
            }

            .cart-button {
                background: rgba(255, 255, 255, 0.2) !important;
                border: 1px solid rgba(255, 255, 255, 0.3);
            }

            .cart-button:hover {
                background: rgba(255, 255, 255, 0.3) !important;
            }

            .cart-button:active {
                background: rgba(255, 255, 255, 0.1) !important;
            }

            .stop-generation-button {
                background: rgba(255, 59, 48, 0.8) !important;
                border: 1px solid rgba(255, 59, 48, 0.5);
            }

            .stop-generation-button:hover {
                background: rgba(255, 69, 58, 0.9) !important;
            }

            .stop-generation-button:active {
                background: rgba(215, 0, 21, 0.8) !important;
            }
        }

        /* Активная клавиатура */
        .keyboard-active .chat-messages {
            padding-bottom: 120px !important;
        }

        .keyboard-active .chat-input-container {
            position: fixed;
            bottom: 0;
            left: 0;
            right: 0;
            z-index: 1000;
        }

        /* Горизонтальная ориентация мобильных */
        @media (max-height: 500px) and (orientation: landscape) {
            .chat-messages {
                padding: 8px;
                padding-top: 40px; /* Отступ сверху для очень маленьких экранов */
            }

            .chat-input-container {
                padding: 8px;
                min-height: 60px;
                width: 100%;
                max-width: 100%;
                box-sizing: border-box;
            }

            .message {
                font-size: 14px;
            }
        }

        /* Стили для секции товаров */
        .products-section {
            margin: 16px 0;
            background: rgba(255, 255, 255, 0.35);
            border-radius: 16px;
            padding: 16px;
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
        }

        .products-header {
            display: flex;
            align-items: center;
            gap: 8px;
            margin-bottom: 16px;
            font-weight: 600;
            color: #333;
        }

        .shopping-cart-icon {
            font-size: 18px;
        }

        .products-title {
            font-size: 14px;
            line-height: 1.4;
        }

        /* Стили для категорий товаров */
        .product-category {
            margin-bottom: 16px;
        }

        .category-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 12px 16px;
            background: hwb(0 81% 19% / 0.797);
            border-radius: 12px;
            cursor: pointer;
            transition: background 0.2s;
            font-weight: 600;
            color: #333;
        }

        .category-header:hover {
            background: #e9ecef;
        }

        .category-name {
            font-size: 14px;
        }

        .category-arrow {
            font-size: 12px;
            transition: transform 0.2s;
        }

        /* Сетка товаров */
        .products-grid {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 12px;
            margin-top: 12px;
            padding: 0 4px;
        }

        /* Карточка товара */
        .product-card {
            background: white;
            border-radius: 12px;
            padding: 12px;
            box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
            transition: transform 0.2s, box-shadow 0.2s;
        }

        .product-card:hover {
            transform: translateY(-2px);
            box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
        }

        .product-image {
            position: relative;
            margin-bottom: 8px;
        }

        .product-image img {
            width: 100%;
            height: 80px;
            object-fit: cover;
            border-radius: 8px;
        }

        .favorite-btn {
            position: absolute;
            top: 4px;
            right: 4px;
            background: rgba(255, 255, 255, 0.9);
            border: none;
            border-radius: 50%;
            width: 24px;
            height: 24px;
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            font-size: 12px;
        }

        .product-info {
            text-align: left;
        }

        .product-rating {
            font-size: 12px;
            color: #ff9500;
            font-weight: 600;
            margin-bottom: 4px;
        }

        .product-name {
            font-size: 12px;
            font-weight: 600;
            color: #333;
            margin-bottom: 4px;
            line-height: 1.3;
            display: -webkit-box;
            -webkit-line-clamp: 2;
            line-clamp: 2;
            -webkit-box-orient: vertical;
            overflow: hidden;
        }

        .product-weight {
            font-size: 11px;
            color: #666;
            margin-bottom: 6px;
        }

        .product-price {
            font-size: 14px;
            font-weight: 700;
            color: #007AFF;
            margin-bottom: 8px;
        }

        .product-price-cart {
            display: flex;
            justify-content: space-between;
            align-items: center;
            gap: 8px;
        }

        .product-price-only {
            font-size: 14px;
            font-weight: 700;
            color: #007AFF;
        }

        .add-to-cart-btn {
            background: #007AFF;
            color: white;
            border: none;
            border-radius: 8px;
            padding: 6px 12px;
            font-size: 11px;
            font-weight: 600;
            cursor: pointer;
            transition: background 0.2s;
            white-space: nowrap;
        }

        .add-to-cart-btn:hover {
            background: #0056b3;
        }

        /* Стили для быстрых вопросов */
        .quick-questions-section {
            margin: 16px 0;
            background: rgba(255, 255, 255, 0.95);
            border-radius: 16px;
            padding: 16px;
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
        }

        .quick-questions-header {
            display: flex;
            align-items: center;
            gap: 8px;
            margin-bottom: 12px;
            font-weight: 600;
            color: #333;
        }

        .lightbulb-icon {
            font-size: 16px;
        }

        .quick-questions-title {
            font-size: 14px;
            line-height: 1.4;
        }

        /* Стили для корзины как сообщения в чате */
        .cart-message {
            background: #F8F9FA;
            border: 1px solid #E9ECEF;
            border-radius: 16px;
            padding: 16px;
            margin: 8px 0;
        }

        .cart-header {
            display: flex;
            align-items: center;
            gap: 8px;
            margin-bottom: 12px;
            font-weight: 600;
            color: #333;
        }

        .cart-icon {
            font-size: 16px;
        }

        .cart-title {
            font-size: 14px;
            line-height: 1.4;
        }

        .cart-items-list {
            margin-bottom: 12px;
        }

        .cart-item {
            display: flex;
            align-items: center;
            gap: 12px;
            padding: 12px 0;
            border-bottom: 1px solid #E9ECEF;
        }

        .cart-item:last-child {
            border-bottom: none;
        }

        .cart-item-image {
            flex-shrink: 0;
        }

        .cart-item-image img {
            width: 40px;
            height: 40px;
            border-radius: 8px;
            object-fit: cover;
        }

        .cart-item-info {
            flex: 1;
            min-width: 0;
        }

        .cart-item-name {
            font-weight: 500;
            color: #333;
            font-size: 14px;
            margin-bottom: 2px;
            line-height: 1.3;
        }

        .cart-item-details {
            color: #666;
            font-size: 12px;
        }

        .cart-item-controls {
            display: flex;
            align-items: center;
            gap: 6px;
            flex-shrink: 0;
        }


        .cart-quantity-input {
            width: 40px;
            height: 24px;
            border: 1px solid #D1D5DB;
            border-radius: 4px;
            text-align: center;
            font-size: 12px;
            font-weight: 500;
            color: #374151;
            background: #FFFFFF;
        }

        .cart-quantity-input:focus {
            outline: none;
            border-color: #007AFF;
            box-shadow: 0 0 0 2px rgba(0, 122, 255, 0.1);
        }

        .cart-remove-btn {
            width: 24px;
            height: 24px;
            border: 1px solid #EF4444;
            background: #FFFFFF;
            border-radius: 4px;
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            font-size: 14px;
            font-weight: 600;
            color: #EF4444;
            transition: all 0.2s ease;
        }

        .cart-remove-btn:hover {
            background: #FEF2F2;
            border-color: #DC2626;
        }

        .cart-remove-btn:active {
            background: #FEE2E2;
        }

        .cart-total {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding-top: 8px;
            border-top: 1px solid #E9ECEF;
            font-weight: 600;
            color: #333;
        }

        .cart-total-text {
            font-size: 14px;
        }

        .cart-total-amount {
            font-size: 16px;
            color: #007AFF;
        }

        /* Кнопка оформления заказа в корзине */
        .cart-checkout-btn {
            width: 100%;
            background: #007AFF;
            color: white;
            border: none;
            border-radius: 12px;
            padding: 12px 16px;
            font-size: 14px;
            font-weight: 600;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
            margin-top: 12px;
            transition: all 0.2s ease;
        }

        .cart-checkout-btn:hover {
            background: #0056CC;
            transform: translateY(-1px);
        }

        .cart-checkout-btn:active {
            background: #004499;
            transform: translateY(0);
        }

        .cart-checkout-icon {
            font-size: 16px;
        }

        .cart-checkout-text {
            font-size: 14px;
        }

        /* Стили для формы оформления заказа */
        .checkout-message {
            background: #F8F9FA;
            border: 1px solid #E9ECEF;
            border-radius: 16px;
            padding: 16px;
            margin: 8px 0;
        }

        .checkout-header {
            display: flex;
            align-items: center;
            gap: 8px;
            margin-bottom: 16px;
            font-weight: 600;
            color: #333;
        }

        .checkout-icon {
            font-size: 16px;
        }

        .checkout-title {
            font-size: 14px;
            line-height: 1.4;
        }

        .checkout-form {
            margin-bottom: 16px;
        }

        .checkout-field {
            margin-bottom: 12px;
        }

        .checkout-label {
            display: block;
            font-size: 12px;
            font-weight: 500;
            color: #666;
            margin-bottom: 4px;
        }

        .checkout-input,
        .checkout-textarea {
            width: 100%;
            padding: 8px 12px;
            border: 1px solid #D1D5DB;
            border-radius: 8px;
            font-size: 14px;
            color: #333;
            background: white;
            transition: border-color 0.2s ease;
        }

        .checkout-input:focus,
        .checkout-textarea:focus {
            outline: none;
            border-color: #007AFF;
            box-shadow: 0 0 0 2px rgba(0, 122, 255, 0.1);
        }

        .checkout-textarea {
            resize: vertical;
            min-height: 60px;
        }

        .order-items {
            background: white;
            border: 1px solid #E9ECEF;
            border-radius: 8px;
            padding: 12px;
            margin-bottom: 16px;
        }

        .order-items-title {
            font-size: 14px;
            font-weight: 600;
            color: #333;
            margin-bottom: 8px;
        }

        .order-item {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 4px 0;
            border-bottom: 1px solid #F3F4F6;
        }

        .order-item:last-child {
            border-bottom: none;
        }

        .order-item-name {
            flex: 1;
            font-size: 13px;
            color: #333;
        }

        .order-item-quantity {
            font-size: 12px;
            color: #666;
            margin: 0 8px;
        }

        .order-item-price {
            font-size: 13px;
            font-weight: 500;
            color: #333;
        }

        .order-total {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding-top: 8px;
            border-top: 1px solid #E9ECEF;
            font-weight: 600;
            color: #333;
            margin-top: 8px;
        }

        .order-total-text {
            font-size: 14px;
        }

        .order-total-amount {
            font-size: 16px;
            color: #007AFF;
        }

        .checkout-buttons {
            display: flex;
            gap: 8px;
        }

        .checkout-cancel-btn {
            flex: 1;
            background: #F3F4F6;
            color: #666;
            border: none;
            border-radius: 8px;
            padding: 10px 16px;
            font-size: 14px;
            font-weight: 500;
            cursor: pointer;
            transition: all 0.2s ease;
        }

        .checkout-cancel-btn:hover {
            background: #E5E7EB;
        }

        .checkout-submit-btn {
            flex: 2;
            background: #007AFF;
            color: white;
            border: none;
            border-radius: 8px;
            padding: 10px 16px;
            font-size: 14px;
            font-weight: 600;
            cursor: pointer;
            transition: all 0.2s ease;
        }

        .checkout-submit-btn:hover {
            background: #0056CC;
        }

        .quick-questions-buttons {
            display: flex;
            flex-direction: column;
            gap: 8px;
        }

        .quick-questions-loading {
            display: flex;
            align-items: center;
            gap: 8px;
            padding: 12px;
            color: #666;
            font-size: 14px;
        }

        .loading-spinner {
            width: 16px;
            height: 16px;
            border: 2px solid #f3f3f3;
            border-top: 2px solid #007AFF;
            border-radius: 50%;
            animation: spin 1s linear infinite;
        }

        @keyframes spin {
            0% { transform: rotate(0deg); }
            100% { transform: rotate(360deg); }
        }

        /* Анимация бегущих точек */
        .quick-questions-loading-dots {
            display: flex;
            justify-content: center;
            align-items: center;
            padding: 8px;
            color: #666;
            font-size: 16px;
            font-weight: 500;
        }

        .dot {
            animation: loadingDots 1.4s infinite ease-in-out;
        }

        .dot:nth-child(1) { animation-delay: -0.32s; }
        .dot:nth-child(2) { animation-delay: -0.16s; }
        .dot:nth-child(3) { animation-delay: 0s; }

        @keyframes loadingDots {
            0%, 80%, 100% {
                opacity: 0.3;
                transform: scale(0.8);
            }
            40% {
                opacity: 1;
                transform: scale(1);
            }
        }

        /* Стили для блоков кода */
        .code-block {
            background: #f8f9fa;
            border: 1px solid #e9ecef;
            border-radius: 8px;
            padding: 12px 16px;
            margin: 8px 0;
            font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Roboto Mono', monospace;
            font-size: 13px;
            line-height: 1.4;
            color: #333;
            white-space: pre-wrap; /* Перенос строк с сохранением форматирования */
            max-width: 100%;
            width: 100%;
            box-sizing: border-box;
            overflow: hidden; /* Убираем скролл */
            position: relative;
            display: block;
            word-break: break-word; /* Перенос длинных слов */
            overflow-wrap: break-word; /* Перенос длинных слов */
            /* КРИТИЧЕСКИ ВАЖНО: предотвращаем выход за границы */
            min-width: 0;
            flex-shrink: 1;
        }

        /* СТРОГАЯ защита от выхода за границы */
        .message .content .code-block {
            max-width: calc(100% - 32px) !important; /* Учитываем отступы сообщения */
            margin-left: 0 !important;
            margin-right: 0 !important;
            width: calc(100% - 32px) !important;
        }

        /* Защита на уровне контейнера сообщения */
        .message .content {
            overflow: hidden;
            word-wrap: break-word;
            max-width: 100%;
        }

        /* Защита на уровне phone-container */
        .phone-container {
            overflow: hidden;
            max-width: 100%;
        }

        /* Для очень маленьких экранов */
        @media (max-width: 480px) {
            .code-block {
                font-size: 12px;
                padding: 10px 12px;
                margin: 6px 0;
                max-width: calc(100% - 24px) !important;
                width: calc(100% - 24px) !important;
            }
            
            .message .content .code-block {
                max-width: calc(100% - 24px) !important;
                width: calc(100% - 24px) !important;
            }

            /* Уменьшаем размеры кнопок на очень маленьких экранах */
            .attach-button,
            .mic-button {
                width: 36px;
                height: 36px;
                padding: 6px;
            }

            .input-wrapper {
                max-width: calc(100% - 88px); /* Учитываем уменьшенные кнопки */
            }

            /* Еще более компактный плейсхолдер на маленьких экранах */
            .chat-input {
                font-size: 14px;
                padding: 8px 12px;
                padding-right: 80px; /* Место для кнопок на маленьких экранах */
            }

            .chat-input::placeholder {
                font-size: 13px;
            }
        }


        .inline-code {
            background: #f1f3f4;
            border-radius: 3px;
            padding: 2px 6px;
            font-family: 'SF Mono', 'Monaco', 'Inconsolata', 'Roboto Mono', monospace;
            font-size: 12px;
            color: #d73a49;
            border: 1px solid #e1e4e8;
        }

        .quick-question-btn {
            background: #f8f9fa;
            border: 1px solid #e9ecef;
            border-radius: 20px;
            padding: 10px 16px;
            font-size: 13px;
            color: #333;
            cursor: pointer;
            transition: all 0.2s;
            text-align: left;
        }

        .quick-question-btn:hover {
            background: #e9ecef;
            border-color: #007AFF;
            color: #007AFF;
        }

        /* Стили для markdown в сообщениях */
        .message .content h1,
        .message .content h2,
        .message .content h3,
        .message .content h4 {
            margin: 6px 0 2px 0;
            font-weight: 700;
            color: #1a1a1a;
            line-height: 1.3;
        }

        .message .content h1 {
            font-size: 18px;
            color: #ffffff;
        }

        .message .content h2 {
            font-size: 16px;
            color: #ffffff;
        }

        .message .content h3 {
            font-size: 15px;
            color: #ffffff;
        }

        .message .content h4 {
            font-size: 14px;
            color: #ffffff;
        }

        .message .content strong {
            font-weight: 700;
            color: #ffffff;
        }

        .message .content em {
            font-style: italic;
            color: #ffffff;
        }

        .message .content ul {
            margin: 4px 0;
            padding-left: 20px;
        }

        .message .content li {
            margin: 2px 0;
            line-height: 1.4;
            color: #ffffff;
        }

        .message .content ul li {
            list-style-type: disc;
        }

        /* Уменьшаем отступы между абзацами */
        .message .content br {
            line-height: 1.2;
        }

        /* Ограничиваем отступы от множественных <br> */
        .message .content br + br {
            margin-top: 0;
        }

        /* Убираем лишние отступы от <br> тегов */
        .message .content {
            line-height: 1.4;
        }

        /* Стили для индикатора загрузки товаров */
        .message.loading-products {
            background: rgba(0, 122, 255, 0.1);
            border-left: 3px solid #007AFF;
        }

        .message.loading-products .content {
            color: #007AFF;
            font-style: italic;
        }

        /* Адаптивность для мобильных устройств */
        @media (max-width: 480px) {
            .products-grid {
                grid-template-columns: 1fr 1fr;
                gap: 8px;
            }

            .product-card {
                padding: 8px;
            }

            .product-image img {
                height: 80px;
            }

            .product-name {
                font-size: 11px;
                line-height: 1.2;
            }

            .product-price {
                font-size: 13px;
            }

            .product-weight {
                font-size: 10px;
            }
        }

        /* Очень маленькие экраны - минимум 2 колонки */
        @media (max-width: 360px) {
            .products-grid {
                grid-template-columns: 1fr 1fr;
                gap: 6px;
            }

            .product-card {
                padding: 6px;
            }

            .product-image img {
                height: 70px;
            }

            .product-name {
                font-size: 10px;
                line-height: 1.1;
            }

            .product-price {
                font-size: 12px;
            }

            .product-weight {
                font-size: 9px;
            }

            .product-rating {
                font-size: 10px;
            }
        }

        /* Экстремально маленькие экраны - все равно 2 колонки */
        @media (max-width: 320px) {
            .products-grid {
                grid-template-columns: 1fr 1fr;
                gap: 4px;
            }

            .product-card {
                padding: 4px;
            }

            .product-image img {
                height: 60px;
            }

            .product-name {
                font-size: 9px;
                line-height: 1.0;
            }

            .product-price {
                font-size: 11px;
            }

            .product-weight {
                font-size: 8px;
            }

            .product-rating {
                font-size: 9px;
            }
        }

        /* Стили для блока предложений в корзине */
        .cart-suggestions-section {
            margin-top: 16px;
            background: rgba(255, 255, 255, 0.95);
            border-radius: 16px;
            padding: 16px;
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
        }

        .cart-suggestions-header {
            display: flex;
            align-items: center;
            gap: 8px;
            margin-bottom: 12px;
            font-weight: 600;
            color: #333;
        }

        .cart-suggestions-title {
            font-size: 14px;
            line-height: 1.4;
        }

        .cart-suggestions-buttons {
            display: flex;
            flex-direction: column;
            gap: 8px;
        }

        .cart-suggestion-btn {
            background: #f8f9fa;
            border: 1px solid #e9ecef;
            border-radius: 20px;
            padding: 10px 16px;
            font-size: 13px;
            color: #333;
            cursor: pointer;
            transition: all 0.2s;
            text-align: left;
        }

        .cart-suggestion-btn:hover {
            background: #e9ecef;
            border-color: #007AFF;
            color: #007AFF;
        }

        .cart-suggestion-content {
            display: flex;
            flex-direction: column;
            gap: 4px;
            text-align: left;
        }

        .cart-suggestion-text {
            font-size: 13px;
            font-weight: 500;
            color: #333;
        }

        .cart-suggestion-missing {
            display: flex;
            flex-direction: column;
            gap: 2px;
            font-size: 11px;
            color: #666;
        }

        .missing-label {
            font-weight: 500;
            color: #FF6B35;
        }

        .missing-items {
            color: #666;
            font-style: italic;
        }

        .cart-suggestions-loading-dots {
            display: flex;
            justify-content: center;
            align-items: center;
            padding: 8px;
            color: #666;
            font-size: 16px;
            font-weight: 500;
        }

        /* Мобильная версия модальных окон */
        @media (max-width: 768px) {
            .modal {
                min-width: 300px;
                max-width: calc(100vw - 40px);
                max-height: calc(100vh - 40px);
            }
        }
