/* ==========================================================================
   1. HERO SECTION — CLEAN INDUSTRIAL BANNER (Широкоформатный ПК-вариант)
   ========================================================================== */
.hero-section {
    position: relative;
    min-height: 650px; 
    padding: 100px 0;
    display: flex;
    align-items: center;
    overflow: hidden;
    background-color: #0a0e17;
}

/* Контейнеры и слайдер фонов */
.hero-backgrounds {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.hero-bg-item {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1.5s ease-in-out;
}

.hero-bg-item.active {
    opacity: 1;
}

/* Равномерный индустриальный градиент по всей площади для идеального чтения текста */
.hero-gradient {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%; 
    height: 100%;
    background: linear-gradient(180deg, 
        rgba(10, 14, 23, 0.75) 0%, 
        rgba(10, 14, 23, 0.90) 100%
    );
    z-index: 2; 
}

.hero-container {
    position: relative;
    z-index: 10;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Растянутый по центру контент-блок (убран левый борт для ПК) */
.hero-content {
    max-width: 100% !important;
    width: 100%;
    text-align: center;
    border-left: none !important;
    padding-left: 0 !important; 
    margin: 0 auto;
    animation: fadeInHero 0.9s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}

.hero-title {
    font-family: var(--font-heading) !important;
    font-size: clamp(34px, 5vw, 56px) !important; /* Оптимальный читаемый размер во всю ширину */
    font-weight: 800 !important;
    line-height: 1.15 !important;
    text-transform: uppercase;
    color: #ffffff !important;
    margin: 0 auto 25px !important;
    letter-spacing: 1px;
}

.hero-title .red-text {
    color: var(--accent-color) !important;
    text-shadow: 0 0 25px rgba(255, 46, 0, 0.45);
}

.hero-subtitle {
    font-family: var(--font-body) !important;
    font-size: 19px !important;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.75) !important;
    margin: 0 auto 40px !important;
    font-weight: 400;
    max-width: 850px; /* Ограничение длины строки для удобства чтения */
}

/* Кнопки Hero-секции */
.hero-btns {
    display: flex;
    gap: 20px;
    align-items: center;
    justify-content: center; /* Центрирование кнопок */
    max-width: 500px;
    margin: 0 auto;
}

.btn-main, .btn-outline {
    padding: 16px 34px;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 15px;
    text-transform: uppercase;
    text-decoration: none !important;
    border-radius: 4px; 
    letter-spacing: 1px;
    transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
    display: inline-block;
}

.btn-main {
    background: var(--accent-color) !important;
    color: #fff !important;
    border: 2px solid var(--accent-color) !important;
    box-shadow: 0 4px 15px rgba(255, 46, 0, 0.3);
}

.btn-main:hover {
    background: transparent !important; 
    color: var(--accent-color) !important;
    box-shadow: 0 0 20px rgba(255, 46, 0, 0.2);
}

.btn-outline {
    border: 2px solid rgba(255, 255, 255, 0.2) !important; 
    color: #fff !important;
}

.btn-outline:hover {
    border-color: #fff !important;
    background: rgba(255, 255, 255, 0.05);
}

/* Анимация проявления по центру */
@keyframes fadeInHero {
    from { opacity: 0; transform: translateY(15px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Мобильная адаптивность для центрированного баннера */
@media (max-width: 768px) {
    .hero-section { 
        min-height: auto;
        padding: 60px 0; 
    }
    .hero-gradient {
        background: linear-gradient(180deg, rgba(10,14,23,0.5) 0%, rgba(10,14,23,0.98) 100%);
    }
    .hero-title {
        font-size: 32px !important;
    }
    .hero-subtitle {
        font-size: 16px !important;
    }
    .hero-btns {
        flex-direction: column;
        align-items: stretch; 
        width: 100%;
    }
}


/* ==========================================================================
   2. PRODUCTS GRID & LIQUID GLASS CARDS (Адаптивная карусель и сетка)
   ========================================================================== */

/* Контейнер-обертка для карусели (нужен для стрелок) */
.carousel-wrapper {
    position: relative;
    width: 100%;
}

/* Базовая сетка продуктов на ПК (по умолчанию 3 в ряд) */
.products-grid {
    display: flex;
    flex-direction: row;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    gap: 30px;
    padding: 15px 5px 30px 5px;
    -webkit-overflow-scrolling: touch;
}

/* Скрываем скроллбар во всех браузерах */
.products-grid::-webkit-scrollbar {
    display: none;
}
.products-grid {
    -ms-overflow-style: none;  /* IE/Edge */
    scrollbar-width: none;  /* Firefox */
}

/* Настройка карточки внутри карусели на ПК */
.products-grid .product-card {
    flex: 0 0 calc(33.333% - 20px); /* Строго 3 карточки на экране ПК */
    scroll-snap-align: start;
    min-width: 290px;
    
    position: relative;
    background: rgba(255, 255, 255, 0.02); 
    backdrop-filter: var(--blur-heavy);
    -webkit-backdrop-filter: var(--blur-heavy);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1);
}

.product-card:hover {
    transform: translateY(-6px);
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 46, 0, 0.4); 
    box-shadow: 
        0 15px 35px rgba(0, 0, 0, 0.6),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

/* Ограничение для картинок внутри карточек */
.product-image {
    background: rgba(255, 255, 255, 0.03); 
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    height: 220px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
}

.product-image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 5px 15px rgba(0,0,0,0.5));
}

.product-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    background-color: var(--accent-color);
    color: #fff;
    padding: 4px 10px;
    font-size: 11px;
    font-family: var(--font-heading);
    font-weight: 700;
    border-radius: 3px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(255, 46, 0, 0.4);
    z-index: 3;
}

.product-info {
    padding: 25px 20px 20px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    text-align: center;
}

.product-title {
    font-family: var(--font-heading);
    font-size: 19px;
    margin: 0 0 12px;
    color: #fff;
    font-weight: 500;
    line-height: 1.3;
}

.product-price {
    font-family: var(--font-heading);
    font-size: 24px;
    color: var(--accent-color); 
    font-weight: 700;
    margin-top: auto; 
    margin-bottom: 20px;
    text-shadow: 0 0 10px rgba(255, 46, 0, 0.2);
}

.product-btn {
    width: 100%;
    padding: 12px;
    background-color: transparent;
    border: 2px solid var(--accent-color);
    color: #fff;
    font-family: var(--font-heading);
    font-weight: 600;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 4px;
    letter-spacing: 0.5px;
}

.product-btn:hover {
    background-color: var(--accent-color);
    color: #fff;
    box-shadow: 0 0 15px var(--accent-glow);
}

/* Стрелки навигации для ПК-версии */
.carousel-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 45px;
    height: 45px;
    background: rgba(10, 14, 23, 0.8);
    backdrop-filter: var(--blur-medium);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0,0,0,0.5);
}

.carousel-arrow:hover {
    border-color: var(--accent-color);
    color: var(--accent-color);
    box-shadow: 0 0 15px var(--accent-glow);
}

.carousel-arrow.prev { left: -25px; }
.carousel-arrow.next { right: -25px; }


/* ==========================================================================
   3. RESPONSIVE MEDIA QUERIES (МОБИЛЬНАЯ ВЕРСИЯ)
   ========================================================================== */
@media (max-width: 768px) {
    .hero-section { 
        min-height: auto;
        padding: 60px 0; 
    }
    
    .hero-gradient {
        background: linear-gradient(180deg, 
            rgba(10,14,23,0.4) 0%, 
            rgba(10,14,23,0.98) 100%
        );
    }

    .hero-content {
        border-left: none; 
        border-top: 4px solid var(--accent-color); 
        padding-left: 0;
        padding-top: 25px;
    }

    .hero-btns {
        flex-direction: column;
        align-items: stretch; 
    }
    
    .btn-main, .btn-outline { text-align: center; }
    
    /* Стрелки убираем — на мобилке листаем пальцем */
    .carousel-arrow { 
        display: none !important; 
    }
    
    /* Мобильный свайп-ряд (Исправленные адаптивные отступы) */
    .products-grid {
        gap: 20px;
        padding: 10px 20px 30px 20px;
        margin-left: -20px;  
        margin-right: -20px;
    }

    /* Настройка мобильной карточки (чтобы не сжималась) */
    .products-grid .product-card {
        flex: 0 0 82%; /* Возвращаем правильный объём под пальцевый свайп */
        scroll-snap-align: center;
        max-width: 300px;
        min-width: 260px;
    }
    
    .products-grid .product-image {
        height: 180px;
    }
    
    .products-grid .product-title {
        font-size: 17px;
    }
}
}
/* Класс для плавного скрытия стрелок карусели */
.carousel-arrow.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none; /* Чтобы нельзя было кликнуть по невидимой стрелке */
}