/* Общие стили */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: Arial, sans-serif;
}

body {
    background-color: rgb(19, 21, 0);
    color: white;
    line-height: 1.6;
}

a {
    text-decoration: none;
    color: white;
    transition: opacity 0.3s;
}

a:hover {
    opacity: 0.8;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Заголовки */
h1, h2, h3, h4, h5, h6 {
    color: orange;
    margin-bottom: 15px;
}

/* Шапка */
header {
    padding: 20px 0 10px; /* Изменен padding */
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    height: 40px;
}

.header-buttons {
    display: flex;
    gap: 15px;
    align-items: center;
}

/* Иконки соцсетей */
.social-icons {
    display: flex;
    gap: 10px;
    margin-right: 15px;
}

.social-icon {
    width: 30px;
    height: 30px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    transition: background-color 0.3s;
}

.social-icon:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

/* Кнопки */
.btn {
    padding: 10px 20px;
    border-radius: 5px;
    border: none;
    cursor: pointer;
    font-weight: bold;
    text-transform: uppercase;
    transition: all 0.3s;
}

.btn-login {
    background: linear-gradient(45deg, #00a86b, #009688);
    box-shadow: 0 0 10px rgba(0, 168, 107, 0.5);
    animation: shimmer-green 2s infinite;
    background-size: 200% 200%;
}

.btn-register {
    background: linear-gradient(45deg, #ff8a00, #ff5722);
    box-shadow: 0 0 10px rgba(255, 138, 0, 0.5);
    animation: shimmer-orange 2s infinite;
    background-size: 200% 200%;
}

.btn-mirror {
    background-color: rgba(255, 255, 255, 0.1);
}

.btn-play {
    background: linear-gradient(45deg, #00a86b, #009688);
    box-shadow: 0 0 10px rgba(0, 168, 107, 0.5);
    padding: 8px 16px;
    font-size: 14px;
    margin-right: 5px;
}

.btn-demo {
    background: linear-gradient(45deg, #ff8a00, #ff5722);
    box-shadow: 0 0 10px rgba(255, 138, 0, 0.5);
    padding: 8px 16px;
    font-size: 14px;
}

@keyframes shimmer-green {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes shimmer-orange {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* === НОВОЕ: Стили для главной навигации === */
.main-navigation {
    display: flex;
    justify-content: center;
    flex-wrap: wrap; 
    gap: 15px;
    padding-top: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.05); 
    margin-top: 15px; 
}

.nav-link {
    color: white;
    text-decoration: none;
    padding: 8px 12px;
    border-radius: 5px;
    background-color: rgba(255, 255, 255, 0.05);
    font-weight: bold;
    font-size: 14px;
    transition: background-color 0.3s, color 0.3s;
}

.nav-link:hover {
    background-color: orange;
    color: rgb(19, 21, 29);
    opacity: 1; 
}

/* Основной контент (Главная страница) */
.hero {
    padding: 30px 0;
    text-align: center;
}

.hero-buttons {
    margin: 20px 0;
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.promo-code {
    margin: 20px auto;
    max-width: 400px;
    padding: 15px;
    background-color: rgba(255, 138, 0, 0.2);
    border: 1px dashed orange;
    border-radius: 5px;
    cursor: pointer;
    position: relative;
}

.promo-code:hover {
    background-color: rgba(255, 138, 0, 0.3);
}

.promo-title {
    display: block;
    color: orange;
    font-weight: bold;
    font-size: 18px;
    margin-bottom: 10px;
}

.promo-code-text {
    font-weight: bold;
    letter-spacing: 1px;
    font-size: 18px;
}

.promo-code-tooltip {
    position: absolute;
    top: -40px;
    left: 50%;
    transform: translateX(-50%);
    background-color: rgba(0, 0, 0, 0.8);
    padding: 5px 10px;
    border-radius: 5px;
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
}

.promo-code-tooltip.show {
    opacity: 1;
}

/* Слайдер (Главная страница) */
.slider {
    margin: 20px 0;
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    height: 300px;
}

.slider-container {
    display: flex;
    transition: transform 0.5s ease;
    height: 100%;
}

.slide {
    min-width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
}

.slider-nav {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
}

.slider-dot {
    width: 12px;
    height: 12px;
    background-color: rgba(255, 255, 255, 0.5);
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.3s;
}

.slider-dot.active {
    background-color: white;
}

.slider-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    background-color: rgba(0, 0, 0, 0.5);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
}

.slider-arrow-left {
    left: 20px;
}

.slider-arrow-right {
    right: 20px;
}

/* Блок с игровыми картинками (Главная страница) */
.games-grid {
    margin: 40px 0;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-gap: 20px;
}

.game-item {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    aspect-ratio: 1 / 1;
}

.game-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.game-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s;
}

.game-item:hover .game-overlay {
    opacity: 1;
}

.game-item:hover .game-image {
    transform: scale(1.05);
}

.game-title {
    margin-bottom: 15px;
    text-align: center;
    font-weight: bold;
}

.game-buttons {
    display: flex;
    gap: 10px;
}

/* Текстовый контент (Главная и внутренние) */
.content {
    padding: 40px 0;
    line-height: 1.8;
}

/* === НОВОЕ: Стили для контента внутренних страниц === */
.internal-page-content {
    padding: 40px 0;
    line-height: 1.8;
}

.internal-page-content img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    margin: 20px auto; /* Центрирование */
    display: block;
    max-height: 400px; 
    object-fit: cover;
    background-color: #333; /* Фон-заглушка */
}

.internal-page-content p {
    margin-bottom: 15px;
}

/* Футер */
footer {
    background-color: rgba(0, 0, 0, 0.3);
    padding: 40px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
}

.footer-logo {
    height: 40px;
}

.footer-social {
    display: flex;
    gap: 15px;
    margin: 20px 0;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
}

/* === НОВОЕ: Стили для легальных ссылок в футере === */
.footer-legal-links {
    display: flex;
    flex-direction: column; /* Вертикально */
    align-items: center; /* По центру */
    gap: 10px; 
    margin-top: 20px; 
}

.footer-legal-links a {
    color: white;
    opacity: 0.7; 
    font-size: 14px;
    text-decoration: none;
}

.footer-legal-links a:hover {
    opacity: 1;
    text-decoration: underline;
}

.copyright {
    margin-top: 20px;
    opacity: 0.7;
    font-size: 14px;
}

/* === НОВОЕ: Стили для Оглавления (TOC) === */
#table-of-contents {
    background-color: rgba(0,0,0,0.2);
    padding: 15px;
    margin: 20px 0;
    border-radius: 5px;
    border: 1px solid rgba(255,255,255,0.1);
}

.toc-title {
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 1.5em;
    cursor: pointer;
    color: orange; /* Стиль заголовка */
    position: relative;
    padding-right: 25px;
}

.toc-title:after {
    content: "▼";
    position: absolute;
    right: 5px;
    top: 5px; /* Скорректировано */
    font-size: 0.7em;
    transition: transform 0.3s;
    color: white; /* Цвет стрелки */
}

.toc-title[data-state="closed"]:after {
    transform: rotate(-90deg);
}

.toc-content.hidden {
    display: none;
}

.toc ol {
    margin: 0;
    padding-left: 20px;
}

.toc li {
    margin-bottom: 8px;
}

.toc a {
    text-decoration: none;
    color: #FFF; /* Белый цвет для ссылок */
    font-style: italic;
}

.toc a:hover {
    text-decoration: underline;
    color: orange;
}

.level-2 {
    margin-left: 20px;
}

.level-3 {
    margin-left: 40px;
}

 

.burger-menu span {
    width: 100%;
    height: 3px;
    background-color: orange;
    border-radius: 10px;
    transition: all 0.3s linear;
}
/* Кнопка бургера (скрыта на ПК) */
.burger-menu {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 20px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1001;
}

.burger-menu span {
    width: 100%;
    height: 3px;
    background-color: orange;
    border-radius: 5px;
    transition: 0.3s;
}

/* Адаптив для мобильных устройств */
@media (max-width: 768px) {
    .burger-menu {
        display: flex; /* Показываем бургер */
    }

    .header-content {
        display: flex !important;
        flex-direction: row !important; /* Лого и бургер в одну линию */
        justify-content: space-between;
        align-items: center;
        width: 100%;
    }

    .header-buttons {
        display: none !important; /* Скрываем кнопку Демо на мобилках, чтобы не мешала */
    }

    /* Мобильное меню */
    .main-navigation {
        display: none !important;
        flex-direction: column !important;
        position: absolute;
        top: 70px; /* Высота шапки */
        left: 0;
        width: 100%;
        background-color: rgb(19, 21, 29);
        padding: 20px;
        border-bottom: 2px solid orange;
        z-index: 1000;
        margin-top: 0;
        gap: 10px;
    }

    /* Когда меню активно */
    .main-navigation.active {
        display: flex !important;
    }

    .nav-link {
        width: 100%;
        text-align: center;
        padding: 15px;
        background-color: rgba(255, 255, 255, 0.05);
    }

    /* Анимация бургера */
    .burger-menu.open span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
    .burger-menu.open span:nth-child(2) { opacity: 0; }
    .burger-menu.open span:nth-child(3) { transform: translateY(-9px) rotate(-45deg); }

    /* Исправление слайдера и сетки для мобилок */
    .slider { height: 200px; }
    .hero-buttons { flex-direction: column; align-items: center; }
}