@charset "UTF-8";
/* ==========================================================================
   ADAT TRAVEL - ADVANCED COMPREHENSIVE MOBILE ADAPTATION 
   (by Gemini)
   
   Этот файл содержит глубокую адаптацию всех inline-стилей и новых 
   компонентов сайта для планшетов и мобильных телефонов.
   ========================================================================== */

/* ==========================================================================
   1. ГЛОБАЛЬНЫЕ НАСТРОЙКИ И СБРОС (MAX-WIDTH: 1199.98PX)
   ========================================================================== */
@media (max-width: 1199.98px) {
    /* Сжатие огромных отступов на больших планшетах/маленьких ноутбуках */
    section[style*="padding: 180px"] { padding-top: 120px !important; padding-bottom: 120px !important; }
    section[style*="padding: 120px"] { padding-top: 90px !important; padding-bottom: 90px !important; }
    section[style*="padding: 100px"] { padding-top: 80px !important; padding-bottom: 80px !important; }
    
    /* Сетка Storytelling */
    div[style*="gap: 80px"] { gap: 40px !important; }
    div[style*="gap: 60px"] { gap: 30px !important; }
    
    /* Изображения в Storytelling */
    img[style*="height: 500px"] { height: 400px !important; }
    
    /* Сетки из 3-х колонок превращаем в 2 */
    div[style*="grid-template-columns: repeat(3"] {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

/* ==========================================================================
   2. ПЛАНШЕТЫ И СРЕДНИЕ ЭКРАНЫ (MAX-WIDTH: 991.98PX)
   ========================================================================== */
@media (max-width: 991.98px) {
    /* -----------------------------------------
       2.1. ГЛОБАЛЬНАЯ ТИПОГРАФИКА
       ----------------------------------------- */
    h1[style*="font-size: 3.8rem"], 
    h1[style*="font-size: 3.5rem"] { 
        font-size: 2.8rem !important; 
    }
    
    h2[style*="font-size: 4rem"] { 
        font-size: 3.2rem !important; 
    }
    
    h2[style*="font-size: 3.5rem"], 
    h2[style*="font-size: 3.2rem"], 
    h2[style*="font-size: 2.8rem"], 
    h2[style*="font-size: 2.6rem"] { 
        font-size: 2.2rem !important; 
    }
    
    h3[style*="font-size: 2.2rem"] { 
        font-size: 1.8rem !important; 
    }
    
    /* Сброс лидинг-абзацев */
    p.lead[style*="font-size: 1.3rem"],
    p.lead[style*="font-size: 1.25rem"],
    p.lead[style*="font-size: 1.2rem"],
    p.lead[style*="font-size: 1.15rem"] {
        font-size: 1.1rem !important;
    }

    /* -----------------------------------------
       2.2. ОТСТУПЫ СЕКЦИЙ И КОНТЕЙНЕРОВ
       ----------------------------------------- */
    section[style*="padding: 180px"] { padding-top: 100px !important; padding-bottom: 100px !important; }
    section[style*="padding: 120px 0 80px"] { padding-top: 100px !important; padding-bottom: 60px !important; }
    section[style*="padding: 120px"] { padding-top: 80px !important; padding-bottom: 80px !important; }
    section[style*="padding: 100px"] { padding-top: 80px !important; padding-bottom: 80px !important; }
    section[style*="padding: 80px"] { padding-top: 60px !important; padding-bottom: 60px !important; }

    /* Панели (Info panels, CTA) */
    div[style*="padding: 48px"] { 
        padding: 32px !important; 
        border-radius: 24px !important; 
    }
    
    div[style*="padding: 40px 32px"] { 
        padding: 32px 24px !important; 
    }
    
    div[style*="padding: 80px 60px"] { 
        padding: 40px 32px !important; 
        border-radius: 24px !important; 
    }

    /* -----------------------------------------
       2.3. СЕТКИ (GRIDS) - ИСПРАВЛЕНИЕ OVERFLOW
       ----------------------------------------- */
    /* Любая жесткая сетка, которая сломает мобилку */
    div[style*="minmax(400px"], 
    div[style*="minmax(300px"], 
    div[style*="minmax(280px"],
    div[style*="minmax(240px"],
    div[style*="grid-template-columns: repeat(2"] {
        grid-template-columns: 1fr !important;
    }

    /* -----------------------------------------
       2.4. STORYTELLING БЛОКИ (index.html)
       ----------------------------------------- */
    /* Убираем "шахматный" порядок */
    div[style*="direction: rtl"] { 
        direction: ltr !important; 
    }
    div[style*="direction: rtl"] > div { 
        direction: ltr !important; 
        padding-left: 0 !important; 
    }
    div[style*="padding-right: 40px"] { 
        padding-right: 0 !important; 
    }
    
    /* Отключаем 3D-анимации, чтобы блоки не вылезали за края экрана на тачах */
    div[style*="perspective"] { transform: none !important; }
    div[style*="perspective"]:hover { transform: translateY(-5px) !important; } /* Оставляем легкий подъем */

    /* Уменьшаем изображения в Storytelling для планшетов */
    img[style*="height: 500px"] { height: 350px !important; }

    /* -----------------------------------------
       2.5. КНОПКИ И ACTIONS
       ----------------------------------------- */
    .hero-actions, 
    div[style*="display: flex"][style*="gap: 20px"] {
        flex-direction: column !important;
        width: 100% !important;
        gap: 12px !important;
    }
    .hero-actions a, .hero-actions button,
    div[style*="display: flex"][style*="gap: 20px"] a,
    div[style*="display: flex"][style*="gap: 20px"] button {
        width: 100% !important;
        justify-content: center !important;
    }

    /* -----------------------------------------
       2.6. ТАБЛИЦА УСЛУГ (our_services.html)
       ----------------------------------------- */
    /* Трансформация таблицы в карточки */
    table[style*="width: 100%"] thead { display: none !important; }
    table[style*="width: 100%"], 
    table[style*="width: 100%"] tbody, 
    table[style*="width: 100%"] tr, 
    table[style*="width: 100%"] td {
        display: block !important;
        width: 100% !important;
    }
    table[style*="width: 100%"] tr {
        margin-bottom: 24px !important;
        border: 1px solid rgba(17,72,63,0.1) !important;
        border-radius: 24px !important;
        overflow: hidden !important;
        background: #fff !important;
        box-shadow: 0 8px 24px rgba(0,0,0,0.04) !important;
    }
    table[style*="width: 100%"] td { 
        padding: 24px !important; 
        border-bottom: none !important; 
    }
    table[style*="width: 100%"] td:first-child { 
        padding-bottom: 12px !important; 
    }
    table[style*="width: 100%"] td:nth-child(2) { 
        padding-top: 0 !important; 
        padding-bottom: 24px !important; 
    }
    table[style*="width: 100%"] td:last-child { 
        padding-top: 0 !important; 
        border-top: 1px solid rgba(17,72,63,0.05) !important; 
        background: rgba(17,72,63,0.01) !important;
    }
    
    /* -----------------------------------------
       2.7. КОНТАКТЫ (contacts.html)
       ----------------------------------------- */
    .contact-layout {
        display: flex !important;
        flex-direction: column !important;
    }
    
    /* -----------------------------------------
       2.8. ФОРМА БРОНИРОВАНИЯ (tour_booking.html)
       ----------------------------------------- */
    .booking-page {
        grid-template-columns: 1fr !important;
    }
    .tour-summary {
        position: static !important;
        margin-bottom: 24px !important;
    }
}


/* ==========================================================================
   3. МОБИЛЬНЫЕ ТЕЛЕФОНЫ (MAX-WIDTH: 767.98PX)
   ========================================================================== */
@media (max-width: 767.98px) {
    /* -----------------------------------------
       3.1. ИЗОБРАЖЕНИЯ И МЕДИА
       ----------------------------------------- */
    /* Изображения в сторителлинге */
    img[style*="height: 500px"],
    img[style*="height: 400px"] { 
        height: 250px !important; 
    }

    /* -----------------------------------------
       3.2. ВНУТРЕННИЕ ЭЛЕМЕНТЫ И ГРИДЫ
       ----------------------------------------- */
    /* Контакты: иконка + текст */
    div[style*="display: flex; align-items: flex-start; gap: 20px"],
    div[style*="display: flex; align-items: flex-start; gap: 16px"] {
        flex-direction: column !important;
        gap: 12px !important;
        text-align: center !important;
        align-items: center !important;
    }
    
    /* Кнопка добавления туриста (tour_booking.html) */
    .form-section__header {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 16px !important;
    }
    
    /* Сетка туристов (поля формы) */
    div[style*="grid-template-columns: 1fr 1fr"] {
        grid-template-columns: 1fr !important;
    }
    
    /* Блок "Нужна помощь" (booking) */
    div[style*="display: flex; align-items: flex-start; gap: 24px"] {
        flex-direction: column !important;
        align-items: center !important;
        text-align: center !important;
    }
    
    /* Телефоны и мессенджеры в блоке помощи */
    div[style*="display: flex; gap: 24px; flex-wrap: wrap"] {
        justify-content: center !important;
        flex-direction: column !important;
        gap: 12px !important;
        width: 100% !important;
    }
    
    div[style*="display: flex; gap: 24px; flex-wrap: wrap"] a {
        background: #fff;
        padding: 12px 16px;
        border-radius: 12px;
        box-shadow: 0 4px 8px rgba(0,0,0,0.02);
        justify-content: center;
    }
    
    /* Карточки с мессенджерами (Контакты) */
    div[style*="width: 80px; height: 80px"] {
        width: 64px !important;
        height: 64px !important;
        font-size: 28px !important;
        margin-bottom: 16px !important;
    }
    
    /* Отступы для карточек услуг (services) */
    div[style*="padding: 32px"] {
        padding: 24px !important;
    }
}


/* ==========================================================================
   4. МАЛЕНЬКИЕ ЭКРАНЫ И SMARTPHONES (MAX-WIDTH: 575.98PX)
   ========================================================================== */
@media (max-width: 575.98px) {
    /* -----------------------------------------
       4.1. ФИНАЛЬНАЯ ТИПОГРАФИКА ДЛЯ ТЕЛЕФОНОВ
       ----------------------------------------- */
    h1[style*="font-size: 3.8rem"], 
    h1[style*="font-size: 3.5rem"] { 
        font-size: 2.2rem !important; 
        line-height: 1.2 !important; 
    }
    
    h2[style*="font-size: 4rem"] { 
        font-size: 2.4rem !important; 
        line-height: 1.2 !important; 
    }
    
    h2[style*="font-size: 3.2rem"], 
    h2[style*="font-size: 2.8rem"], 
    h2[style*="font-size: 2.6rem"] { 
        font-size: 1.8rem !important; 
        line-height: 1.25 !important; 
    }
    
    h3[style*="font-size: 2.2rem"] { 
        font-size: 1.5rem !important; 
    }
    
    /* -----------------------------------------
       4.2. МИНИМИЗАЦИЯ ОТСТУПОВ (ЭКОНОМИЯ МЕСТА)
       ----------------------------------------- */
    section[style*="padding: 180px"] { padding-top: 60px !important; padding-bottom: 60px !important; }
    section[style*="padding: 100px"] { padding-top: 50px !important; padding-bottom: 50px !important; }
    section[style*="padding: 120px"] { padding-top: 60px !important; padding-bottom: 50px !important; }
    
    /* Панели */
    div[style*="padding: 48px"], 
    div[style*="padding: 32px"],
    div[style*="padding: 24px"] { 
        padding: 20px !important; 
    }
    
    /* -----------------------------------------
       4.3. СКРЫТИЕ ДЕКОРАТИВНЫХ ЭЛЕМЕНТОВ
       (Ломают ширину экрана на старых Android / iOS)
       ----------------------------------------- */
    div[style*="background: radial-gradient(circle"][style*="width: 600px"],
    div[style*="background: radial-gradient(circle"][style*="width: 500px"],
    div[style*="background: radial-gradient(circle"][style*="width: 400px"],
    div[style*="background: radial-gradient(circle"][style*="width: 300px"],
    div[style*="background: radial-gradient(circle"][style*="width: 200px"] {
        display: none !important;
    }
    
    /* -----------------------------------------
       4.4. КНОПКИ (TOUCH TARGETS)
       ----------------------------------------- */
    /* Кнопки - делаем еще плотнее для пальца */
    a[style*="padding: 18px 36px"], 
    button[style*="padding: 18px 40px"], 
    a[style*="padding: 20px 40px"] {
        padding: 16px 20px !important;
        font-size: 1rem !important;
        border-radius: 12px !important;
    }
    
    /* -----------------------------------------
       4.5. ФОТОГРАФИИ УСЛУГ И КАРТОЧЕК
       ----------------------------------------- */
    /* Изображения в услугах */
    img[style*="height: 200px"] {
        height: 160px !important;
    }
    
    /* -----------------------------------------
       4.6. КАРТОЧКИ МОДАЛКИ (TOUR PICKER)
       ----------------------------------------- */
    a.picker-route-card, button.picker-route-card {
        padding: 16px !important;
        gap: 12px !important;
    }
    
    .picker-route-card div[style*="width: 56px"] {
        width: 48px !important;
        height: 48px !important;
        font-size: 20px !important;
    }
}

/* ==========================================================================
   5. ПРЕДОТВРАЩЕНИЕ ЛЮБОГО ГОРИЗОНТАЛЬНОГО СКРОЛЛА
   ========================================================================== */
html, body {
    overflow-x: hidden !important;
    max-width: 100vw !important;
}

.container {
    overflow-x: visible !important;
}
