/* ==========================================================================
   ЧАСТЬ 1: БАЗОВЫЕ НАСТРОЙКИ, ФИКСИРОВАННАЯ ШАПКА И СЕРВИСНЫЕ БАРЫ
   ========================================================================== */

:root {
    --primary: #ff5722;          /* Ярко-оранжевый акцент */
    --primary-hover: #e04714;    /* Темно-оранжевый при наведении */
    --dark: #1e1e24;             /* Глубокий черный/угольный */
    --light-bg: #f4f6f9;         /* Светло-серый фон страниц */
    --border: #e1e4e8;           /* Серые бордюры разделителей */
    --text: #333333;             /* Основной цвет текста */
    --radius: 8px;               /* Скругление углов обычных блоков */
    --brand-radius: 12px;        /* Скругление виджетов */
    --transition: all 0.25s ease; /* Скорость анимаций */
}

* { 
    box-sizing: border-box; 
    margin: 0; 
    padding: 0; 
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; 
}

/* Верхний отступ для body, чтобы контент сайта не заезжал под липкую шапку */
body { 
    background-color: var(--light-bg); 
    color: var(--text); 
    line-height: 1.5; 
    padding-top: 155px; 
    max-width: 100% !important;
    overflow-x: hidden !important;
}

.container { 
    max-width: 1240px; 
    margin: 0 auto; 
    padding: 0 20px; 
}

a { 
    text-decoration: none; 
    color: inherit; 
}

img {
    max-width: 100%;
    height: auto;
}

/* ФИКСИРОВАННЫЙ КАРКАС ШАПКИ — ИСПРАВЛЕНО: РАЗРЕШЕН ВЫПУСК ВЫПАДАЮЩЕГО МЕНЮ */
.fixed-header-wrapper {
    position: fixed !important;
    top: 0;
    left: 0;
    width: 100%;
    
    /* КРИТИЧЕСКИ ВАЖНО: Разрешаем элементам выпадать за границы шапки */
    overflow: visible !important; 
    
    /* Ставим железный приоритет над слайдером и виджетами */
    z-index: 9999999 !important; 
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    max-width: 100% !important;
}


.header-top-banner { 
    background: var(--primary); 
    color: #fff; 
    font-size: 13px; 
    padding: 8px 0; 
    width: 100%;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.main-header-row { 
    background: #fff; 
    padding: 15px 0; 
    border-bottom: 1px solid var(--border);
}

.header-navigation-row {
    background: #ffffff;
    border-bottom: 1px solid var(--border);
    padding: 10px 0;
}

.header-nav-menu-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
    gap: 24px;
    font-size: 14px;
    font-weight: 600;
}

.header-nav-menu-list li a {
    color: var(--dark);
    transition: var(--transition);
}

.header-nav-menu-list li a:hover {
    color: var(--primary);
}

.top-bar { 
    background: var(--dark); 
    color: #fff; 
    font-size: 13px; 
    padding: 8px 0; 
}
.top-bar__inner { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
}
.top-menu { 
    display: flex; 
    gap: 20px; 
    list-style: none; 
}
.top-menu li a:hover { 
    color: var(--primary); 
}
.highlight-link { 
    color: var(--primary); 
    font-weight: bold; 
}
.user-actions { 
    display: flex; 
    align-items: center; 
    gap: 12px; 
}
.login-link:hover { 
    color: var(--primary); 
    cursor: pointer;
}
.user-actions-divider { 
    color: #555; 
    font-size: 12px; 
}
.cart-link { 
    font-weight: bold; 
    color: var(--primary); 
}

.main-header { 
    background: #fff; 
    padding: 15px 0; 
    box-shadow: 0 2px 10px rgba(0,0,0,0.05); 
    position: sticky; 
    top: 0; 
    z-index: 100; 
}
.header-inner { 
    display: flex; 
    align-items: center; 
    justify-content: space-between; 
    gap: 20px; 
}
.logo { 
    font-size: 28px; 
    font-weight: 800; 
    color: var(--dark); 
}
.logo span { 
    color: var(--primary); 
}

.search-box { 
    flex-grow: 1; 
    max-width: 450px; 
    display: flex; 
}
.search-box input { 
    width: 100%; 
    padding: 12px; 
    border: 1px solid var(--border); 
    border-radius: var(--radius) 0 0 var(--radius); 
    outline: none; 
}
.search-box button { 
    background: var(--primary); 
    color: #fff; 
    border: none; 
    padding: 0 20px; 
    border-radius: 0 var(--radius) var(--radius) 0; 
    cursor: pointer; 
    font-weight: 600;
}
.search-box button:hover {
    background: var(--primary-hover);
}

.contacts-block { 
    display: flex; 
    flex-direction: column; 
    align-items: flex-end; 
    gap: 4px; 
}
.contacts-block .phone { 
    font-size: 18px; 
    font-weight: 700; 
    color: var(--dark); 
}
.contacts-block .sub { 
    font-size: 11px; 
    color: #777; 
}
.header-book-btn {
    background: var(--primary); 
    color: #fff; 
    border: none; 
    padding: 8px 16px;
    font-size: 13px; 
    font-weight: 700; 
    border-radius: var(--radius); 
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(255, 87, 34, 0.2); 
    transition: var(--transition); 
    margin-top: 5px; 
    white-space: nowrap;
}
.header-book-btn:hover { 
    background: var(--primary-hover); 
    transform: translateY(-1px); 
}
/* ==========================================================================
   ЧАСТЬ 2: ГЛАВНЫЙ СЛАЙДЕР, ФОРМЫ ПОДБОРА, СЕТКИ ТОВАРОВ И ФИЛЬТРЫ КАТАЛОГА
   ========================================================================== */

.hero-section {
    position: relative;
    width: 100%;
    min-height: 540px;
    background: #222;
    overflow: hidden;
    display: flex;
    align-items: center;
}
.main-slider {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%; z-index: 1;
}
.hero-slide {
    width: 100%; height: 100%; position: absolute; top: 0; left: 0;
    background-position: center center !important;
    background-size: cover !important;
    background-repeat: no-repeat !important;
    transition: opacity 0.6s ease-in-out;
}
.search-widget-container {
    position: relative;
    z-index: 10;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 30px;
    padding-top: 30px;
    padding-bottom: 30px;
}
.hero-slide-content {
    flex: 1;
    max-width: 50%;
    pointer-events: none;
    display: flex;
    flex-direction: column;
    gap: 15px;
}
.hero-slide-title {
    color: #ffffff;
    font-size: 38px;
    font-weight: 800;
    text-transform: uppercase;
    line-height: 1.2;
    margin: 0;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.85);
}
.hero-slide-subtitle {
    color: #f3f3f3;
    font-size: 18px;
    font-weight: 400;
    line-height: 1.4;
    margin: 0;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.85);
}
.search-widget-box {
    background: rgba(255, 255, 255, 0.97);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    width: 420px;
    min-width: 420px;
    border-radius: var(--brand-radius);
    padding: 30px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.25);
    box-sizing: border-box;
}
.widget-mode-tabs {
    display: flex; background: #e4e4e6; border-radius: 8px; padding: 4px; margin-bottom: 22px;
}
.widget-tab-btn {
    flex: 1; border: none; padding: 11px; font-size: 14px; font-weight: 700; border-radius: 6px; cursor: pointer; background: transparent; color: #555555; transition: var(--transition); outline: none;
}
.widget-tab-btn.active-tire { background: #ffffff !important; color: var(--primary) !important; box-shadow: 0 2px 6px rgba(0,0,0,0.1); }
.widget-tab-btn.active-wheel { background: #ffffff !important; color: var(--dark) !important; box-shadow: 0 2px 6px rgba(0,0,0,0.1); }
.widget-search-form { display: flex; flex-direction: column; gap: 14px; }
.widget-field-group { display: flex; flex-direction: column; gap: 5px; width: 100%; box-sizing: border-box; }
.widget-field-group label { font-size: 12px; font-weight: 700; color: #444444; text-transform: uppercase; }
.widget-field-group select {
    width: 100%; height: 44px; padding: 0 12px; border: 1px solid #cccccc; border-radius: 6px; background: #ffffff; color: #1e1e24; font-size: 14px; font-weight: 500; outline: none; cursor: pointer; box-sizing: border-box;
}
.widget-submit-btn {
    width: 100%; height: 48px; border: none; font-size: 16px; font-weight: 700; border-radius: 6px; cursor: pointer; color: #ffffff; transition: var(--transition); display: flex; align-items: center; justify-content: center;
}
.widget-submit-btn.tire-bg { background: var(--primary); margin-top: 8px; }
.widget-submit-btn.wheel-bg { background: var(--dark); margin-top: 66px; }

.slider-container { position: relative; border-radius: var(--radius); overflow: hidden; background: #222; }
.slide { width: 100%; height: 100%; display: none; background-size: cover; background-position: center; color: #fff; padding: 40px; }
.slide.active { display: flex; flex-direction: column; justify-content: center; align-items: flex-start; }
.slide h2 { font-size: 36px; margin-bottom: 15px; text-shadow: 0 2px 4px rgba(0,0,0,0.7); }
.slide p { font-size: 18px; text-shadow: 0 2px 4px rgba(0,0,0,0.7); }
.slider-btn { position: absolute; top: 50%; transform: translateY(-50%); background: rgba(0,0,0,0.5); color: #fff; border: none; padding: 12px; cursor: pointer; border-radius: 50%; z-index: 10; }
.slider-btn.prev { left: 15px; }
.slider-btn.next { right: 15px; }

.filter-widget { background: #fff; padding: 25px; border-radius: var(--radius); border: 1px solid var(--border); display: flex; flex-direction: column; }
.widget-content { display: none; flex-direction: column; gap: 12px; }
.widget-content.active { display: flex; }
.form-group { display: flex; flex-direction: column; gap: 5px; }
.form-group label { font-size: 13px; font-weight: 600; color: #666; }
.form-group select { padding: 10px; border: 1px solid var(--border); border-radius: var(--radius); background: #fff; outline: none; }
.form-group select:disabled { background: #f0f0f0; cursor: not-allowed; }
.widget-submit { background: var(--primary); color: #fff; border: none; padding: 12px; border-radius: var(--radius); font-weight: 600; cursor: pointer; text-align: center; }
.widget-submit:hover { background: var(--primary-hover); }

/* КАТАЛОГ И СЕТКИ КАРТОЧЕК */
.catalog-container { display: grid; grid-template-columns: 280px 1fr; gap: 30px; margin: 30px 0; }
/* Включаем липкий фильтр со скроллом ТОЛЬКО на больших экранах ПК */
@media (min-width: 1025px) {
    .sidebar-filters {
        position: sticky !important;
        top: 170px !important; 
        max-height: calc(100vh - 190px) !important; 
        overflow-y: auto !important; 
    }
    /* Красивая тонкая полоса прокрутки для ПК */
    .sidebar-filters::-webkit-scrollbar { width: 4px; }
    .sidebar-filters::-webkit-scrollbar-thumb { background: #ccc; border-radius: 4px; }
}

.products-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 20px; }
.product-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; position: relative; display: flex; flex-direction: column; justify-content: space-between; transition: var(--transition); cursor: pointer; }
.product-card:hover { transform: translateY(-3px); box-shadow: 0 6px 15px rgba(0,0,0,0.06); border-color: var(--primary); }
.prod-badge { position: absolute; top: 12px; left: 12px; background: var(--dark); color: #fff; font-size: 11px; padding: 4px 8px; border-radius: 4px; font-weight: 600; }
.prod-img { width: 100%; height: 160px; object-fit: contain; margin-bottom: 15px; }
.prod-name { font-size: 16px; font-weight: 700; margin-bottom: 8px; color: var(--dark); }
.prod-meta { font-size: 13px; color: #666; margin-bottom: 15px; }
.prod-footer { display: flex; align-items: center; justify-content: space-between; }
.prod-price { font-size: 18px; font-weight: 800; color: var(--dark); }
.buy-btn { background: var(--primary); color: #fff; border: none; padding: 8px 16px; border-radius: var(--radius); font-weight: 600; cursor: pointer; transition: var(--transition); }
.buy-btn:hover { background: var(--primary-hover); }
/* ==========================================================================
   ЧАСТЬ 3: ИНФО-БЛОКИ, ПРОМО, СТИЛИ ПРАЙС-ЛИСТОВ, ЛИЧНЫЙ КАБИНЕТ И ФУТЕР
   ========================================================================== */

.info-blocks { display: grid; grid-template-columns: 1fr 1fr; gap: 25px; margin-bottom: 40px; }
.info-card { background: #fff; padding: 25px; border-radius: var(--radius); border-left: 5px solid var(--primary); box-shadow: 0 2px 5px rgba(0,0,0,0.02); }
.info-card h3 { margin-bottom: 10px; font-size: 18px; }
.about-section { background: #fff; padding: 35px; border-radius: var(--radius); border: 1px solid var(--border); margin-bottom: 50px; }
.about-section h3 { margin-bottom: 12px; font-size: 22px; }

/* СТИЛИ СТРАНИЦЫ ПРАЙС-ЛИСТОВ */
.price-tab {
    display: flex; align-items: center; gap: 8px; padding: 12px 24px; border: 1px solid #e1e4e8; border-radius: 6px; font-weight: 600; cursor: pointer; transition: all 0.2s ease; background: #fff; color: #333;
}
.price-tab.active {
    background: var(--primary) !important; color: #fff !important; border-color: var(--primary) !important; box-shadow: 0 4px 10px rgba(255, 87, 34, 0.3);
}

/* СТИЛИ ЛИЧНОГО КАБИНЕТА, ТАБОВ АДМИНА И ТАБЛИЦ */
.widget-tabs { display: flex; border-bottom: 2px solid var(--border); margin-bottom: 20px; width: 100%; }
.widget-tab { flex: 1; text-align: center; padding: 12px 20px; font-weight: 600; color: #777; background: none; border: none; cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -2px; transition: var(--transition); font-size: 15px; }
.widget-tab:hover { color: var(--primary); }
.widget-tab.active { color: var(--primary) !important; border-bottom: 2px solid var(--primary) !important; font-weight: 700; }

/* ПРОМО-КАРТОЧКИ (АКЦИИ НА ГЛАВНОЙ) */
.promo-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 40px; margin-bottom: 50px; width: 100%; }
.promo-card { background: #f4f4f6; border-radius: 8px; padding: 22px; display: flex; justify-content: space-between; align-items: center; box-sizing: border-box; transition: var(--transition); border: 1px solid transparent; }
.promo-card:hover { transform: translateY(-3px); background: #ededff; box-shadow: 0 10px 20px rgba(0,0,0,0.05); }
.promo-card.green-border  { border-left: 5px solid var(--primary); }
.promo-card.blue-border   { border-left: 5px solid var(--dark); }
.promo-card.orange-border { border-left: 5px solid var(--primary); }
.promo-card h4 { font-size: 17px; font-weight: 700; color: #222222; margin: 0; }
.promo-card p { font-size: 13px; color: #666666; margin: 0 0 10px 0; line-height: 1.4; }
.promo-card a, .promo-card span.link { font-size: 13px; font-weight: 700; text-decoration: none; cursor: pointer; transition: var(--transition); display: inline-block; }
.promo-card a:hover, .promo-card span.link:hover { text-decoration: underline; }
.promo-card.green-border a  { color: var(--primary); }
.promo-card.blue-border a   { color: var(--dark); }
.promo-card.orange-border span.link { color: var(--primary); }
.promo-card .icon { font-size: 42px; user-select: none; padding-left: 10px; }

.brands-section { margin: 40px 0; }
.brands-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 15px; }
.brand-card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; text-align: center; font-weight: 600; transition: var(--transition); cursor: pointer; }
.brand-card:hover { transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,0.05); border-color: var(--primary); color: var(--primary); }

/* МОДНЫЙ ЧЕРНЫЙ ФУТЕР САЙТА */
.main-footer { background: var(--dark); color: #fff; padding: 50px 0 20px 0; margin-top: 50px; width: 100%; }
.footer-inner { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; margin-bottom: 30px; }
.footer-col h4 { font-size: 16px; margin-bottom: 15px; color: var(--primary); text-transform: uppercase; font-weight: 700; }
.footer-info .logo { font-size: 24px; font-weight: 900; color: #fff; margin-bottom: 15px; }
.footer-info p { color: #aaa; font-size: 14px; max-width: 350px; line-height: 1.6; }
.footer-links ul { list-style: none; }
.footer-links ul li { margin-bottom: 12px; }
.footer-links ul li a { color: #ccc; font-size: 14px; transition: var(--transition); }
.footer-links ul li a:hover { color: var(--primary); }
.footer-contacts p { color: #ccc; font-size: 14px; margin-bottom: 10px; }
.footer-contacts .footer-phone { font-size: 20px; font-weight: 800; color: #fff; display: block; }
.footer-bottom { border-top: 1px solid #333339; padding-top: 20px; text-align: center; font-size: 13px; color: #777; margin-top: 20px; }

/* МОДАЛЬНЫЕ ОКНА И ОВЕРЛЕИ АВТОРИЗАЦИИ */
.modal-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(30, 30, 36, 0.6); backdrop-filter: blur(5px); display: none; justify-content: center; align-items: center; z-index: 99999; }
.modal-content { background: #fff; padding: 35px; border-radius: 12px; max-width: 420px; width: 90%; position: relative; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15); }
.close-modal { position: absolute; top: 15px; right: 15px; font-size: 24px; cursor: pointer; border: none; background: none; color: #999; }
.close-modal:hover { color: var(--primary); }
.auth-form-content { display: none; flex-direction: column; gap: 15px; }
.auth-form-content.active { display: flex; }
.modal-content input { width: 100%; padding: 11px; border: 1px solid var(--border); border-radius: var(--radius); outline: none; font-size: 14px; }
.modal-content input:focus { border-color: var(--primary); }
.modal-content h3 { font-size: 20px; margin-bottom: 20px; text-align: center; }

/* АДАПТИВНОСТЬ */
@media (max-width: 992px) {
    body { padding-top: 240px; }
    .search-widget-container { flex-direction: column; justify-content: center; gap: 40px; padding-top: 40px; }
    .hero-slide-content { max-width: 100%; text-align: center; padding-left: 0; }
    .search-widget-box { width: 100%; max-width: 460px; }
    .promo-grid { grid-template-columns: 1fr; gap: 15px; }
    .catalog-container { grid-template-columns: 1fr; }
    .info-blocks, .footer-inner { grid-template-columns: 1fr; gap: 30px; }
}
@media (max-width: 576px) {
    .brands-grid { grid-template-columns: repeat(2, 1fr); }
}
/* ==========================================================================
   СОВРЕМЕННЫЕ PUSH-УВЕДОМЛЕНИЯ (ВМЕСТО СКУЧНЫХ ALERT)
   ========================================================================== */
.phone-toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 999999;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.phone-toast {
    background: #1e1e24; /* Темный глубокий фон смартфона */
    color: #ffffff;
    padding: 16px 22px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    box-shadow: 0 10px 25px rgba(0,0,0,0.25);
    border-left: 5px solid #ff5722; /* Оранжевый акцент бренда */
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 320px;
    max-width: 450px;
    transform: translateX(120%);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* Класс для плавного вылета на экран */
.phone-toast.show {
    transform: translateX(0);
}
/* ==========================================================================
   ОБНОВЛЕНИЕ КАТАЛОГА: ПОСТРАНИЧНАЯ НАВИГАЦИЯ И ЛИПКИЙ ФИЛЬТР
   ========================================================================== */

/* ИСПРАВЛЕНО: Делаем боковую панель фильтра плавающей при скролле */
.sidebar-filters {
    background: #fff;
    padding: 20px;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    gap: 20px;
    
    /* Вот эта магия делает фильтр липким */
    position: sticky;
    top: 170px; /* Отступ сверху с учетом высоты нашей фиксированной шапки */
    max-height: calc(100vh - 190px); /* Чтобы фильтр не вылезал за границы экрана */
    overflow-y: auto; /* Если фильтр длинный, внутри него появится аккуратный скролл */
}

/* Красивая полоса прокрутки внутри фильтра, если экран маленький */
.sidebar-filters::-webkit-scrollbar { width: 4px; }
.sidebar-filters::-webkit-scrollbar-thumb { background: #ccc; border-radius: 4px; }

/* Стили для кнопок постраничной навигации (Пагинация) */
.pagination-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 40px;
    margin-bottom: 20px;
    width: 100%;
}

.pagination-link {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 14px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 6px;
    color: var(--dark);
    font-size: 14px;
    font-weight: 600;
    transition: var(--transition);
    cursor: pointer;
}

.pagination-link:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.pagination-link.active {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff !important;
}

.pagination-link.disabled {
    background: #f4f6f9;
    color: #999;
    border-color: var(--border);
    cursor: not-allowed;
    pointer-events: none;
}
/* ==========================================================================
   УМНЫЙ МОБИЛЬНЫЙ ФЛЕКС-ДИЗАЙН ДЛЯ ШАПКИ И СЕТОК САЙТА (ИРКУТСК 2026)
   ========================================================================== */

html, body {
    max-width: 100vw !important;
    overflow-x: hidden !important;
    position: relative;
    box-sizing: border-box;
}

.header-main-container { display: flex; align-items: center; justify-content: space-between; gap: 20px; width: 100%; }
.header-logo-block { min-width: 180px; }
.header-logo-block a { text-decoration: none; font-size: 26px; font-weight: 900; color: #1e1e24; letter-spacing: -0.5px; }
.header-logo-block a span { color: #ff5722; }
.header-search-block { flex: 1; max-width: 600px; }
.header-search-block form { display: flex; width: 100%; margin: 0; }
.header-search-block input { width: 100%; height: 44px; padding: 0 15px; border: 1px solid #cccccc; border-radius: 8px 0 0 8px; font-size: 14px; outline: none; background: #f4f4f6; box-sizing: border-box; }
.header-search-block button { height: 44px; width: 54px; background: #ff5722; border: none; border-radius: 0 8px 8px 0; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.header-user-block { display: flex; align-items: center; gap: 25px; min-width: 200px; justify-content: flex-end; }
.user-icon-link { text-decoration: none; color: #1e1e24; display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 12px; font-weight: 600; }
.icon-emoji { font-size: 20px; }
.pointer-cursor { cursor: pointer; }
.header-nav-container { display: flex; align-items: center; justify-content: space-between; width: 100%; }
.location-li { display: flex; align-items: center; gap: 4px; color: #77777a; font-weight: 500; }
.contacts-strong-link { color: var(--dark) !important; font-weight: 700 !important; }
.header-actions-block { display: flex; align-items: center; gap: 20px; }
.orange-booking-btn { background: #ff5722; color: #fff; border: none; padding: 8px 16px; font-size: 13px; font-weight: 700; border-radius: 6px; cursor: pointer; transition: all 0.2s ease; white-space: nowrap; }
.header-phone-wrapper { display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 700; color: #1e1e24; }
.header-phone-wrapper a { text-decoration: none; color: #1e1e24; }

/* 1. Адаптация для ПЛАНШЕТОВ (Экраны до 1024px) */
@media (max-width: 1024px) {
    body { padding-top: 155px !important; }
    .container { width: 100% !important; max-width: 100% !important; padding: 0 15px !important; box-sizing: border-box !important; }
    
    .header-user-block { min-width: auto; gap: 15px; }
    .header-nav-menu-list { gap: 14px; font-size: 13px; }
    .header-actions-block { gap: 10px; }
    
    .products-grid, .catalog-grid { grid-template-columns: repeat(2, 1fr) !important; gap: 15px !important; width: 100% !important; }
    .catalog-container, .cart-wrapper, .profile-wrapper { grid-template-columns: 1fr !important; gap: 20px !important; }
    .sidebar-filters { position: static !important; max-height: none !important; width: 100% !important; }
    .promo-grid { grid-template-columns: 1fr !important; width: 100% !important; }
    
    /* Уничтожаем жесткие распорки виджетов подбора, которые ломали экран */
    .search-widget-container { flex-direction: column !important; gap: 20px !important; width: 100% !important; }
    .search-widget-box { width: 100% !important; min-width: 0 !important; max-width: 100% !important; }
    .hero-slide-content { max-width: 100% !important; text-align: center !important; }
}

/* 2. Адаптация для СМАРТФОНОВ (Экраны до 768px) */
@media (max-width: 768px) {
    body { padding-top: 135px !important; }
    
    /* ЖЕЛЕЗНО: Поднимаем весь каркас шапки над виджетами и слайдером главной страницы */
    .fixed-header-wrapper { 
        z-index: 9999999 !important; 
        position: fixed !important;
    }
    
    .icon-text, .header-phone-wrapper { display: none !important; }
    .header-logo-block a { font-size: 20px; }
    
    /* Включаем бургер-кнопку на флексах */
    .mobile-burger-btn { display: flex !important; }
    
    .main-header-row { padding: 10px 0 !important; }
    .header-search-block { max-width: none !important; order: 3; width: 100% !important; margin-top: 5px; }
    .header-main-container { flex-wrap: wrap; gap: 8px; }
    
    /* Шторка навигации */
    .header-navigation-row {
        display: none; /* Управляется скриптом по клику на бургер */
        position: absolute !important;
        
        /* Точный отступ от верха, чтобы встать ровно под поиском */
        top: 100% !important; 
        left: 0 !important;
        width: 100% !important;
        background: #ffffff !important;
        box-shadow: 0 15px 25px rgba(0,0,0,0.15) !important;
        border-bottom: 4px solid #ff5722 !important;
        
        /* Выставляем максимальный слой внутри открытого каркаса */
        z-index: 99999999 !important; 
    }


    .header-nav-container { flex-direction: column !important; gap: 15px !important; align-items: stretch !important; }
    .header-nav-menu-list { flex-direction: column !important; align-items: center !important; gap: 12px !important; width: 100% !important; }
    .header-nav-menu-list li { width: 100% !important; text-align: center !important; }
    .header-nav-menu-list li a { display: block !important; padding: 6px 0 !important; font-size: 15px !important; width: 100% !important; }
    .header-actions-block { width: 100% !important; justify-content: center !important; }
    .orange-booking-btn { width: 100% !important; max-width: 280px !important; height: 42px !important; font-size: 14px !important; }

    .products-grid, .catalog-grid { grid-template-columns: 1fr !important; width: 100% !important; }
    .product-card { padding: 15px !important; width: 100% !important; }
    
    /* Обрезка вылетов в слайдере */
    .hero-section { min-height: 400px !important; }
    .hero-slide-title { font-size: 24px !important; }
    .hero-slide-subtitle { font-size: 14px !important; }
}

