/* ---------------------------------------------------- */
/* 1. БАЗОВЫЕ СТИЛИ: СБРОС */
/* ---------------------------------------------------- */
html,
body {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    scroll-behavior: smooth;
    background-color: #000;
}

/* ---------------------------------------------------- */
/* 2. КОНТЕЙНЕР: ГЛАВНЫЙ ЭЛЕМЕНТ ПРОКРУТКИ */
/* ---------------------------------------------------- */
.sections-container {
    width: 100%;
    height: 100vh;
    overflow-y: scroll;
    scroll-snap-type: y mandatory;
    display: flex;
    flex-direction: column;
    align-items: stretch;
}

/* ---------------------------------------------------- */
/* 3. СЕКЦИИ: ВЫСОТА, ПРИВЯЗКА И ЗАПРЕТ СЖАТИЯ */
/* ---------------------------------------------------- */
.section {
    width: 100%;
    height: 100vh;
    flex-shrink: 0;
    position: relative;
    scroll-snap-align: start;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: white;
    font-family: sans-serif;
    overflow: hidden;

    /* Общие стили для фона */
    background-position: center center;
    background-repeat: no-repeat;
    background-size: cover;
}

/* ---------------------------------------------------- */
/* 4. АНИМАЦИЯ ФОНОВЫХ ИЗОБРАЖЕНИЙ */
/* ---------------------------------------------------- */
.section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-position: center center;
    background-repeat: no-repeat;
    background-size: cover;
    transition: transform 4s ease-out;
    z-index: 1;
}

/* Начальное состояние - изображение увеличено */
.section:not(.active)::before {
    transform: scale(1.05);
}

/* Когда секция активна - изображение возвращается к нормальному размеру */
.section.active::before {
    transform: scale(1);
}

/* Устанавливаем фоновые изображения для псевдоэлементов */
#section-1::before {
    background-image: url('public/mk-ch-2.jpg');
}

#section-2::before {
    background-image: url('public/mk-kal-1.jpg');
}

#section-3::before {
    background-image: url('public/fun-kal-1.jpg');
}

#section-4::before {
    background-image: url('public/geo-kal-1.jpg');
}

#section-5::before {
    background-image: url('public/rec-zol-1.jpg');
}

#section-6::before {
    background-image: url('public/Chub11-web.jpg');
}

#section-poslugi::before {
    background-image: url('public/35.jpg');
}


#section-metall::before {
    background-image: url('public/mk-ch-1.jpg');
}

/* Убираем фоновые изображения у самих секций */
.section {
    background-image: none !important;
}

/* ---------------------------------------------------- */
/* 5. СТИЛИ КОНТЕНТА */
/* ---------------------------------------------------- */
.content {
    color: #ffffff;
    font-family: Arial;
    font-weight: 400;
    position: relative;
    z-index: 10;
    line-height: 1.12;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    text-align: left;
    margin-left: 20px;
    margin-right: auto;
    margin-top: 0;
    margin-bottom: 0;
    max-width: 80%;
    padding: 20px;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 5px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.content h1 {
    font-size: clamp(1.3rem, 4vw, 3rem);
    font-weight: 400;
    margin: 0;
    line-height: 1.2;
}

.content h2 {
    font-size: clamp(1.3rem, 4vw, 3rem);
    font-weight: 400;
    margin: 0;
    line-height: 1.2;
}

.content p a {
    display: inline-block;
    position: relative;
    font-size: clamp(1.0rem, 4vw, 1.2rem);
    text-decoration: none;
    color: inherit;
    padding: 5px 0;
    border-bottom: 1px solid transparent;
    transition: border-color 0.3s;
}

.content-link {
    position: relative;
    z-index: 1000;
    pointer-events: auto !important;
}

.button-onContent {
    display: inline-flex;
    text-align: center;
    margin: 0px;
    padding: 10px 20px;
    /* Увеличил padding для лучшего визуального эффекта */
    background: rgba(0, 0, 0, 0.3);
    border-radius: 3px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    /* Дополнительно: добавьте transition для плавного изменения цвета */
    transition: background 0.3s ease;
}

/* Правило для наведения */
.button-onContent:hover {
    /* Меняем только цвет фона, сохраняя все остальные свойства (включая размеры, которые определяются padding) */
    background: rgba(30, 144, 255, 0.7); 
}




.button-onContent p {
    font-size: clamp(1.0rem, 4vw, 1.2rem);
    margin: 0;
    /* Убираем стандартные отступы у параграфа */
}





/* Дополнительно: Если ты хочешь, чтобы при наведении цвет оставался белым */
.content p a:hover,
.content p a:focus,
.content p a:active,
.content p a:visited {
    color: inherit;
    text-decoration: none;
}

/* ---------------------------------------------------- */
/* 6. СТИЛИ ДЛЯ HEADER */
/* ---------------------------------------------------- */
#site-header {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 10000;
    transform: translateY(0);
    transition: transform 0.6s ease-out;
    background: rgba(18, 18, 18, 0.85);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    font-family: sans-serif;
    color: white;
}

#site-header.hidden {
    transform: translateY(-100%);
}

.header-content {
    display: flex;
    justify-content: space-around;
    align-items: center;
    max-width: auto;
    margin: 0 auto;
    padding-top: 20px;
    padding-bottom: 20px;    
}

header-content nav {
    display: flex;
    gap: 15px;
}

.header-content a {
    color: white;
    text-decoration: none;
    padding: 0 10px;
    font-size: 1rem;
    font-weight: 500;
    padding: 15px 10px;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 3px;
    margin-right: 3px;
}

/* Эффект наведения */
.header-content a:hover {
    background: rgba(30, 144, 255, 0.7);
    padding: 15px 10px;
    transform: scale(1.02);
    cursor: pointer;
}

.header-content .logo {
    font-size: 1.3rem;
    font-weight: bold;
    letter-spacing: 1px;
    text-align: left;
}

/* Медиазапросы для адаптивности */
@media (max-width: 768px) {
    .header-content {
        flex-wrap: wrap;
    }

    .header-content nav {
        display: flex;
        width: 100%;
        margin: 5px;
        justify-content: space-between;
    }

    .header-content a {
        font-size: 0.8rem;
        padding: 0 5px;
    }

    /* Эффект наведения */
    .header-content a:hover {
        background: rgba(30, 144, 255, 0.7);
        padding: 5px 2px;
        transform: scale(1.02);
        cursor: pointer;
    }

    .header-content .logo {
        width: 100%;
        font-size: 1.0rem;
        margin-left: 5px;
    }

    .language-switcher {
        width: 100%;
        margin-left: 5px;
    }
}

@media (max-width: 480px) {
    .header-content a {
        flex-wrap: wrap;
        font-size: 0.8rem;
    }

    .header-content nav {
        display: flex;
        width: 100%;
        margin: 5px;
        justify-content: space-between;
    }

    .header-content .logo {
        width: 100%;
        font-size: 0.8rem;
        margin-left: 5px;
    }

    .language-switcher {
        width: 100%;
        margin-left: 10px;
    }
}