/* 1. БАЗОВЫЕ НАСТРОЙКИ */
body { 
    font-family: 'Inter', sans-serif; 
    background-color: #050505; 
    color: white; 
    margin: 0; 
    scroll-behavior: smooth; 
}

/* 2. ШРИФТЫ */
@font-face {
    font-family: 'Cinzel';
    src: url('../fonts/Cinzel-Bold.woff2') format('woff2'),
         url('../fonts/Cinzel-Bold.woff') format('woff');
    font-weight: bold;
    font-style: normal;
}

.font-cinzel {
    font-family: 'Cinzel', serif !important;
}

/* 3. КНОПКИ (ЛК И CABINET) */
.main-auth-btn, .btn-cabinet {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    visibility: visible !important;
    opacity: 1 !important;
    padding: 12px 30px !important;
    border: 1px solid rgba(255, 255, 255, 0.4) !important;
    border-radius: 50px !important;
    background: rgba(255, 255, 255, 0.05) !important;
    color: #ffffff !important;
    font-family: 'Cinzel', serif !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.2em !important;
    text-decoration: none !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    white-space: nowrap;
}

.main-auth-btn:hover, .btn-cabinet:hover {
    background: rgba(255, 255, 255, 0.15) !important;
    border-color: #ffffff !important;
    transform: translateY(-1px);
}

/* 4. НАВИГАЦИЯ */
.nav-link {
    font-family: 'Cinzel', serif !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    color: #ffffff !important;
    text-transform: uppercase !important;
    letter-spacing: 0.2em !important;
    text-decoration: none !important;
    opacity: 0.8;
    transition: opacity 0.3s;
}

.nav-link:hover { opacity: 1; }

/* 5. ПЕРЕКЛЮЧАТЕЛЬ ЯЗЫКОВ */
.langs { position: relative; display: inline-block; }
.lang__link_select {
    color: #fff; padding: 8px 12px; background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255,255,255,0.1); border-radius: 8px; cursor: pointer;
    font-family: 'Inter', sans-serif; font-size: 13px;
}
.lang__list {
    position: absolute; top: 110%; right: 0; background: #111;
    border: 1px solid rgba(255,255,255,0.1); border-radius: 8px; display: none;
    min-width: 60px; z-index: 9999; padding: 5px 0;
}
.langs:hover .lang__list { display: block; }
.lang__link_sub {
    display: block; padding: 8px 15px; color: #888; text-decoration: none; font-size: 12px;
}
.lang__link_sub:hover { background: rgba(255,255,255,0.05); color: #fff; }



/* 7. РЕЙТИНГ (ФИКС ПОД ТВОИ ШАБЛОНЫ) */
.rating-wrapper {
    width: 100% !important;
}

/* Жёсткое скрытие неактивных вкладок */
.stats-content.hidden, .rating__tab.hidden {
    display: none !important;
}

/* Строка заголовка (Player / PvP / PK) */
.top_header {
    display: flex !important;
    justify-content: space-between !important;
    padding: 0 15px 10px !important;
    opacity: 0.4;
    font-size: 11px;
    text-transform: uppercase;
    font-family: 'Cinzel', serif;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    margin-bottom: 15px;
}

/* Заголовки колонок */
.top__name_header {
    margin-left: 35px; /* Чтобы "Player" стоял ровно над никами, пропуская номер */
}

/* Основная строка с данными */
.rating-wrapper .top {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    padding: 12px 15px !important;
    margin-bottom: 8px !important;
    background: rgba(255, 255, 255, 0.03) !important;
    border: 1px solid rgba(255, 255, 255, 0.05) !important;
    border-radius: 12px !important;
    transition: all 0.2s ease;
}

.rating-wrapper .top:hover {
    background: rgba(255, 255, 255, 0.06) !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
}

/* Номер по порядку */
.top__num {
    width: 35px !important;
    font-size: 12px;
    color: rgba(255,255,255,0.3);
    font-family: 'Cinzel', serif;
}

/* Имя или Название клана */
.top__name {
    flex-grow: 1 !important;
    font-weight: bold;
    color: #fff;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Очки (PVP/PK) */
.top__score {
    margin-left: auto !important;
    color: #f3c25a !important;
    font-weight: 800;
    font-family: 'Cinzel', serif;
    font-size: 14px;
}

/* Иконки гербов */
.top__name img {
    height: 16px !important;
    width: auto !important;
    display: inline-block !important;
}

/* Чистка мусора движка */
.top__ico { display: none !important; }
.rating-wrapper br { display: none !important; }

/* Принудительно показываем активную вкладку */
.stats-content.rating-active {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: auto !important;
}

/* Принудительно скрываем неактивные */
.stats-content:not(.rating-active) {
    display: none !important;
}

/* По умолчанию прячем все блоки внутри вывода */
.single-stat-block {
    display: none !important;
}

/* Если у родителя есть класс show-pvp — показываем только PVP и т.д. */
.rating-wrapper.show-pvp .pvp-block { display: block !important; }
.rating-wrapper.show-pk .pk-block { display: block !important; }
.rating-wrapper.show-clans .clan-block { display: block !important; }

/* Прячем все блоки по умолчанию */
.single-stat-block {
    display: none !important;
}

/* Показываем только тот, который соответствует классу родителя */
.rating-wrapper.show-pvp .pvp-block { display: block !important; }
.rating-wrapper.show-pk .pk-block { display: block !important; }
.rating-wrapper.show-clans .clan-block { display: block !important; }

body {
    background-color: transparent !important;
    /* Устанавливаем картинку на фон всего body */
    background-image: url('/template/site/ofsite/images/bg_bg.png') !important;
    background-attachment: fixed !important; /* Картинка не движется при скролле */
    background-repeat: no-repeat !important;
    background-size: cover !important;
    
    /* Сдвигаем картинку вниз на 128px (высота твоего хедера) */
    background-position: center 8rem !important; 
}

/* Затемнение и плавный переход (Усиленное) */
body::before {
    content: "" !important;
    position: fixed !important;
    inset: 0 !important;
    /* Усилили прозрачность с 0.3 до 0.7 и подняли градиент выше */
    background: linear-gradient(to bottom, 
        #020202 0%, 
        #020202 8rem, 
        transparent 10rem, 
        rgba(2, 2, 2, 0.7) 40%, /* Стало темнее (0.7) и затемнение начинается раньше (40%) */
        #020202 100%) !important;
    z-index: -1 !important;
}

/* Плавное появление меню сообщества */
.group:hover .group-hover\:visible {
    transform: translate(-50%, 0);
}
.group .group-hover\:visible {
    transform: translate(-50%, 10px);
    transition: all 0.3s ease-out;
}

html {
    scroll-behavior: smooth;
}