/* ============================================================================
   HOME PAGE - МОБИЛЬНЫЕ СТИЛИ
   Стили только для мобильных устройств (max-width: 768px)
   ============================================================================ */

@media (max-width: 768px) {
    /* ============================================================================
       НАВИГАЦИЯ - УНИФИКАЦИЯ СЭНДВИЧ-МЕНЮ
       ============================================================================ */
    
    /* Унификация навигации для всех языковых версий */
    .navbar {
        padding: 0.5rem 1rem !important;
        min-height: 60px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        flex-wrap: nowrap !important;
    }
    
    .navbar .container {
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        width: 100% !important;
        padding: 0 !important;
        flex-wrap: nowrap !important;
    }
    
    /* Логотип - фиксированная ширина */
    .navbar-brand {
        display: flex !important;
        align-items: center !important;
        margin-right: 0 !important;
        padding: 0 !important;
        flex-shrink: 0 !important;
        max-width: 60% !important;
        overflow: hidden !important;
    }
    
    .navbar-brand img {
        height: 32px !important;
        width: auto !important;
        flex-shrink: 0 !important;
    }
    
    .navbar-brand span,
    .navbar-brand {
        font-size: 14px !important;
        font-weight: 600 !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        max-width: 200px !important;
    }
    
    /* Сэндвич-меню - всегда справа */
    .navbar-toggler {
        order: 3 !important;
        margin-left: auto !important;
        margin-right: 0 !important;
        padding: 0.5rem !important;
        min-height: 44px !important;
        min-width: 44px !important;
        border: 1px solid #dee2e6 !important;
        border-radius: 8px !important;
        background-color: #f8f9fa !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        flex-shrink: 0 !important;
    }
    
    .navbar-toggler:focus {
        box-shadow: 0 0 0 0.2rem rgba(59, 130, 246, 0.25) !important;
        outline: none !important;
    }
    
    .navbar-toggler-icon {
        width: 20px !important;
        height: 2px !important;
        background-color: #6c757d !important;
        position: relative !important;
        display: block !important;
    }
    
    .navbar-toggler-icon::before,
    .navbar-toggler-icon::after {
        content: '' !important;
        position: absolute !important;
        width: 20px !important;
        height: 2px !important;
        background-color: #6c757d !important;
        left: 0 !important;
    }
    
    .navbar-toggler-icon::before {
        top: -6px !important;
    }
    
    .navbar-toggler-icon::after {
        bottom: -6px !important;
    }
    
    /* Скрываем навигационные элементы на мобильных */
    .navbar-collapse {
        position: absolute !important;
        top: 100% !important;
        left: 0 !important;
        right: 0 !important;
        background: white !important;
        border-top: 1px solid #dee2e6 !important;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1) !important;
        z-index: 1000 !important;
        max-height: 70vh !important;
        overflow-y: auto !important;
    }
    
    /* Принудительное расположение элементов */
    .navbar > .container > * {
        flex-shrink: 0 !important;
    }
    
    .navbar > .container > .navbar-brand {
        flex: 1 1 auto !important;
        margin-right: 1rem !important;
    }
    
    .navbar > .container > .navbar-toggler {
        flex: 0 0 auto !important;
        margin-left: 0 !important;
    }
    
    /* Предотвращение переноса элементов */
    .navbar .container {
        flex-wrap: nowrap !important;
        overflow: hidden !important;
    }
    
    /* ============================================================================
       HERO SECTION - МОБИЛЬНАЯ ВЕРСИЯ
       ============================================================================ */
    
    .hero-section {
        min-height: 400px !important;
        padding: 2rem 0 !important;
    }
    
    .hero-title {
        font-size: 2.5rem !important;
        line-height: 1.2 !important;
    }
    
    .hero-description {
        font-size: 1.1rem !important;
        line-height: 1.5 !important;
    }
    
    .hero-image {
        min-height: 300px !important;
        margin-top: 1rem !important;
    }
    
    .hero-chat-demo {
        max-width: 100% !important;
        min-height: 280px !important;
        margin: 0 10px !important;
    }
    
    /* Обеспечиваем горизонтальное расположение точек в мобильной версии */
    .hero-chat-demo .window-controls,
    .hero-chat-demo .d-flex.window-controls,
    .hero-chat-demo .window-controls.d-flex,
    .hero-section .hero-chat-demo .window-controls,
    .hero-section .hero-chat-demo .d-flex.window-controls,
    .hero-section .hero-chat-demo .window-controls.d-flex {
        flex-direction: row !important;
        justify-content: flex-start !important;
        align-items: center !important;
        display: flex !important;
        flex-wrap: nowrap !important;
    }
    
    .hero-chat-demo .window-controls .dot,
    .hero-chat-demo .dot,
    .hero-chat-demo .window-controls .bg-danger,
    .hero-chat-demo .window-controls .bg-warning,
    .hero-chat-demo .window-controls .bg-success {
        width: 8px !important;
        height: 8px !important;
        margin-right: 4px !important;
        display: inline-block !important;
        flex-shrink: 0 !important;
        border-radius: 50% !important;
    }
    
    .hero-chat-demo .window-controls .dot:last-child,
    .hero-chat-demo .dot:last-child,
    .hero-chat-demo .window-controls .bg-success {
        margin-right: 8px !important;
    }
    
    /* Улучшаем отображение заголовка чата в мобильной версии */
    .hero-chat-demo .chat-header {
        padding: 8px 0 !important;
        border-bottom: 1px solid #e9ecef !important;
    }
    
    .hero-chat-demo .chat-header .text-muted {
        font-size: 12px !important;
        font-weight: 500 !important;
    }
    
    .hero-btn {
        width: 100% !important;
        min-height: 48px !important;
        font-size: 16px !important;
        font-weight: 600 !important;
        text-align: center !important;
        white-space: normal !important;
        word-wrap: break-word !important;
        overflow-wrap: break-word !important;
        max-width: 100% !important;
        padding: 12px 16px !important;
        border-radius: 8px !important;
        margin-bottom: 8px !important;
    }
    
    .hero-btn:last-child {
        margin-bottom: 0 !important;
    }
    
    .hero-section .d-flex {
        flex-direction: column !important;
        gap: 8px !important;
    }
    
    .hero-section .d-flex .btn {
        flex: 1 1 100% !important;
        max-width: 100% !important;
    }
    
    /* ============================================================================
       FEATURES SECTION - МОБИЛЬНАЯ ВЕРСИЯ
       ============================================================================ */
    
    .features-section .card {
        border-radius: 12px !important;
        box-shadow: 0 4px 12px rgba(0,0,0,0.1) !important;
        margin-bottom: 1rem !important;
    }
    
    .features-section .feature-icon {
        font-size: 2.5rem !important;
    }
    
    .features-section .card-title {
        font-size: 1.25rem !important;
        margin-bottom: 0.75rem !important;
    }
    
    .features-section .card-text {
        font-size: 0.95rem !important;
        line-height: 1.5 !important;
    }
    
    .feature-icon-large {
        width: 60px !important;
        height: 60px !important;
    }
    
    .feature-icon-medium {
        min-width: 32px !important;
        font-size: 1.5rem !important;
    }
    
    /* ============================================================================
       HOW IT WORKS SECTION - МОБИЛЬНАЯ ВЕРСИЯ
       ============================================================================ */
    
    .how-it-works-section .step-item {
        margin-bottom: 1.5rem !important;
    }
    
    .how-it-works-section .step-icon {
        width: 60px !important;
        height: 60px !important;
        font-size: 1.5rem !important;
    }
    
    .how-it-works-section .step-title {
        font-size: 1.1rem !important;
        margin-bottom: 0.5rem !important;
    }
    
    .how-it-works-section .step-description {
        font-size: 0.95rem !important;
        line-height: 1.5 !important;
    }
    
    /* ============================================================================
       FAQ SECTION - МОБИЛЬНАЯ ВЕРСИЯ
       ============================================================================ */
    
    .faq-section .accordion-button {
        font-size: 16px !important;
        padding: 1rem !important;
        min-height: 44px !important;
    }
    
    .faq-section .accordion-body {
        font-size: 14px !important;
        line-height: 1.6 !important;
        padding: 1rem !important;
    }
    
    .faq-section .accordion-item {
        border-radius: 8px !important;
        margin-bottom: 0.5rem !important;
    }
    
    /* ============================================================================
       ADD BOT SECTION - МОБИЛЬНАЯ ВЕРСИЯ
       ============================================================================ */
    
    .add-bot-section .step-item {
        margin-bottom: 1.5rem !important;
    }
    
    .add-bot-section .step-number {
        width: 48px !important;
        height: 48px !important;
        font-size: 18px !important;
    }
    
    .add-bot-section .step-title {
        font-size: 1.1rem !important;
        margin-bottom: 0.5rem !important;
    }
    
    .add-bot-image {
        border-radius: 12px !important;
        box-shadow: 0 4px 16px rgba(0,0,0,0.15) !important;
        margin: 1rem 0 !important;
    }
    
    /* ============================================================================
       ENTERPRISE SECTION - МОБИЛЬНАЯ ВЕРСИЯ
       ============================================================================ */
    
    .enterprise-section .display-5 {
        font-size: 2rem !important;
        line-height: 1.2 !important;
    }
    
    .enterprise-section .lead {
        font-size: 1rem !important;
        line-height: 1.5 !important;
    }
    
    /* ============================================================================
       TECHNOLOGIES SECTION - МОБИЛЬНАЯ ВЕРСИЯ
       ============================================================================ */
    
    .technologies-section .card {
        border-radius: 12px !important;
        box-shadow: 0 4px 12px rgba(0,0,0,0.1) !important;
    }
    
    .technologies-section .card-body {
        padding: 1.5rem !important;
    }
    
    .technologies-section h5 {
        font-size: 1.1rem !important;
        margin-bottom: 1rem !important;
    }
    
    .technologies-section ul li {
        font-size: 0.95rem !important;
        margin-bottom: 0.5rem !important;
    }
    
    /* ============================================================================
       CTA SECTION - МОБИЛЬНАЯ ВЕРСИЯ
       ============================================================================ */
    
    .cta-section .display-4 {
        font-size: 2.5rem !important;
        line-height: 1.2 !important;
    }
    
    .cta-section .lead {
        font-size: 1.1rem !important;
        line-height: 1.5 !important;
    }
    
    .cta-btn-equal {
        width: 100% !important;
        min-height: 48px !important;
        font-size: 16px !important;
        margin-bottom: 0.5rem !important;
    }
    
    .cta-btn-equal:last-child {
        margin-bottom: 0 !important;
    }
    
    /* ============================================================================
       ОБЩИЕ МОБИЛЬНЫЕ УЛУЧШЕНИЯ
       ============================================================================ */
    
    /* Увеличение отступов */
    .container {
        padding-left: 15px !important;
        padding-right: 15px !important;
    }
    
    /* Оптимизация заголовков */
    .display-3 {
        font-size: 2.5rem !important;
    }
    
    .display-4 {
        font-size: 2rem !important;
    }
    
    .display-5 {
        font-size: 1.75rem !important;
    }
    
    /* Touch-friendly элементы */
    .btn, .nav-link, .accordion-button {
        min-height: 44px !important;
        padding: 12px 16px !important;
    }
    
    /* Оптимизация изображений */
    img {
        border-radius: 8px !important;
    }
    
    /* Улучшение читаемости */
    body {
        font-size: 16px !important;
        line-height: 1.5 !important;
    }
    
    p, .lead {
        font-size: 1rem !important;
        line-height: 1.6 !important;
    }
    
    /* Оптимизация карточек */
    .card {
        border-radius: 12px !important;
        box-shadow: 0 2px 8px rgba(0,0,0,0.1) !important;
    }
    
    /* Улучшение навигации */
    .navbar-nav .nav-item {
        margin-bottom: 8px !important;
    }
    
    .navbar-nav .nav-link {
        padding: 12px 16px !important;
        border-radius: 8px !important;
        margin-bottom: 4px !important;
        font-weight: 500 !important;
    }
    
    /* Оптимизация модальных окон */
    .modal-dialog {
        margin: 1rem !important;
    }
    
    .modal-content {
        border-radius: 12px !important;
    }
    
    /* Улучшение форм */
    .form-control, .form-select {
        font-size: 16px !important;
        padding: 12px !important;
        border-radius: 8px !important;
    }
    
    /* Оптимизация кнопок */
    .btn {
        border-radius: 8px !important;
        font-weight: 500 !important;
        box-shadow: 0 2px 4px rgba(0,0,0,0.1) !important;
        transition: all 0.2s ease !important;
    }
    
    .btn:active {
        transform: translateY(1px) !important;
        box-shadow: 0 1px 2px rgba(0,0,0,0.1) !important;
    }
} 