/* Плавная прокрутка для навигации */
html {
    scroll-behavior: smooth;
}

/* Стили навигации */
nav {
    transition: background-color 0.3s ease;
}

nav.scrolled {
    background-color: #1F2937;
    backdrop-filter: blur(8px);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

/* Стили для пунктов меню с анимацией подчеркивания только для текста */
.nav-links a {
    display: inline-flex;
    align-items: center;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: #FF9999; /* Светлее #C54242 */
}

.nav-links a span {
    position: relative;
}

.nav-links a span::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -2px;
    left: 0;
    background-color: #FF9999;
    transition: width 0.3s ease;
}

.nav-links a:hover span::after {
    width: 100%;
}

/* Стили бургер-меню */
.burger-menu {
    display: none;
    cursor: pointer;
    position: relative;
    z-index: 60;
}

.burger-menu div {
    width: 30px;
    height: 4px;
    background-color: #fff;
    margin: 6px 0;
    border-radius: 2px;
    transition: all 0.4s ease;
}

.nav-links {
    transition: all 0.4s ease-in-out;
}

@media (max-width: 768px) {
    .burger-menu {
        display: block;
    }

    .nav-links {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background: rgba(31, 41, 55, 0.95);
        backdrop-filter: blur(8px); /* Размытие заднего фона */
        flex-direction: column;
        align-items: center;
        justify-content: center;
        transform: translateY(-100%);
        opacity: 0;
        z-index: 50;
    }

    .nav-links.active {
        transform: translateY(0);
        opacity: 1;
    }

    .nav-links li {
        margin: 30px 0;
        text-align: center;
        width: 100%;
    }

    .nav-links a {
        font-size: 1.5rem; /* Увеличенный шрифт для модального окна */
    }

    /* Анимация бургер-меню (без крестика) */
    .burger-menu.active .line1 {
        transform: translateY(10px);
    }

    .burger-menu.active .line2 {
        opacity: 0;
    }

    .burger-menu.active .line3 {
        transform: translateY(-10px);
    }
}

/* Анимация кнопки */
.animated-button {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* Стили аккордеона */
.accordion-item {
    border-bottom: 1px solid #4B5563;
}

.accordion-header {
    cursor: pointer;
    padding: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background-color 0.3s ease;
}

.accordion-header:hover {
    background-color: #2D3748;
}

.accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.8s cubic-bezier(0.25, 0.8, 0.25, 1), padding 0.8s cubic-bezier(0.25, 0.8, 0.25, 1), opacity 0.8s ease;
    padding: 0 1rem;
    opacity: 0;
}

.accordion-content.active {
    max-height: 400px;
    padding: 1rem;
    opacity: 1;
}