/* ОБЩИЕ СТИЛИ И ОБНУЛЕНИЕ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    scroll-behavior: smooth;
}

:root {
    --bg-dark: #0a0a12;
    --bg-card: #121225;
    --neon-purple: #bc00dd;
    --neon-blue: #00f0ff;
    --text-white: #ffffff;
    --text-gray: #a5a5c5;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-white);
    line-height: 1.6;
}

.container {
    width: 85%;
    max-width: 1200px;
    margin: 0 auto;
}

/* ШАПКА И НАВИГАЦИЯ */
header {
    background: rgba(10, 10, 18, 0.9);
    backdrop-filter: blur(10px);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(188, 0, 221, 0.2);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
}

/* СТИЛИ ЛОГОТИПА С КАРТИНКОЙ */
.logo-container {
    display: flex;
    align-items: center;
    gap: 10px;
}

.site-logo {
    height: 42px;
    width: auto;
    object-fit: contain;
    mix-blend-mode: screen; 
    filter: drop-shadow(0 0 8px var(--neon-blue));
}

.logo-text {
    font-size: 24px;
    font-weight: bold;
    letter-spacing: 2px;
    color: var(--text-white);
}

.logo-text span {
    color: var(--neon-blue);
    text-shadow: 0 0 10px var(--neon-blue);
}

.nav-links {
    display: flex;
    list-style: none;
    align-items: center;
}

.nav-links li {
    margin-left: 30px;
}

.nav-links a {
    color: var(--text-gray);
    text-decoration: none;
    font-size: 16px;
    transition: 0.3s;
}

.nav-links a:hover {
    color: var(--neon-purple);
    text-shadow: 0 0 8px var(--neon-purple);
}

/* РАСКРЫВАЮЩЕЕСЯ МЕНЮ ПРОДУКТЫ */
.dropdown {
    position: relative;
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: var(--bg-card);
    min-width: 200px;
    box-shadow: 0px 8px 16px rgba(0,0,0,0.5);
    border: 1px solid var(--neon-purple);
    border-radius: 8px;
    
    /* ИСПРАВЛЕНИЕ: */
    top: 100%; /* Окно начнется ровно там, где заканчивается ссылка */
    left: 0;
    margin-top: 0; /* Убрали отступ, который создавал дыру для мышки */
    
    z-index: 1;
    overflow: hidden;
}

.dropdown-content a {
    color: var(--text-white);
    padding: 12px 16px;
    display: block;
    font-size: 15px;
}

.dropdown-content a:hover {
    background: linear-gradient(90deg, rgba(188,0,221,0.2), rgba(0,240,255,0.2));
    color: var(--neon-blue);
}

.dropdown:hover .dropdown-content {
    display: block;
}

/* ГЛАВНЫЙ ЭКРАН */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    overflow: hidden;
    padding-top: 80px;
}

.hero-glow {
    position: absolute;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(188,0,221,0.3) 0%, rgba(0,240,255,0.1) 50%, rgba(0,0,0,0) 100%);
    filter: blur(50px);
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero h1 {
    font-size: 56px;
    margin-bottom: 20px;
    letter-spacing: 1px;
}

.hero p {
    font-size: 20px;
    color: var(--text-gray);
    max-width: 600px;
    margin: 0 auto 40px auto;
}

.neon-text-blue {
    color: var(--neon-blue);
    text-shadow: 0 0 15px var(--neon-blue);
}

/* КНОПКА НЕОН */
.btn-neon {
    display: inline-block;
    padding: 12px 35px;
    border: 2px solid var(--neon-purple);
    color: var(--text-white);
    text-decoration: none;
    font-weight: bold;
    border-radius: 30px;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: 0.4s;
    box-shadow: 0 0 10px rgba(188, 0, 221, 0.3);
    cursor: pointer;
    background: transparent;
}

.btn-neon:hover {
    background: var(--neon-purple);
    box-shadow: 0 0 25px var(--neon-purple);
}

/* ЗАГОЛОВКИ СЕКЦИЙ */
.section-title {
    text-align: center;
    font-size: 36px;
    margin-bottom: 60px;
    position: relative;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: var(--neon-blue);
    box-shadow: 0 0 10px var(--neon-blue);
    margin: 10px auto 0 auto;
}

/* СЕКЦИЯ: О НАС */
.about-section, .privacy-section, .contacts-section {
    padding: 100px 0;
}

.about-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.about-card {
    background: var(--bg-card);
    padding: 40px 30px;
    border-radius: 12px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: 0.3s ease-in-out;
}

.about-card:hover {
    transform: translateY(-10px);
    border-color: var(--neon-blue);
    box-shadow: 0 5px 20px rgba(0, 240, 255, 0.2);
}

.card-icon {
    font-size: 40px;
    color: var(--neon-purple);
    text-shadow: 0 0 10px var(--neon-purple);
    margin-bottom: 20px;
}

.about-card h3 {
    margin-bottom: 15px;
    font-size: 22px;
}

.about-card p {
    color: var(--text-gray);
    font-size: 15px;
}

/* СЕКЦИЯ: КОНФИДЕНЦИАЛЬНОСТЬ */
.privacy-section {
    background: rgba(18, 18, 37, 0.4);
}

.lang-switcher {
    display: flex;
    justify-content: center;
    margin-bottom: 40px;
    gap: 15px;
}

.lang-btn {
    padding: 8px 20px;
    border: 1px solid var(--text-gray);
    background: transparent;
    color: var(--text-white);
    cursor: pointer;
    border-radius: 5px;
    transition: 0.3s;
}

.lang-btn.active, .lang-btn:hover {
    border-color: var(--neon-blue);
    color: var(--neon-blue);
    box-shadow: 0 0 10px rgba(0, 240, 255, 0.3);
}

.privacy-content {
    background: var(--bg-card);
    border: 1px solid rgba(188, 0, 221, 0.1);
    border-radius: 12px;
    padding: 40px;
    max-height: 500px;
    overflow-y: auto;
}

.privacy-content::-webkit-scrollbar {
    width: 6px;
}
.privacy-content::-webkit-scrollbar-thumb {
    background: var(--neon-purple);
    border-radius: 4px;
}

.lang-content {
    display: none;
}

.lang-content.active {
    display: block;
}

.privacy-content h3 {
    margin-bottom: 10px;
    color: var(--neon-blue);
}

.privacy-content .date {
    font-style: italic;
    color: var(--text-gray);
    margin-bottom: 20px;
}

.privacy-content h4 {
    margin-top: 25px;
    margin-bottom: 10px;
    color: var(--neon-purple);
}

.privacy-content p {
    color: var(--text-gray);
    margin-bottom: 15px;
    font-size: 15px;
}

/* СЕКЦИЯ: КОНТАКТЫ */
.contacts-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
}

.contact-info h3 {
    font-size: 28px;
    margin-bottom: 20px;
}

.contact-info p {
    color: var(--text-gray);
    margin-bottom: 30px;
}

.info-item {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.info-item i {
    font-size: 20px;
    color: var(--neon-blue);
    margin-right: 15px;
    width: 25px;
}

.contact-form form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.contact-form input, .contact-form textarea {
    background: #171730;
    border: 1px solid rgba(255,255,255,0.1);
    padding: 15px;
    border-radius: 8px;
    color: var(--text-white);
    font-size: 16px;
    transition: 0.3s;
}

.contact-form input:focus, .contact-form textarea:focus {
    outline: none;
    border-color: var(--neon-blue);
    box-shadow: 0 0 10px rgba(0, 240, 255, 0.2);
}

/* ПОДВАЛ */
footer {
    border-top: 1px solid rgba(255,255,255,0.05);
    padding: 30px 0;
    text-align: center;
    background: #07070d;
}

footer p {
    color: var(--text-gray);
    font-size: 14px;
}

/* ОБНОВЛЕННАЯ СТРУКТУРА НАВИГАЦИИ */
nav {
    display: flex;
    align-items: center;
}

.nav-static {
    display: flex;
    list-style: none;
    align-items: center;
    margin-left: 20px;
}

.nav-static li {
    margin-left: 20px;
}

.mobile-menu-icon {
    display: none;
    font-size: 24px;
    color: var(--text-white);
    cursor: pointer;
    transition: 0.3s;
}

.mobile-menu-icon:hover {
    color: var(--neon-blue);
}

/* МОБИЛЬНАЯ СТИЛИЗАЦИЯ ДЛЯ ЭКРАНОВ ДО 768px */
@media (max-width: 768px) {
    .navbar {
        padding: 10px 0;
    }

    .mobile-menu-icon {
        display: block; /* Показываем иконку бургера */
        margin-right: 15px;
    }

    /* Прячем изменяемое меню и превращаем его в выпадающую панель */
    .nav-links {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(18, 18, 37, 0.98);
        border-bottom: 2px solid var(--neon-purple);
        padding: 20px 0;
        box-shadow: 0 10px 20px rgba(0,0,0,0.5);
    }

    .nav-links.mobile-active {
        display: flex; /* Показывается при клике на бургер */
    }

    .nav-links li {
        margin: 15px 0;
        text-align: center;
        width: 100%;
    }

    .dropdown-content {
        position: relative;
        top: 10px;
        box-shadow: none;
        background: rgba(255, 255, 255, 0.02);
        margin: 0 auto;
        min-width: 80%;
    }

    /* Оставляем контакты и переключатель языков на месте */
    .nav-static {
        margin-left: 0;
    }

    .nav-static li {
        margin-left: 15px;
    }

    .logo-text {
        font-size: 20px;
    }

    .site-logo {
        height: 32px;
    }

    /* Адаптация контента сайта */
    .hero h1 {
        font-size: 32px;
    }
    
    .hero p {
        font-size: 16px;
    }

    .contacts-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

/* СТИЛИ ДЛЯ ОТДЕЛЬНОЙ СТРАНИЦЫ КОНФИДЕНЦИАЛЬНОСТИ */
.privacy-page {
    padding-top: 100px;
}

.privacy-document-section {
    padding: 60px 0;
    min-height: calc(100vh - 240px);
}

.privacy-render-content {
    background: var(--bg-card);
    border: 1px solid rgba(188, 0, 221, 0.15);
    border-radius: 12px;
    padding: 50px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

/* Стилизация элементов, которые приходят из Markdown */
.privacy-render-content h1 {
    color: var(--neon-blue);
    font-size: 32px;
    margin-bottom: 10px;
    text-shadow: 0 0 10px rgba(0, 240, 255, 0.2);
}

.privacy-render-content h3 {
    color: var(--neon-purple);
    font-size: 22px;
    margin-top: 35px;
    margin-bottom: 15px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    padding-bottom: 5px;
}

.privacy-render-content p {
    color: var(--text-gray);
    font-size: 16px;
    margin-bottom: 15px;
}

.privacy-render-content ul {
    margin-left: 20px;
    margin-bottom: 20px;
    color: var(--text-gray);
}

.privacy-render-content li {
    margin-bottom: 8px;
}

.privacy-render-content strong {
    color: var(--text-white);
}

@media (max-width: 768px) {
    .privacy-render-content {
        padding: 25px;
    }
}

/* ПЕРЕКЛЮЧАТЕЛЬ ЯЗЫКОВ В МЕНЮ */
.site-lang-switcher {
    display: flex;
    gap: 8px;
    margin-left: 40px;
    border-left: 1px solid rgba(255, 255, 255, 0.1);
    padding-left: 15px;
}

.lang-tab {
    font-size: 13px;
    font-weight: bold;
    color: var(--text-gray);
    cursor: pointer;
    transition: 0.3s;
    padding: 2px 6px;
    border-radius: 4px;
}

.lang-tab:hover {
    color: var(--neon-blue);
}

.lang-tab.active {
    color: var(--bg-dark);
    background: var(--neon-blue);
    box-shadow: 0 0 10px var(--neon-blue);
}

/* Корректировка для мобильных устройств */
@media (max-width: 768px) {
    .site-lang-switcher {
        margin-left: 0;
        margin-top: 10px;
        border-left: none;
        padding-left: 0;
    }
}

/* ИДЕАЛЬНОЕ ВЫРАВНИВАНИЕ ЛОГОТИПА И ТЕКСТА ПО ЦЕНТРУ */
.dropdown-content a.dropdown-item-happ {
    display: flex !important;
    align-items: center !important; /* Выравнивает иконку и текст строго по вертикали */
    justify-content: flex-start !important;
    gap: 12px !important;
    padding: 12px 16px;
    text-decoration: none;
}

.dropdown-content a.dropdown-item-happ img.submenu-logo {
    display: block !important;
    height: 24px !important;
    width: 24px !important;
    max-height: 24px !important;
    max-width: 24px !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    border: 1px solid rgba(0, 240, 255, 0.3) !important;
    margin: 0 !important; /* Убираем любые дефолтные отступы */
}

.dropdown-content a.dropdown-item-happ span {
    display: inline-block !important;
    line-height: 24px !important; /* Высота строки совпадает с высотой иконки */
}

.submenu-logo {
    height: 24px; /* Компактный размер под высоту шрифта */
    width: 24px;
    border-radius: 50%; /* На всякий случай скругляем */
    object-fit: cover;
    border: 1px solid rgba(0, 240, 255, 0.3); /* Легкий неоновый ободок вокруг иконки */
}

/* СБРОС СТИЛЕЙ ДЛЯ КНОПКИ КОНТАКТОВ В МЕНЮ */
.nav-static a.contact-link {
    color: var(--text-gray) !important;
    text-decoration: none !important;
    font-size: 16px;
    transition: 0.3s;
}

.nav-static a.contact-link:hover {
    color: var(--neon-purple) !important;
    text-shadow: 0 0 8px var(--neon-purple) !important;
}

/* СКРЫВАЕМ НАДПИСЬ HWM.KZ НА МОБИЛЬНЫХ УСТРОЙСТВАХ */
@media (max-width: 768px) {
    .logo-container .logo-text {
        display: none !important;
    }
    
    /* Слегка увеличим зазор для бургер-меню, чтобы иконка смотрелась аккуратно */
    .mobile-menu-icon {
        margin-left: auto;
        padding-right: 10px;
    }
}

/* ПЕРЕНОС БУРГЕР-МЕНЮ К ЛОГОТИПУ НА МОБИЛЬНЫХ */
@media (max-width: 768px) {
    /* Настраиваем общий контейнер навигации */
    nav {
        width: 100%;
        display: flex !important;
        justify-content: space-between !important;
        align-items: center !important;
    }

    /* Принудительно двигаем бургер в левую сторону к логотипу */
    .mobile-menu-icon {
        display: block !important;
        order: 1 !important; /* Встает первым внутри nav */
        margin-right: 15px !important; /* Делает аккуратный отступ от иконки HWM */
        margin-left: 0 !important;
    }

    /* Смещаем блок контактов и языков в крайнюю правую часть */
    .nav-static {
        order: 2 !important; /* Встает вторым внутри nav */
        margin-left: auto !important; /* Выталкивает блок вправо */
    }

    /* Выпадающая панель меню */
    .nav-links {
        order: 3 !important; /* Уходит вниз структуры при раскрытии */
    }
}