/* ==========================================================================
   PREMIUM ESPORTS — единая дизайн-система (слой поверх существующих стилей)
   Подключается ПОСЛЕДНИМ: style.css / extras.css / … остаются как есть,
   этот файл только перекрашивает и дорабатывает их. Удалишь файл — сайт
   вернётся к прежнему виду.

   Содержание
     0. Токены и палитра            8. Формы, кнопки, таблицы, вкладки
     1. База, скроллбар, фокус      9. Окна, тосты
     2. Фон: аврора, сетка, частицы 10. Главная: hero, виджеты, график
     3. Загрузчик и полоса перехода 11. Переходы между страницами
     4. Боковое меню (ПК)           12. Hover-эффекты
     5. Верхняя панель + поиск      13. Адаптив (планшет / телефон)
     6. Мобильная шапка и меню      14. Хэллоуин-совместимость
     7. Карточки, заголовки         15. prefers-reduced-motion
   ========================================================================== */

/* ---------- 0. ТОКЕНЫ ---------- */
:root {
    --bg: #05030d;
    --bg-soft: #0c0718;
    --surface: rgba(255, 255, 255, .035);
    --surface-strong: rgba(167, 120, 255, .09);
    --border: rgba(167, 120, 255, .16);
    --border-strong: rgba(167, 120, 255, .32);
    --text: #f2edff;
    --muted: #9b92c4;

    /* бывший «cyan» — теперь главный неон-акцент (светло-фиолетовый) */
    --cyan: #b78cff;
    --violet: #8f3dff;
    --pink: #ff4fd8;
    --grad: linear-gradient(135deg, #7a2cff 0%, #b05cff 55%, #ff4fd8 100%);
    --grad-hot: linear-gradient(135deg, #ff4fd8 0%, #8f3dff 100%);

    --ff-a: 143, 61, 255;                 /* RGB неона: используется в rgba(var(--ff-a), .x) */
    --ff-a2: 255, 79, 216;                /* вторичный неон (маджента) */
    --ff-ease: cubic-bezier(.22, .8, .24, 1);
    --ff-side-w: 248px;
    --radius: 18px;
    --shadow: 0 12px 44px rgba(0, 0, 0, .5);
}

/* ---------- 1. БАЗА ---------- */
html { scrollbar-color: rgba(var(--ff-a), .6) transparent; scrollbar-width: thin; }
body { background: var(--bg); }
::selection { background: rgba(var(--ff-a), .55); color: #fff; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: linear-gradient(180deg, rgba(var(--ff-a), .7), rgba(var(--ff-a2), .5)); border-radius: 10px; border: 2px solid var(--bg); }
:focus-visible { outline: 2px solid #c9a8ff; outline-offset: 2px; border-radius: 8px; }

/* родной фон из style.css — заменяем на мягкую фиолетовую подсветку */
body::before {
    background:
        radial-gradient(900px 520px at 12% -6%, rgba(var(--ff-a), .24), transparent 70%),
        radial-gradient(760px 520px at 100% 8%, rgba(var(--ff-a2), .10), transparent 70%),
        radial-gradient(700px 500px at 50% 110%, rgba(var(--ff-a), .16), transparent 70%);
}
/* слои прежнего fx.js (если файл есть на сервере) заменены новым фоном */
.bg-grid, .bg-aurora { display: none !important; }

.ni { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- 2. ФОН ---------- */
.ff-bg { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; contain: strict; }
.ff-bg i { position: absolute; border-radius: 50%; filter: blur(70px); opacity: .55; will-change: transform; }
.ff-bg .a1 { width: 52vmax; height: 52vmax; left: -14vmax; top: -18vmax; background: radial-gradient(circle, rgba(var(--ff-a), .55), transparent 65%); animation: ffDrift1 26s ease-in-out infinite alternate; }
.ff-bg .a2 { width: 44vmax; height: 44vmax; right: -16vmax; top: 6vmax; background: radial-gradient(circle, rgba(var(--ff-a2), .28), transparent 65%); animation: ffDrift2 32s ease-in-out infinite alternate; }
.ff-bg .a3 { width: 48vmax; height: 48vmax; left: 22vw; bottom: -30vmax; background: radial-gradient(circle, rgba(110, 60, 255, .42), transparent 65%); animation: ffDrift3 38s ease-in-out infinite alternate; }
.ff-bg .grid {
    inset: 0; width: auto; height: auto; filter: none; border-radius: 0; opacity: .5;
    background-image: linear-gradient(rgba(167, 120, 255, .07) 1px, transparent 1px), linear-gradient(90deg, rgba(167, 120, 255, .07) 1px, transparent 1px);
    background-size: 56px 56px;
    -webkit-mask-image: radial-gradient(ellipse 75% 60% at 50% 30%, #000 20%, transparent 78%);
    mask-image: radial-gradient(ellipse 75% 60% at 50% 30%, #000 20%, transparent 78%);
}
.ff-bg canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
@keyframes ffDrift1 { to { transform: translate3d(9vmax, 7vmax, 0) scale(1.15); } }
@keyframes ffDrift2 { to { transform: translate3d(-8vmax, 9vmax, 0) scale(1.1); } }
@keyframes ffDrift3 { to { transform: translate3d(10vmax, -6vmax, 0) scale(1.12); } }

/* ---------- 3. ЗАГРУЗЧИК / ПОЛОСА ПЕРЕХОДА ---------- */
.ff-loader {
    position: fixed; inset: 0; z-index: 100000; display: grid; place-items: center;
    background: radial-gradient(circle at 50% 38%, #1d0b42 0%, #090415 55%, #05030d 100%);
    transition: opacity .7s var(--ff-ease), visibility .7s;
    animation: ffLoaderSafety .6s 6s forwards;            /* страховка, если скрипт не отработал */
}
.ff-loader.is-done { opacity: 0; visibility: hidden; pointer-events: none; }
@keyframes ffLoaderSafety { to { opacity: 0; visibility: hidden; pointer-events: none; } }
.ff-loader-core { position: relative; display: flex; flex-direction: column; align-items: center; gap: 18px; width: min(320px, 80vw); }
.ff-loader-ring { position: relative; width: 112px; height: 112px; }
.ff-loader-ring i { position: absolute; inset: 0; border-radius: 50%; border: 2px solid transparent; }
.ff-loader-ring i:nth-child(1) { border-top-color: #b78cff; border-right-color: rgba(183, 140, 255, .35); animation: ffSpin 1.1s linear infinite; filter: drop-shadow(0 0 8px rgba(var(--ff-a), .9)); }
.ff-loader-ring i:nth-child(2) { inset: 12px; border-bottom-color: #ff4fd8; border-left-color: rgba(255, 79, 216, .3); animation: ffSpin 1.7s linear infinite reverse; }
.ff-loader-mark { position: absolute; top: 28px; width: 56px; height: 56px; stroke: none; fill: url(#ffg); filter: drop-shadow(0 0 12px rgba(var(--ff-a), .9)); animation: ffBeat 1.6s ease-in-out infinite; }
.ff-loader-title { font: 900 22px 'Orbitron', sans-serif; letter-spacing: 3px; font-style: italic; color: #fff; text-shadow: 0 0 18px rgba(var(--ff-a), .9); }
.ff-loader-title span { background: var(--grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.ff-loader-bar { width: 100%; height: 4px; border-radius: 4px; background: rgba(255, 255, 255, .08); overflow: hidden; }
.ff-loader-bar b { display: block; width: 40%; height: 100%; border-radius: 4px; background: var(--grad); box-shadow: 0 0 14px rgba(var(--ff-a), .9); animation: ffBar 1.15s ease-in-out infinite; }
.ff-loader-sub { font-size: 11px; letter-spacing: 3px; text-transform: uppercase; color: var(--muted); }
@keyframes ffSpin { to { transform: rotate(360deg); } }
@keyframes ffBeat { 0%, 100% { transform: scale(1); opacity: .9; } 50% { transform: scale(1.12); opacity: 1; } }
@keyframes ffBar { 0% { transform: translateX(-110%); } 100% { transform: translateX(300%); } }

.ff-progress { position: fixed; left: 0; right: 0; top: 0; height: 3px; z-index: 100002; pointer-events: none; opacity: 0; }
.ff-progress i { display: block; height: 100%; width: 100%; transform: scaleX(0); transform-origin: left; background: var(--grad); box-shadow: 0 0 14px rgba(var(--ff-a), .95), 0 0 4px #fff; }
.ff-progress.run { opacity: 1; }
.ff-progress.run i { animation: ffProg .75s var(--ff-ease) forwards; }
@keyframes ffProg { 0% { transform: scaleX(0); opacity: 1; } 70% { transform: scaleX(.92); opacity: 1; } 100% { transform: scaleX(1); opacity: 0; } }

/* ---------- 4. БОКОВОЕ МЕНЮ (ПК) ---------- */
.brand { cursor: pointer; }
.brand-mark { display: none; }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-title { font-style: italic; letter-spacing: 1.2px; }
.ff-promo { display: none; }

@media (min-width: 901px) {
    body.ff-side { --header-h: 0px; }
    body.ff-side .site-header {
        position: fixed; inset: 0 auto 0 0; width: var(--ff-side-w); height: 100vh; height: 100dvh; padding: 22px 14px 16px;
        flex-direction: column; align-items: stretch; justify-content: flex-start; gap: 16px; overflow-y: auto; overflow-x: hidden; scrollbar-width: none;
        background: linear-gradient(180deg, rgba(16, 8, 36, .94), rgba(6, 3, 15, .97));
        -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
        border-right: 1px solid var(--border); border-bottom: 0; box-shadow: 8px 0 40px rgba(0, 0, 0, .35);
    }
    body.ff-side .site-header::-webkit-scrollbar { display: none; }
    /* неоновая линия по краю */
    body.ff-side .site-header::after { content: ''; position: absolute; top: 0; right: -1px; bottom: 0; width: 1px; pointer-events: none;
        background: linear-gradient(180deg, transparent, rgba(var(--ff-a), .95) 30%, rgba(var(--ff-a2), .8) 70%, transparent); opacity: .7; animation: ffEdge 6s ease-in-out infinite alternate; }
    @keyframes ffEdge { from { opacity: .35; } to { opacity: .9; } }

    body.ff-side .brand { flex-direction: row; align-items: center; gap: 12px; padding: 2px 6px 16px; border-bottom: 1px solid var(--border); }
    body.ff-side .brand-mark { display: block; flex: none; }
    body.ff-side .brand-mark svg { width: 46px; height: 46px; overflow: visible; filter: drop-shadow(0 0 10px rgba(var(--ff-a), .85)); transition: transform .4s var(--ff-ease); }
    body.ff-side .brand:hover .brand-mark svg { transform: rotate(-8deg) scale(1.08); }
    .bm-hex { fill: rgba(22, 9, 48, .92); stroke: url(#ffg); stroke-width: 2.2; stroke-linejoin: round; }
    .bm-bolt { fill: url(#ffg); }
    body.ff-side .brand-title { font-size: 17px; color: #fff; background: none; -webkit-text-fill-color: #fff; text-shadow: 0 0 16px rgba(var(--ff-a), .85); }
    body.ff-side .brand-subtitle { font-size: 8.5px; letter-spacing: 2.4px; color: #b78cff; }

    body.ff-side .desktop-nav { flex-direction: column; flex-wrap: nowrap; justify-content: flex-start; gap: 3px; }
    body.ff-side .nav-btn { display: flex; align-items: center; gap: 13px; width: 100%; padding: 12px 14px; border-radius: 12px; text-align: left; font-size: 14px; letter-spacing: .2px; position: relative; overflow: hidden; }
    body.ff-side .nav-btn .nl { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
    body.ff-side .nav-btn .ni { opacity: .85; transition: transform .3s var(--ff-ease), filter .3s; }
    body.ff-side .nav-btn:hover { color: #fff; background: rgba(var(--ff-a), .12); text-shadow: none; transform: translateX(3px); }
    body.ff-side .nav-btn:hover .ni { transform: scale(1.14); filter: drop-shadow(0 0 6px rgba(var(--ff-a), .9)); }
    body.ff-side .nav-btn.active {
        color: #fff; animation: none;
        background: linear-gradient(90deg, rgba(var(--ff-a), .62), rgba(var(--ff-a), .16));
        box-shadow: inset 0 0 0 1px rgba(183, 140, 255, .42), 0 0 24px rgba(var(--ff-a), .4);
    }
    body.ff-side .nav-btn.active::before { content: ''; position: absolute; left: 0; top: 18%; bottom: 18%; width: 3px; border-radius: 0 3px 3px 0; background: #fff; box-shadow: 0 0 12px #fff, 0 0 18px rgba(var(--ff-a), 1); }
    body.ff-side .nav-btn.active .ni { opacity: 1; filter: drop-shadow(0 0 7px rgba(255, 255, 255, .7)); }
    body.ff-side .nav-btn .nbadge { position: static; margin-left: auto; }
    body.ff-side .nav-btn.admin-link { margin-top: 6px; border: 1px dashed var(--border-strong); }

    /* промо-карточка внизу меню */
    body.ff-side .ff-promo {
        display: block; position: relative; margin-top: auto; padding: 56px 16px 16px; border-radius: 18px; text-align: left; overflow: hidden;
        background: linear-gradient(160deg, rgba(var(--ff-a), .28), rgba(14, 6, 30, .9) 60%); border: 1px solid rgba(183, 140, 255, .38);
        box-shadow: 0 0 30px rgba(var(--ff-a), .25), inset 0 0 30px rgba(var(--ff-a), .12);
    }
    .ff-promo-crown { position: absolute; top: 8px; left: 50%; width: 62px; height: 46px; margin-left: -31px; fill: url(#ffg); filter: drop-shadow(0 0 12px rgba(var(--ff-a), 1)); animation: ffFloat 4s ease-in-out infinite; }
    .ff-promo b { display: block; font: 800 16px 'Orbitron', sans-serif; margin-bottom: 4px; color: #fff; }
    .ff-promo p { font-size: 12px; line-height: 1.45; color: var(--muted); margin-bottom: 12px; }
    .ff-promo .btn { width: 100%; padding: 10px 12px; font-size: 12px; }
    body.ff-side .ff-promo .btn { animation: none; }
}

/* ---------- 5. ВЕРХНЯЯ ПАНЕЛЬ + ПОИСК ---------- */
.ff-topbar { display: none; }
.ff-search { position: relative; flex: 1; max-width: 640px; display: flex; align-items: center; gap: 10px; height: 48px; padding: 0 6px 0 16px; border-radius: 14px;
    background: rgba(16, 9, 36, .88); border: 1px solid var(--border-strong); color: var(--muted); transition: border-color .25s, box-shadow .25s, background .25s; }
.ff-search:focus-within { color: #c9a8ff; border-color: #b78cff; background: rgba(22, 12, 48, .95); box-shadow: 0 0 0 3px rgba(var(--ff-a), .22), 0 0 30px rgba(var(--ff-a), .4); }
.ff-search input, .ff-search input:focus { flex: 1; min-width: 0; width: auto; height: 100%; margin: 0; padding: 0; border: 0; background: transparent; box-shadow: none; color: var(--text); font-size: 14px; border-radius: 0; }
.ff-search input::-webkit-search-cancel-button { display: none; }
.ff-search button { flex: none; display: grid; place-items: center; width: 46px; height: 36px; border: 0; border-radius: 10px; background: var(--grad); color: #fff; cursor: pointer; box-shadow: 0 0 18px rgba(var(--ff-a), .55); transition: transform .2s var(--ff-ease), box-shadow .2s; }
.ff-search button:hover { transform: scale(1.06); box-shadow: 0 0 26px rgba(var(--ff-a), .9); }
.ff-actions { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.ff-actions:empty { display: none; }
.ff-login { display: inline-flex; align-items: center; gap: 8px; height: 46px; padding: 0 20px; border: 0; border-radius: 13px; background: var(--grad); color: #fff; font: 800 14px 'Inter', sans-serif; cursor: pointer;
    box-shadow: 0 6px 26px rgba(var(--ff-a), .55); position: relative; overflow: hidden; transition: transform .2s var(--ff-ease), box-shadow .25s; white-space: nowrap; max-width: 220px; }
.ff-login span { overflow: hidden; text-overflow: ellipsis; }
.ff-login::after { content: ''; position: absolute; top: 0; left: -120%; width: 55%; height: 100%; background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .45), transparent); transform: skewX(-20deg); transition: left .6s ease; }
.ff-login:hover { transform: translateY(-2px); box-shadow: 0 10px 34px rgba(var(--ff-a), .85); }
.ff-login:hover::after { left: 150%; }
.ff-login:active { transform: scale(.97); }
.ff-login.in { background: rgba(var(--ff-a), .18); border: 1px solid rgba(183, 140, 255, .5); box-shadow: 0 0 20px rgba(var(--ff-a), .3); }

@media (min-width: 901px) {
    body.ff-side .ff-topbar { display: flex; position: sticky; top: 0; z-index: 90; align-items: center; gap: 14px; margin-left: var(--ff-side-w); padding: 16px 28px 10px;
        background: linear-gradient(180deg, rgba(5, 3, 13, .94) 0%, rgba(5, 3, 13, .7) 70%, transparent); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
    body.ff-side .container { max-width: 1560px; margin: 8px 0 0 var(--ff-side-w); padding: 10px 28px 48px; }
    body.ff-side .toast { left: calc(50% + var(--ff-side-w) / 2); }
}

/* ---------- 6. МОБИЛЬНАЯ ШАПКА / МЕНЮ / НИЖНЯЯ ПАНЕЛЬ ---------- */
@media (max-width: 900px) {
    .site-header { background: rgba(8, 4, 20, .88); border-bottom: 1px solid var(--border); box-shadow: 0 6px 30px rgba(0, 0, 0, .4); }
    .brand { flex-direction: row; align-items: center; gap: 10px; min-width: 0; }
    .brand-mark { display: block; flex: none; }
    .brand-mark svg { width: 34px; height: 34px; filter: drop-shadow(0 0 8px rgba(var(--ff-a), .85)); }
    .bm-hex { fill: rgba(22, 9, 48, .92); stroke: url(#ffg); stroke-width: 2.4; }
    .bm-bolt { fill: url(#ffg); }
    .brand-title { font-size: 16px; }
    .burger { border-color: var(--border-strong); background: rgba(var(--ff-a), .14); color: #fff; transition: transform .25s var(--ff-ease), box-shadow .25s; }
    .burger:active { transform: scale(.92); }
    .mobile-menu { background: rgba(8, 4, 20, .97); -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px); border-bottom: 1px solid var(--border-strong); box-shadow: 0 20px 50px rgba(0, 0, 0, .6); max-height: calc(100dvh - var(--header-h) - var(--bottom-h)); overflow-y: auto; }
    .mobile-menu .nav-btn { display: flex; align-items: center; gap: 10px; background: rgba(var(--ff-a), .07); border-color: var(--border); color: var(--text); }
    .mobile-menu .nav-btn.active { background: linear-gradient(135deg, rgba(var(--ff-a), .7), rgba(var(--ff-a), .25)); animation: none; }
    .mobile-menu .nav-btn .nbadge { position: static; margin-left: auto; }

    .ff-topbar { display: block; padding: 12px 14px 0; }
    .ff-topbar .ff-search { max-width: none; height: 46px; }
    .ff-topbar .ff-actions, .ff-topbar .ff-login { display: none; }

    .bottom-nav { background: rgba(8, 4, 20, .92); border-top: 1px solid var(--border-strong); box-shadow: 0 -10px 34px rgba(var(--ff-a), .22); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); }
    .bottom-nav button { position: relative; color: var(--muted); transition: color .25s, transform .25s var(--ff-ease); }
    .bottom-nav button .ni { width: 22px; height: 22px; transition: transform .3s var(--ff-ease), filter .3s; }
    .bottom-nav button .bl { font-size: 10px; line-height: 1.1; filter: none; }
    .bottom-nav button.active { color: #fff; }
    .bottom-nav button.active span { filter: none; }
    .bottom-nav button.active .ni { transform: translateY(-2px) scale(1.12); filter: drop-shadow(0 0 8px rgba(var(--ff-a), 1)); stroke: #d7c0ff; }
    .bottom-nav button.active::before { content: ''; position: absolute; top: -7px; left: 26%; right: 26%; height: 3px; border-radius: 0 0 4px 4px; background: var(--grad); box-shadow: 0 0 14px rgba(var(--ff-a), 1); }
    .bottom-nav button:active { transform: scale(.92); }
}

/* ---------- 7. КАРТОЧКИ / ЗАГОЛОВКИ ---------- */
.card, .mini-box, .stat-card, .feature {
    -webkit-backdrop-filter: none; backdrop-filter: none;               /* дорогой blur на каждой карточке убран — плавнее на слабых устройствах */
}
.card {
    background: linear-gradient(160deg, rgba(26, 14, 56, .78), rgba(9, 5, 20, .9));
    border: 1px solid var(--border); border-radius: 20px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, .45), inset 0 1px 0 rgba(255, 255, 255, .05);
    transition: border-color .3s, box-shadow .3s;
}
.card::before { border-color: #b78cff; filter: drop-shadow(0 0 5px rgba(var(--ff-a), 1)); }
.card::after { border-color: var(--pink); filter: drop-shadow(0 0 5px rgba(var(--ff-a2), .9)); }
.card:hover { border-color: rgba(183, 140, 255, .42); box-shadow: 0 14px 46px rgba(0, 0, 0, .5), 0 0 34px rgba(var(--ff-a), .16); }
.card > h3, .card > .sc-head h3, .card > .shop-top h3 { position: relative; padding-left: 14px; }
.card > h3::before, .card > .sc-head h3::before, .card > .shop-top h3::before { content: ''; position: absolute; left: 0; top: 4px; bottom: 4px; width: 4px; border-radius: 4px; background: var(--grad); box-shadow: 0 0 12px rgba(var(--ff-a), .95); }
.card h3 .accent, .hero h1 .accent { text-shadow: 0 0 18px rgba(var(--ff-a), .6); }
.accent { color: #c4a0ff; }
th { color: #c4a0ff; text-shadow: 0 0 10px rgba(var(--ff-a), .7); border-bottom: 1px solid rgba(var(--ff-a), .45); }
tbody tr:hover td { background: rgba(var(--ff-a), .09); }
.badge-elo { box-shadow: 0 0 14px rgba(var(--ff-a), .3); }

/* Зал славы: золото остаётся (это ТОП-1), голубые блики -> фиолетовые */
.hall-of-fame {
    animation: none; border-color: rgba(255, 200, 87, .5);
    background: radial-gradient(120% 180% at 0% 0%, rgba(255, 200, 87, .2), transparent 55%), radial-gradient(120% 180% at 100% 100%, rgba(var(--ff-a), .26), transparent 55%), linear-gradient(120deg, rgba(24, 12, 48, .92), rgba(10, 5, 22, .96));
    box-shadow: 0 14px 50px rgba(0, 0, 0, .5), 0 0 40px rgba(255, 200, 87, .12);
}
.hall-of-fame::before { background: conic-gradient(from 0deg, transparent 0 78%, rgba(255, 200, 87, .9) 86%, rgba(183, 140, 255, .9) 92%, transparent 100%); }

/* ---------- 8. ФОРМЫ / КНОПКИ / ВКЛАДКИ ---------- */
input, select, textarea { background: rgba(10, 5, 24, .78); border-color: var(--border-strong); }
input:focus, select:focus, textarea:focus { border-color: #b78cff; box-shadow: 0 0 0 3px rgba(var(--ff-a), .22), 0 0 22px rgba(var(--ff-a), .3); }
input[readonly] { color: #c4a0ff; }

.btn, .btn-action { border: 1px solid rgba(255, 255, 255, .16); border-radius: 12px; background: var(--grad); box-shadow: 0 6px 24px rgba(var(--ff-a), .5), inset 0 1px 0 rgba(255, 255, 255, .25);
    animation: none !important; transition: transform .25s var(--ff-ease), box-shadow .25s, filter .25s; }          /* бесконечная пульсация box-shadow убрана — это был главный источник лагов */
.btn:hover, .btn-action:hover { transform: translateY(-2px); box-shadow: 0 12px 34px rgba(var(--ff-a), .8), inset 0 1px 0 rgba(255, 255, 255, .3); filter: brightness(1.08); }
.btn:active, .btn-action:active { transform: scale(.97); }
.btn-ghost { background: rgba(var(--ff-a), .1); border-color: var(--border-strong); box-shadow: none; }
.btn-ghost:hover { background: rgba(var(--ff-a), .22); border-color: #b78cff; box-shadow: 0 0 22px rgba(var(--ff-a), .5); }
.btn-green { background: linear-gradient(135deg, #12b981, #7ee8c0); }
.btn-red { background: linear-gradient(135deg, #ff4d6d, #ff4fd8); }
.btn .ni { width: 16px; height: 16px; }

.subtabs button, .shop-tabs button, .seg button { transition: transform .2s var(--ff-ease), background .25s, box-shadow .25s, border-color .25s, color .25s; }
.subtabs button:hover, .shop-tabs button:hover, .seg button:hover { border-color: #b78cff; color: #fff; transform: translateY(-1px); }
.subtabs button.on, .shop-tabs button.on, .adm-tabs button.on { background: var(--grad); box-shadow: 0 0 22px rgba(var(--ff-a), .6); }
.seg button.on { background: var(--violet); box-shadow: 0 0 14px rgba(var(--ff-a), .6); }

/* ---------- 9. ОКНА / ТОСТЫ ---------- */
.modal { background: rgba(4, 2, 12, .8); }
.modal.open .modal-card { animation: ffPop .4s var(--ff-ease); }
.modal-card { background: linear-gradient(170deg, #150a2e, #0a0518); border-color: rgba(183, 140, 255, .4); box-shadow: 0 24px 90px rgba(var(--ff-a), .4), 0 0 0 1px rgba(255, 255, 255, .03) inset; border-radius: 22px; }
.modal-x:hover { background: rgba(var(--ff-a), .3); border-color: #b78cff; }
.toast { border-color: rgba(183, 140, 255, .5); box-shadow: 0 10px 40px rgba(0, 0, 0, .5), 0 0 24px rgba(var(--ff-a), .35); }
@keyframes ffFloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }
@keyframes ffPop { from { opacity: 0; transform: translateY(14px) scale(.96); } to { opacity: 1; transform: none; } }

/* ---------- 10. ГЛАВНАЯ ---------- */
.ff-home { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: 20px; align-items: stretch; }
.ff-home > * { min-width: 0; margin-bottom: 20px; }
.ff-home > .hero { grid-column: 1 / -1; grid-row: 1; }
.ff-home > .ff-top { grid-column: 1 / -1; grid-row: 3; }
.ff-home > .stat-grid { grid-column: 1 / -1; grid-row: 2; margin-bottom: 20px; }
.ff-home > .live-strip { grid-column: 1 / -1; grid-row: 4; }
.ff-home > .feature-grid { grid-column: 1 / -1; grid-row: 5; }
.ff-home > .ff-chart { grid-column: 1 / -1; grid-row: 6; }
.ff-home > .ff-recent { grid-column: 1 / -1; grid-row: 7; }
.ff-home > .ff-arena { grid-column: 1 / -1; grid-row: 8; }
.ff-home > .ff-ach { grid-column: 1 / -1; grid-row: 9; }
@media (min-width: 1100px) and (max-width: 1359px) {
    .ff-home > .ff-chart { grid-column: 1 / span 7; grid-row: 6; }
    .ff-home > .ff-recent { grid-column: 8 / span 5; grid-row: 6; }
    .ff-home > .ff-arena { grid-column: 1 / span 7; grid-row: 7; }
    .ff-home > .ff-ach { grid-column: 8 / span 5; grid-row: 7; }
}
@media (min-width: 1360px) {
    .ff-home > .hero { grid-column: 1 / span 8; }
    .ff-home > .ff-top { grid-column: 9 / span 4; grid-row: 1 / span 2; margin-bottom: 20px; }
    .ff-home > .stat-grid { grid-column: 1 / span 8; }
    .ff-home > .live-strip { grid-row: 3; }
    .ff-home > .feature-grid { grid-row: 4; }
    .ff-home > .ff-chart { grid-column: 1 / span 7; grid-row: 5; }
    .ff-home > .ff-recent { grid-column: 8 / span 5; grid-row: 5; }
    .ff-home > .ff-arena { grid-column: 1 / span 7; grid-row: 6; }
    .ff-home > .ff-ach { grid-column: 8 / span 5; grid-row: 6; }
}

/* hero */
.hero {
    position: relative; overflow: hidden; isolation: isolate; min-height: 320px; display: flex; flex-direction: column; justify-content: center; align-items: flex-start;
    padding: clamp(26px, 4vw, 52px); border-radius: 24px; border: 1px solid rgba(183, 140, 255, .34);
    background: radial-gradient(760px 360px at 88% 0%, rgba(var(--ff-a), .55), transparent 62%), radial-gradient(520px 320px at 0% 110%, rgba(var(--ff-a2), .22), transparent 62%), linear-gradient(135deg, #150832, #07040f);
    box-shadow: 0 24px 70px rgba(54, 10, 130, .4), inset 0 1px 0 rgba(255, 255, 255, .08);
}
.hero::before {                                    /* бегущие диагональные лучи вместо старых «сканлиний» */
    content: ''; position: absolute; inset: -60%; z-index: -1; pointer-events: none; animation: ffRays 38s linear infinite;
    background: repeating-conic-gradient(from 0deg at 70% 50%, rgba(var(--ff-a), .0) 0deg 9deg, rgba(var(--ff-a), .10) 9deg 10.5deg, rgba(var(--ff-a), 0) 10.5deg 18deg);
}
@keyframes ffRays { to { transform: rotate(360deg); } }
.hero .orb { display: none; }
.ff-tagline { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 14px; padding: 6px 14px; border-radius: 999px; font: 700 12px 'Inter', sans-serif; letter-spacing: 1.6px; text-transform: uppercase; color: #e6d6ff; background: rgba(var(--ff-a), .2); border: 1px solid rgba(183, 140, 255, .4); box-shadow: 0 0 18px rgba(var(--ff-a), .35); }
.ff-tagline::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: #ff4fd8; box-shadow: 0 0 10px #ff4fd8; animation: ffBlink 1.6s ease-in-out infinite; }
@keyframes ffBlink { 50% { opacity: .3; } }
.hero h1 { max-width: min(640px, 100%); font-size: clamp(30px, 4.6vw, 60px); font-weight: 900; font-style: italic; text-transform: uppercase; line-height: 1.04; letter-spacing: .5px; text-shadow: 0 4px 30px rgba(var(--ff-a), .55); }
.hero h1 .accent { background: linear-gradient(90deg, #fff, #c9a8ff, #ff4fd8, #fff); background-size: 300% 100%; -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; animation: x-shimmer 7s linear infinite; }
.hero p { max-width: 520px; color: #b9aee0; }
@media (min-width: 901px) { .hero h1, .hero p { max-width: min(560px, 62%); } .hero h1 { font-size: clamp(30px, 3.6vw, 54px); } }
.hero-actions { margin-top: 4px; }
.ff-hero-art { position: absolute; z-index: -1; right: clamp(-60px, -2vw, 10px); top: 50%; width: min(48%, 440px); aspect-ratio: 1; transform: translateY(-50%); pointer-events: none; opacity: .95; filter: drop-shadow(0 0 40px rgba(var(--ff-a), .6)); }
.ha-ring { transform-box: fill-box; transform-origin: center; }
.ha-ring.r1 { animation: ffSpin 60s linear infinite; }
.ha-ring.r2 { animation: ffSpin 42s linear infinite reverse; }
.ha-ring.r3 { animation: ffSpin 30s linear infinite; }
.ha-bolt { animation: ffBolt 2.8s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes ffBolt { 0%, 100% { opacity: .85; transform: scale(1); } 50% { opacity: 1; transform: scale(1.06); } }

/* счётчики */
.stat-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.stat-card { position: relative; display: flex; align-items: center; gap: 14px; padding: 18px 16px; border-radius: 18px; background: linear-gradient(160deg, rgba(26, 14, 56, .78), rgba(9, 5, 20, .9)); border: 1px solid var(--border); overflow: hidden; isolation: isolate;
    transition: transform .3s var(--ff-ease), border-color .3s, box-shadow .3s; }
.stat-card::before { content: ''; position: absolute; inset: 0; z-index: -1; opacity: 0; transition: opacity .3s; background: radial-gradient(240px circle at var(--mx, 50%) var(--my, 0%), rgba(var(--ff-a), .28), transparent 65%); }
.stat-card:hover { transform: translateY(-4px); border-color: rgba(183, 140, 255, .55); box-shadow: 0 14px 40px rgba(0, 0, 0, .5), 0 0 30px rgba(var(--ff-a), .35); }
.stat-card:hover::before { opacity: 1; }
.stat-card .num { font-size: clamp(20px, 2.1vw, 28px); font-variant-numeric: tabular-nums; line-height: 1.1; text-shadow: none; }
.stat-card .lbl { font-size: 11px; letter-spacing: 1px; }
.ff-ico { flex: none; display: grid; place-items: center; width: 46px; height: 46px; border-radius: 14px; color: #d7c0ff; background: linear-gradient(135deg, rgba(var(--ff-a), .4), rgba(var(--ff-a), .1)); border: 1px solid rgba(183, 140, 255, .4); box-shadow: 0 0 20px rgba(var(--ff-a), .35); }
.ff-ico .ni { width: 24px; height: 24px; filter: drop-shadow(0 0 6px rgba(var(--ff-a), 1)); }
.ff-ico.c2 { color: #ffb3f0; background: linear-gradient(135deg, rgba(var(--ff-a2), .35), rgba(var(--ff-a2), .08)); border-color: rgba(255, 79, 216, .4); box-shadow: 0 0 20px rgba(var(--ff-a2), .3); }
.ff-ico.c3 { color: #ffd98a; background: linear-gradient(135deg, rgba(255, 200, 87, .3), rgba(255, 200, 87, .06)); border-color: rgba(255, 200, 87, .4); box-shadow: 0 0 20px rgba(255, 200, 87, .25); }
.ff-ico.c4 { color: #ff9db1; background: linear-gradient(135deg, rgba(255, 77, 109, .3), rgba(255, 77, 109, .06)); border-color: rgba(255, 77, 109, .4); box-shadow: 0 0 20px rgba(255, 77, 109, .25); }

.feature { border-color: var(--border); background: linear-gradient(160deg, rgba(26, 14, 56, .7), rgba(9, 5, 20, .85)); }

/* виджеты */
.ff-widget { position: relative; isolation: isolate; overflow: hidden; padding: 20px; border-radius: 20px; border: 1px solid var(--border);
    background: linear-gradient(160deg, rgba(26, 14, 56, .78), rgba(9, 5, 20, .9)); box-shadow: 0 12px 40px rgba(0, 0, 0, .45), inset 0 1px 0 rgba(255, 255, 255, .05);
    transition: border-color .3s, box-shadow .3s; }
.ff-widget::before { content: ''; position: absolute; inset: 0; z-index: -1; opacity: 0; transition: opacity .35s; background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 0%), rgba(var(--ff-a), .18), transparent 62%); }
.ff-widget:hover { border-color: rgba(183, 140, 255, .42); box-shadow: 0 14px 46px rgba(0, 0, 0, .5), 0 0 34px rgba(var(--ff-a), .2); }
.ff-widget:hover::before { opacity: 1; }
.ff-w-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }
.ff-w-head h3 { display: flex; align-items: center; gap: 10px; margin: 0; font-size: 15px; letter-spacing: .6px; }
.ff-w-head h3 .ni { width: 22px; height: 22px; color: #c4a0ff; filter: drop-shadow(0 0 7px rgba(var(--ff-a), 1)); }
.ff-live-dot { display: inline-flex; align-items: center; gap: 6px; font: 800 10px 'Inter', sans-serif; letter-spacing: 1.6px; color: #ff9db1; }
.ff-live-dot::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: #ff4d6d; box-shadow: 0 0 10px #ff4d6d; animation: ffBlink 1.4s ease-in-out infinite; }
.ff-link, .ff-more { display: inline-flex; align-items: center; justify-content: center; gap: 6px; cursor: pointer; color: #c4a0ff; font: 700 12px 'Inter', sans-serif; border: 1px solid var(--border-strong); background: rgba(var(--ff-a), .1); border-radius: 10px; padding: 7px 12px; transition: background .25s, transform .25s var(--ff-ease), box-shadow .25s, color .25s; }
.ff-link:hover, .ff-more:hover { background: rgba(var(--ff-a), .26); color: #fff; box-shadow: 0 0 18px rgba(var(--ff-a), .5); }
.ff-link:hover .ni, .ff-more:hover .ni { transform: translateX(3px); }
.ff-link .ni, .ff-more .ni { width: 14px; height: 14px; transition: transform .25s var(--ff-ease); }
.ff-more { width: 100%; margin-top: 14px; padding: 11px; }

/* топ игроков */
.ff-top { display: flex; flex-direction: column; }
.ff-toplist { list-style: none; display: grid; gap: 4px; flex: 1; grid-auto-rows: minmax(52px, 1fr); }
.ff-toplist li { display: grid; grid-template-columns: 28px 46px minmax(0, 1fr) auto; align-items: center; gap: 10px; padding: 7px 8px; border-radius: 13px; border: 1px solid transparent; cursor: pointer; transition: background .25s, border-color .25s, transform .25s var(--ff-ease); }
.ff-toplist li:hover { background: rgba(var(--ff-a), .14); border-color: rgba(183, 140, 255, .3); transform: translateX(4px); }
.ff-toplist li.ff-in { animation: ffRise .55s var(--ff-ease) both; animation-delay: calc(var(--i, 0) * 70ms); }
.ff-toplist .av-wrap { padding: 2px; }
.ff-toplist .av-wrap img { width: 38px; height: 38px; border-radius: 9px; object-fit: cover; }
.ff-rank { display: grid; place-items: center; font: 900 14px 'Orbitron', sans-serif; color: var(--muted); }
.ff-rank svg { width: 24px; height: 24px; fill: #ffc857; filter: drop-shadow(0 0 7px rgba(255, 200, 87, .9)); }
.ff-toplist li:nth-child(2) .ff-rank { color: #d9dff0; }
.ff-toplist li:nth-child(3) .ff-rank { color: #f0a06e; }
.ff-nm { font-weight: 700; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ff-nm small { display: block; font-size: 11px; font-weight: 500; color: var(--muted); }
.ff-elo { font: 800 14px 'Orbitron', sans-serif; color: #fff; font-variant-numeric: tabular-nums; text-shadow: 0 0 12px rgba(var(--ff-a), .8); white-space: nowrap; }
.ff-empty { padding: 18px 8px; text-align: center; color: var(--muted); font-size: 13px; }
.ff-skel, .ff-skel-row { height: 52px; border-radius: 13px; background: linear-gradient(100deg, rgba(255, 255, 255, .03) 30%, rgba(var(--ff-a), .16) 50%, rgba(255, 255, 255, .03) 70%); background-size: 250% 100%; animation: ffShimmer 1.4s linear infinite; }
.ff-skel-row { margin-bottom: 8px; }
@keyframes ffShimmer { to { background-position: -150% 0; } }

/* график */
.ff-range { display: inline-flex; gap: 4px; padding: 3px; border-radius: 999px; background: rgba(0, 0, 0, .35); border: 1px solid var(--border); }
.ff-range button { padding: 6px 12px; border: 0; border-radius: 999px; background: transparent; color: var(--muted); font: 700 11px 'Inter', sans-serif; cursor: pointer; transition: background .25s, color .25s, box-shadow .25s; }
.ff-range button:hover { color: #fff; }
.ff-range button.on { color: #fff; background: var(--grad); box-shadow: 0 0 16px rgba(var(--ff-a), .65); }
.ff-chart { display: flex; flex-direction: column; }
.ff-chart-body { position: relative; flex: 1; min-height: 230px; }
.ff-chart-body svg { position: absolute; inset: 0; display: block; width: 100%; height: 100%; overflow: visible; touch-action: pan-y; }
.ff-grid-l { stroke: rgba(167, 120, 255, .12); stroke-width: 1; }
.ff-ax { fill: #8b82b5; font: 600 11px 'Inter', sans-serif; }
.ff-line { fill: none; stroke: url(#ffLineG); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; filter: drop-shadow(0 0 7px rgba(var(--ff-a), .9)); stroke-dasharray: var(--len, 2000); stroke-dashoffset: var(--len, 2000); animation: ffDraw 1.5s var(--ff-ease) .15s forwards; }
.ff-area { fill: url(#ffAreaG); opacity: 0; animation: ffFade .9s ease .7s forwards; }
.ff-dot { fill: #fff; stroke: #b78cff; stroke-width: 2.5; transform-box: fill-box; transform-origin: center; opacity: 0; animation: ffPopDot .45s var(--ff-ease) forwards; animation-delay: calc(.8s + var(--i, 0) * 45ms); }
.ff-guide { stroke: rgba(201, 168, 255, .5); stroke-width: 1; stroke-dasharray: 4 4; opacity: 0; transition: opacity .2s; }
.ff-hov { fill: #fff; stroke: #ff4fd8; stroke-width: 3; opacity: 0; transition: opacity .2s; filter: drop-shadow(0 0 8px #ff4fd8); }
.ff-chart-body.hover .ff-guide, .ff-chart-body.hover .ff-hov { opacity: 1; }
.ff-tip { position: absolute; top: 0; left: 0; z-index: 3; padding: 7px 11px; border-radius: 10px; pointer-events: none; opacity: 0; white-space: nowrap; transform: translate(-50%, -115%); transition: opacity .15s;
    background: rgba(14, 7, 32, .96); border: 1px solid rgba(183, 140, 255, .5); box-shadow: 0 8px 28px rgba(0, 0, 0, .55), 0 0 18px rgba(var(--ff-a), .4); font-size: 12px; text-align: center; }
.ff-tip b { display: block; font: 800 15px 'Orbitron', sans-serif; color: #fff; }
.ff-tip span { color: var(--muted); font-size: 11px; }
.ff-chart-body.hover .ff-tip { opacity: 1; }
.ff-chart-empty { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; color: var(--muted); font-size: 13px; pointer-events: none; padding-bottom: 28px; }
@keyframes ffDraw { to { stroke-dashoffset: 0; } }
@keyframes ffFade { to { opacity: 1; } }
@keyframes ffPopDot { 0% { opacity: 0; transform: scale(0); } 100% { opacity: 1; transform: scale(1); } }

/* последние матчи */
.ff-matches { display: grid; gap: 8px; }
.ff-match { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); grid-template-areas: "l s r" "w w w"; align-items: center; column-gap: 10px; row-gap: 4px; padding: 11px 12px 8px; border-radius: 14px; cursor: pointer;
    background: rgba(255, 255, 255, .025); border: 1px solid var(--border); transition: transform .25s var(--ff-ease), border-color .25s, background .25s, box-shadow .25s; }
.ff-match:hover, .ff-match:focus-visible { transform: translateX(4px); border-color: rgba(183, 140, 255, .55); background: rgba(var(--ff-a), .12); box-shadow: 0 0 22px rgba(var(--ff-a), .25); }
.ff-match.ff-in { animation: ffRise .55s var(--ff-ease) both; animation-delay: calc(var(--i, 0) * 80ms); }
.ff-m-l, .ff-m-r { font-weight: 700; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); }
.ff-m-l { grid-area: l; text-align: right; } .ff-m-r { grid-area: r; }
.ff-m-l.win, .ff-m-r.win { color: #fff; text-shadow: 0 0 12px rgba(var(--ff-a), .8); }
.ff-m-s { grid-area: s; padding: 5px 12px; border-radius: 9px; font: 900 14px 'Orbitron', sans-serif; color: #fff; background: rgba(var(--ff-a), .22); border: 1px solid rgba(183, 140, 255, .4); font-variant-numeric: tabular-nums; }
.ff-m-w { grid-area: w; display: flex; justify-content: center; gap: 8px; align-items: center; font-size: 11px; color: var(--muted); }
.ff-tag { padding: 2px 9px; border-radius: 999px; font-weight: 800; font-size: 10px; letter-spacing: .6px; text-transform: uppercase; }
.ff-tag.win { color: #7dffc8; background: rgba(46, 229, 157, .14); border: 1px solid rgba(46, 229, 157, .4); }
.ff-tag.draw { color: #ffe39a; background: rgba(255, 200, 87, .12); border: 1px solid rgba(255, 200, 87, .4); }

/* битва месяца */
.ff-arena { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; grid-template-areas: "t i c" "t i b"; align-items: center; gap: 8px 22px;
    background: radial-gradient(500px 220px at 0% 0%, rgba(255, 200, 87, .14), transparent 60%), linear-gradient(160deg, rgba(34, 16, 70, .85), rgba(9, 5, 20, .92)); border-color: rgba(255, 200, 87, .28); }
.ff-arena-trophy { grid-area: t; display: grid; place-items: center; width: 96px; height: 96px; border-radius: 24px; color: #ffc857; background: radial-gradient(circle, rgba(255, 200, 87, .25), rgba(255, 200, 87, .04) 70%); border: 1px solid rgba(255, 200, 87, .4); box-shadow: 0 0 40px rgba(255, 200, 87, .25); animation: ffFloat 4.5s ease-in-out infinite; }
.ff-arena-trophy .ni { width: 54px; height: 54px; stroke-width: 1.5; filter: drop-shadow(0 0 12px rgba(255, 200, 87, .95)); }
.ff-arena-info { grid-area: i; min-width: 0; }
.ff-arena-title { font: 800 20px 'Orbitron', sans-serif; line-height: 1.2; }
.ff-arena-lead { margin-top: 6px; font-size: 13px; color: var(--muted); }
.ff-arena-lead b { color: #ffd98a; }
.ff-count { grid-area: c; display: flex; gap: 8px; }
.ff-count > div { display: grid; place-items: center; min-width: 58px; padding: 8px 6px; border-radius: 12px; background: rgba(0, 0, 0, .4); border: 1px solid rgba(183, 140, 255, .35); box-shadow: inset 0 0 18px rgba(var(--ff-a), .2); }
.ff-count b { font: 900 22px 'Orbitron', sans-serif; color: #fff; text-shadow: 0 0 14px rgba(var(--ff-a), .9); font-variant-numeric: tabular-nums; line-height: 1.1; }
.ff-count span { font-size: 10px; letter-spacing: 1px; text-transform: uppercase; color: var(--muted); }
.ff-arena > .btn { grid-area: b; justify-self: end; }
.ff-arena .ff-w-head h3 .ni { color: #ffc857; filter: drop-shadow(0 0 7px rgba(255, 200, 87, .9)); }

/* достижения */
.ff-badges { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; }
.ff-badge { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; cursor: pointer; padding: 6px 2px; border-radius: 14px; transition: transform .3s var(--ff-ease); min-width: 0; }
.ff-badge:hover { transform: translateY(-5px); }
.ff-badge.ff-in { animation: ffPopIn .6s var(--ff-ease) both; animation-delay: calc(var(--i, 0) * 90ms); }
.ff-hexw { filter: drop-shadow(0 0 10px var(--tg, rgba(var(--ff-a), .8))); transition: filter .3s; }
.ff-badge:hover .ff-hexw { filter: drop-shadow(0 0 18px var(--tg, rgba(var(--ff-a), 1))); }
.ff-hex { position: relative; display: grid; place-items: center; width: 62px; height: 70px; clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%); background: var(--tc); }
.ff-hex::before { content: ''; position: absolute; inset: 3px; clip-path: inherit; background: linear-gradient(160deg, #1b0d3c, #0a0518); }
.ff-hex .ni { position: relative; width: 28px; height: 28px; stroke: none; fill: var(--ti, #fff); }
.t-diamond { --tc: linear-gradient(135deg, #a5ecff, #b78cff 55%, #fff); --tg: rgba(150, 220, 255, .85); --ti: #b6eeff; }
.t-gold { --tc: linear-gradient(135deg, #ffe08a, #ff9f1c); --tg: rgba(255, 190, 60, .85); --ti: #ffd36b; }
.t-silver { --tc: linear-gradient(135deg, #f0f4ff, #8d98b5); --tg: rgba(200, 210, 235, .6); --ti: #dfe5f5; }
.t-bronze { --tc: linear-gradient(135deg, #f0a870, #8a4a24); --tg: rgba(224, 139, 90, .65); --ti: #e69a62; }
.t-locked { --tc: linear-gradient(135deg, #3d3260, #2a2145); --tg: rgba(0, 0, 0, 0); --ti: #54497a; opacity: .6; cursor: default; }
.ff-hn { position: relative; font: 900 26px 'Orbitron', sans-serif; color: var(--ti, #fff); text-shadow: 0 0 14px var(--tg); }
.ff-b-t { font: 800 11px 'Orbitron', sans-serif; letter-spacing: .5px; line-height: 1.2; }
.ff-b-n { max-width: 100%; font-size: 11px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@keyframes ffPopIn { from { opacity: 0; transform: translateY(14px) scale(.8); } to { opacity: 1; transform: none; } }

/* ---------- 11. ПЕРЕХОДЫ МЕЖДУ СТРАНИЦАМИ ---------- */
.page.active { animation: ffPageIn .5s var(--ff-ease) both; }
.page.active > *, .page.active .ff-home > * { animation: ffRise .6s var(--ff-ease) both; animation-delay: calc(var(--ff-d, 0) * 65ms); }
.page.active > :nth-child(2), .page.active .ff-home > :nth-child(2) { --ff-d: 1; }
.page.active > :nth-child(3), .page.active .ff-home > :nth-child(3) { --ff-d: 2; }
.page.active > :nth-child(4), .page.active .ff-home > :nth-child(4) { --ff-d: 3; }
.page.active > :nth-child(5), .page.active .ff-home > :nth-child(5) { --ff-d: 4; }
.page.active > :nth-child(6), .page.active .ff-home > :nth-child(6) { --ff-d: 5; }
.page.active > :nth-child(n+7), .page.active .ff-home > :nth-child(n+7) { --ff-d: 6; }
.page.active .ff-home { animation: none; }
@keyframes ffPageIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes ffRise { from { opacity: 0; transform: translateY(22px) scale(.985); } to { opacity: 1; transform: none; } }
.hall-of-fame { animation: ffRise .7s var(--ff-ease) both; }

/* ---------- 12. HOVER-ЭФФЕКТЫ ---------- */
.zb-card, .sc-card, .mini-box, .feature, .media-card, .video-card { transition: transform .3s var(--ff-ease), border-color .3s, box-shadow .3s; }
.zb-card:hover, .zb-card:focus-visible { border-color: rgba(183, 140, 255, .7); box-shadow: 0 0 30px rgba(var(--ff-a), .4); }
.sc-card:hover { transform: translateY(-4px); }
.mini-box:hover { border-color: rgba(183, 140, 255, .4); }
.feature:hover { border-color: var(--fb, #b78cff); }
.feature.f1, .feature:not(.f2):not(.f3):not(.f4) { --fb: #b78cff; --fc: rgba(var(--ff-a), .4); }
.profile-stat { transition: transform .25s var(--ff-ease), border-color .25s, box-shadow .25s; }
.profile-stat:hover { transform: translateY(-3px); border-color: rgba(183, 140, 255, .5); box-shadow: 0 0 24px rgba(var(--ff-a), .3); }
tbody tr[data-uid], tbody tr[data-gid] { cursor: pointer; }
.coin-chip:hover { transform: translateY(-2px); }

/* ---------- 13. АДАПТИВ ---------- */
/* Магазин: колонки сетки должны уметь сжиматься. Без этого превью «Рамок профиля»
   (фиксированные 150px) распирали страницу и на телефоне появлялся горизонтальный скролл. */
.shop-grid > *, .item { min-width: 0; }
.pf-prev-wrap { grid-template-columns: minmax(0, 1fr); }
/* Декор рамок/баннеров по замыслу выходит за карточку; на телефоне обрезаем по краю экрана,
   чтобы Chrome не расширял страницу (clip, а не hidden — вертикальное свечение не режется). */
@media (max-width: 900px) { main.container { overflow-x: clip; } }

/* Анимации карточек/строк, которых сейчас не видно, ставятся на паузу (класс ставит premium.js).
   Внешний вид не меняется — просто не тратится батарея и GPU на то, чего не видно. */
.ff-off, .ff-off *, .ff-off *::before, .ff-off *::after { animation-play-state: paused !important; }

@media (max-width: 1099px) { .ff-badges { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
@media (max-width: 900px) {
    .ff-home { column-gap: 0; }
    .container { padding-top: 4px; }
    .hero { min-height: 0; padding: 26px 20px 24px; }
    .ff-hero-art { width: 70%; right: -22%; top: 38%; opacity: .5; }
    .hero h1 { max-width: 100%; }
    .stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
}
@media (max-width: 640px) {
    .stat-card { flex-direction: row; justify-content: flex-start; padding: 14px 12px; gap: 10px; }
    .ff-ico { width: 40px; height: 40px; border-radius: 12px; }
    .ff-ico .ni { width: 21px; height: 21px; }
    .stat-card .num { font-size: 20px; }
    .stat-card .lbl { font-size: 10px; }
    .ff-widget { padding: 16px; border-radius: 18px; }
    .ff-chart-body { min-height: 200px; }
    .ff-arena { grid-template-columns: auto minmax(0, 1fr); grid-template-areas: "t i" "c c" "b b"; gap: 12px 14px; }
    .ff-arena-trophy { width: 68px; height: 68px; border-radius: 18px; }
    .ff-arena-trophy .ni { width: 38px; height: 38px; }
    .ff-arena-title { font-size: 15px; }
    .ff-count { justify-content: space-between; }
    .ff-count > div { flex: 1; min-width: 0; }
    .ff-arena > .btn { justify-self: stretch; }
    .ff-badges { grid-template-columns: repeat(5, 64px); overflow-x: auto; padding-bottom: 6px; scroll-snap-type: x mandatory; scrollbar-width: none; margin: 0 -4px; padding-inline: 4px; }
    .ff-badges::-webkit-scrollbar { display: none; }
    .ff-badge { scroll-snap-align: start; }
    .ff-toplist li { grid-template-columns: 24px 44px minmax(0, 1fr) auto; gap: 8px; }
    .modal { padding: 0; align-items: flex-end; }
    .modal-card { max-height: 92dvh; border-radius: 22px 22px 0 0; }
    .toast { max-width: calc(100vw - 28px); }
}
@media (max-width: 380px) { .ff-count b { font-size: 18px; } .ff-tagline { font-size: 10px; letter-spacing: 1px; } }
@media (hover: none) { .ff-widget::before, .stat-card::before { display: none; } .card:hover, .ff-widget:hover { box-shadow: 0 12px 40px rgba(0, 0, 0, .45); } }

/* ---------- ПРОЧИЕ СТРАНИЦЫ (admin.html / streamer.html): тот же стиль без сайдбара ---------- */
body:not(.ff-side) .site-header, body:not(.ff-side) header.top { -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); }
body:not(.overlay):not(.ff-side) { --cyan: #b78cff; --violet: #8f3dff; --pink: #ff4fd8; --grad: linear-gradient(135deg, #7a2cff 0%, #b05cff 55%, #ff4fd8 100%); --grad-hot: linear-gradient(135deg, #ff4fd8, #8f3dff); --border: rgba(167, 120, 255, .16); --border-strong: rgba(167, 120, 255, .32); }
body.overlay .ff-bg, body.overlay .ff-loader, body.overlay .ff-progress { display: none !important; }

/* ---------- 15. REDUCED MOTION ---------- */
/* Убрано: раньше при выключенных анимациях Windows гасились ВСЕ анимации (в т.ч. купленные баннеры, рамки и частицы). */
