/* components\header\header.css */

.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    transition: all 0.3s ease;
    background: transparent;
    border-bottom: 1px solid var(--card-border);
    animation: slideDownFadeIn 0.5s ease-out;
}

@keyframes slideDownFadeIn {
    from {
        opacity: 0;
        transform: translateY(-100%);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.header.scrolled {
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(20px);
    box-shadow: var(--shadow-lg);
    border-bottom-color: rgba(255, 255, 255, 0.15);
}

.header__container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 40px;
    max-width: 1440px;
    margin: 0 auto;
    transition: padding 0.3s ease;
}

.header.scrolled .header__container {
    padding: 16px 40px;
}

.header__logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 28px;
    font-weight: 800;
    color: var(--white);
    z-index: 1001;
    letter-spacing: -1px;
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
    animation: fadeInScale 0.4s ease-out 0.2s both;
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.header__logo::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-gradient);
    transition: width 0.3s ease;
}

.header__logo:hover::after {
    width: 100%;
}

.header__logo:hover {
    transform: scale(1.05);
    text-shadow: 0 2px 12px rgba(255, 255, 255, 0.15);
}

.header__logo-text {
    color: var(--white);
}

.header__nav {
    display: flex;
    align-items: center;
    gap: 48px;
}

.header__menu {
    display: flex;
    align-items: center;
    gap: 40px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.header__menu-item {
    position: relative;
    animation: fadeInUp 0.35s ease-out both;
}

.header__menu-item:nth-child(1) { animation-delay: 0.25s; }
.header__menu-item:nth-child(2) { animation-delay: 0.3s; }
.header__menu-item:nth-child(3) { animation-delay: 0.35s; }
.header__menu-item:nth-child(4) { animation-delay: 0.4s; }
.header__menu-item:nth-child(5) { animation-delay: 0.45s; }

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.header__menu-link {
    color: var(--white);
    font-size: 15px;
    font-weight: 600;
    position: relative;
    padding: 8px 0;
    text-decoration: none;
    transition: all 0.3s ease;
}

.header__menu-link::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    transition: all 0.4s ease;
    z-index: -1;
}

.header__menu-link:hover::before {
    width: 120%;
    height: 200%;
}

.header__menu-link:hover {
    color: var(--gray-100);
}

.header__menu-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-gradient);
    transition: width 0.3s ease;
}

.header__menu-link:hover::after,
.header__menu-link.active::after {
    width: 100%;
}

.header__menu-link.active {
    color: var(--white);
}

.header__burger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: transparent;
    border: none;
    padding: 8px;
    cursor: pointer;
    z-index: 1001;
    transition: transform 0.3s ease;
}

.header__burger:hover {
    transform: scale(1.1);
}

.header__burger-line {
    width: 28px;
    height: 3px;
    background: var(--white);
    border-radius: 2px;
    transition: all 0.3s ease;
}

.header__burger:hover .header__burger-line {
    background: var(--gray-200);
}

.header__burger.active .header__burger-line:nth-child(1) {
    transform: rotate(45deg) translate(7px, 7px);
}

.header__burger.active .header__burger-line:nth-child(2) {
    opacity: 0;
}

.header__burger.active .header__burger-line:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

/* Переключатель языков */
.header__lang-switch {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-left: 20px;
    background-color: #0000002c;
}

.header__mobile-lang {
    display: none;
}

.lang-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    font-size: 12px;
    font-weight: 700;
    color: #fff;
    text-decoration: none;
    transition: all 0.3s ease;
    text-transform: uppercase;
}

.lang-link:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--white);
}

.lang-link--active {
    background: var(--accent-gradient);
    color: #363636;
    border-color: transparent;
    pointer-events: none;
}

@media (max-width: 1024px) {
    .header__menu {
        gap: 24px;
    }
    
    .header__nav {
        gap: 32px;
    }
}

@media (max-width: 768px) {
    .header__container {
        padding: 16px 20px;
    }
    
    .header.scrolled .header__container {
        padding: 14px 20px;
    }
    
    .header__burger {
        display: flex;
        animation: fadeInScale 0.4s ease-out 0.2s both;
    }
    
    .header__nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 100%;
        height: 100vh;
        background: rgba(0, 0, 0, 0.98);
        backdrop-filter: blur(20px);
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 80px 32px 32px;
        gap: 48px;
        transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        overflow-y: auto;
    }
    
    .header__nav.active {
        right: 0;
    }
    
    .header__menu {
        flex-direction: column;
        align-items: center;
        gap: 32px;
        width: 100%;
    }
    
    .header__menu-item {
        animation: none;
    }
    
    .header__menu-link {
        font-size: 24px;
        width: 100%;
        text-align: center;
        padding: 12px 0;
    }

    .header__menu-link:hover {
        transform: scale(1.05);
    }

    .header__lang-switch {
        display: none;
    }

    .header__mobile-lang {
        display: flex;
        gap: 15px;
        margin-top: 20px;
        padding-top: 20px;
        border-top: 1px solid rgba(255, 255, 255, 0.1);
        width: 100%;
        justify-content: center;
    }

    .header__mobile-lang .lang-link {
        width: 44px;
        height: 44px;
        font-size: 14px;
    }
}