/* CSS переменные */
        :root {
            --sidebar-width: 250px;
            --sidebar-collapsed-width: 60px;
            --header-height: 70px;
            --transition-duration: 0.3s;

            /* ===== Цветовая палитра (RGB-триплеты) =====
               Использование: rgb(var(--x)) или rgb(var(--x) / 0.5).
               Значения — тёмная тема. Светлая тема в будущем переопределит эти переменные. */
            --color-bg: 15 15 19;
            --color-bg-soft: 21 21 29;
            --color-card: 30 30 40;
            --color-card-soft: 42 42 56;
            --color-card-line: 34 34 44;
            --color-text: 248 250 252;
            --color-text-secondary: 229 231 235;
            --color-text-soft: 209 213 219;
            --color-text-muted: 156 163 175;
            --color-text-faint: 107 114 128;
            --color-text-fainter: 75 85 99;
            --color-text-dark: 31 41 55;
            --color-text-strong: 255 255 255;
            --color-overlay-white: 255 255 255;
            --color-overlay-black: 0 0 0;
            --accent-primary: 59 130 246;
            --accent-primary-light: 96 165 250;
            --accent-primary-dark: 37 99 235;
            --accent-primary-deep: 29 78 216;
            --accent-primary-deepest: 30 58 138;
            --accent-purple: 139 92 246;
            --accent-purple-light: 124 58 237;
            --accent-purple-dark: 109 40 217;
            --accent-gold: 253 185 39;
            --accent-indigo: 102 126 234;
            --accent-indigo-dark: 79 70 229;
            --accent-indigo-deep: 118 75 162;
            --color-purple-lakers: 85 37 131;
            --color-purple-deep: 59 31 94;
            --color-success: 52 211 153;
            --color-success-strong: 34 197 94;
            --color-success-deep: 16 185 129;
            --color-success-pale: 134 239 172;
            --color-danger: 239 68 68;
            --color-danger-strong: 220 38 38;
            --color-danger-light: 248 113 113;
            --color-danger-pale: 252 165 165;
            --color-warning: 245 158 11;
            --color-warning-light: 251 191 36;
            --color-warning-dark: 217 119 6;
        }
        
        /* Базовые стили */
        * {
            box-sizing: border-box;
            margin: 0;
            padding: 0;
        }
        
        body {
            font-family: 'Inter', sans-serif;
            background: rgb(var(--color-bg));
            color: rgb(var(--color-text));
            overflow-x: hidden;
            line-height: 1.5;
            position: relative;
        }
        
        /* Утилитарные классы */
        .sr-only {
            position: absolute;
            width: 1px;
            height: 1px;
            padding: 0;
            margin: -1px;
            overflow: hidden;
            clip: rect(0, 0, 0, 0);
            white-space: nowrap;
            border: 0;
        }
        
        .focus\:outline-none:focus {
            outline: 2px solid rgb(var(--accent-primary));
            outline-offset: 2px;
        }
        
        /* Основные компоненты */
        .strict-bg {
            background: linear-gradient(160deg, rgb(var(--color-bg)) 0%, rgb(var(--color-bg-soft)) 100%);
        }
        
        .strict-card {
            background: rgb(var(--color-card) / 0.7);
            backdrop-filter: blur(10px);
            border: 1px solid rgb(var(--color-overlay-white) / 0.08);
            box-shadow: 0 4px 20px rgb(var(--color-overlay-black) / 0.2);
            transition: all var(--transition-duration) ease;
        }
        
        .strict-card:hover {
            box-shadow: 0 8px 30px rgb(var(--color-overlay-black) / 0.3);
            transform: translateY(-2px);
        }
        
        .strict-nav {
            background: rgb(var(--color-bg) / 0.95);
            backdrop-filter: blur(10px);
            border-bottom: 1px solid rgb(var(--color-overlay-white) / 0.08);
        }
        
        .strict-button {
            background: linear-gradient(135deg, rgb(var(--accent-primary)) 0%, rgb(var(--accent-primary-deep)) 100%);
            border: none;
            position: relative;
            overflow: hidden;
            transition: all var(--transition-duration) ease;
        }
        
        .strict-button:hover {
            background: linear-gradient(135deg, rgb(var(--accent-primary-dark)) 0%, rgb(var(--accent-primary-deep)) 100%);
            box-shadow: 0 4px 15px rgb(var(--accent-primary) / 0.3);
        }
        
        .strict-button-secondary {
            background: rgb(var(--color-overlay-white) / 0.05);
            border: 1px solid rgb(var(--color-overlay-white) / 0.1);
            transition: all var(--transition-duration) ease;
        }
        
        .strict-button-secondary:hover {
            background: rgb(var(--color-overlay-white) / 0.1);
            border-color: rgb(var(--color-overlay-white) / 0.2);
        }
        
        .accent-text {
            background: linear-gradient(90deg, rgb(var(--accent-primary)), rgb(var(--accent-purple)));
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            background-clip: text;
        }
        
        .strict-divider {
            height: 1px;
            background: linear-gradient(90deg, transparent, rgb(var(--accent-primary) / 0.3), transparent);
        }
        
        /* Индикатор LIVE */
        .live-indicator {
            width: 8px;
            height: 8px;
            border-radius: 50%;
            background: rgb(var(--color-danger));
            position: relative;
        }
        
        .live-indicator::after {
            content: '';
            position: absolute;
            top: -2px;
            left: -2px;
            right: -2px;
            bottom: -2px;
            border-radius: 50%;
            background: rgb(var(--color-danger));
            animation: pulse 2s infinite;
        }
        
        @keyframes pulse {
            0% {
                transform: scale(1);
                opacity: 0.8;
            }
            70% {
                transform: scale(2);
                opacity: 0;
            }
            100% {
                transform: scale(2);
                opacity: 0;
            }
        }
        
        /* Табы */
        .strict-tabs {
            display: flex;
            background: rgb(var(--color-overlay-white) / 0.05);
            border-radius: 8px;
            padding: 4px;
        }
        
        .strict-tab {
            flex: 1;
            text-align: center;
            padding: 8px 16px;
            border-radius: 6px;
            cursor: pointer;
            transition: all var(--transition-duration);
            font-weight: 500;
        }
        
        .strict-tab.active {
            background: rgb(var(--accent-primary));
            color: white;
        }
        
        /* Прогресс-бары */
        .strict-progress {
            height: 4px;
            background: rgb(var(--color-overlay-white) / 0.1);
            border-radius: 2px;
            overflow: hidden;
        }
        
        .strict-progress-bar {
            height: 100%;
            background: linear-gradient(90deg, rgb(var(--accent-primary)), rgb(var(--accent-purple)));
            border-radius: 2px;
        }
        
        /* Сетка с тонкими линиями */
        .grid-lines {
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background-image: 
                linear-gradient(rgb(var(--accent-primary) / 0.03) 1px, transparent 1px),
                linear-gradient(90deg, rgb(var(--accent-primary) / 0.03) 1px, transparent 1px);
            background-size: 40px 40px;
            pointer-events: none;
            z-index: -1;
        }
        
        /* Стили для карточек */
        .news-card,
        .stream-card {
            background: rgb(var(--color-card) / 0.7);
            border-radius: 12px;
            overflow: hidden;
            transition: all var(--transition-duration) ease;
            border: 1px solid rgb(var(--color-overlay-white) / 0.08);
        }
        
        .news-card:hover,
        .stream-card:hover {
            transform: translateY(-5px);
            box-shadow: 0 10px 25px rgb(var(--color-overlay-black) / 0.3);
        }
        
        .news-badge {
            position: absolute;
            top: 12px;
            left: 12px;
            background: rgb(var(--accent-primary));
            color: white;
            padding: 4px 10px;
            border-radius: 4px;
            font-size: 12px;
            font-weight: 600;
            z-index: 1;
        }
        
        .news-image {
            height: 120px;
            width: 100%;
            object-fit: cover;
            background: linear-gradient(135deg, rgb(var(--accent-indigo)) 0%, rgb(var(--accent-indigo-deep)) 100%);
        }
        
        /* Стили для бокового меню */
        .sidebar {
            transition: all var(--transition-duration) ease;
            position: sticky;
            top: calc(var(--header-height) + 20px);
            height: auto;
            max-height: calc(100vh - var(--header-height) - 40px);
            overflow-y: auto;
            width: var(--sidebar-width);
            flex-shrink: 0;
            align-self: flex-start;
        }
        
        .sidebar.collapsed {
            width: var(--sidebar-collapsed-width);
        }
        
        .sidebar.collapsed .menu-text {
            display: none;
        }
        
        .sidebar.collapsed .menu-item {
            justify-content: center;
            padding: 10px 0;
        }
        
        .sidebar.collapsed .menu-item .material-icons-outlined {
            margin-right: 0;
            display: flex;
            justify-content: center;
            align-items: center;
        }
        
        .sidebar.collapsed .league-menu-btn .material-icons-outlined:last-child {
            display: none;
        }
        
        .menu-item {
            display: flex;
            align-items: center;
            padding: 10px 14px;
            border-radius: 8px;
            transition: all var(--transition-duration);
            color: rgb(var(--color-text-muted));
            cursor: pointer;
            font-size: 0.9rem;
        }
        
        .menu-item:hover {
            background: rgb(var(--accent-primary) / 0.1);
            color: rgb(var(--accent-primary));
        }
        
        .menu-item.active {
            background: rgb(var(--accent-primary) / 0.2);
            color: rgb(var(--accent-primary-light));
        }

        /* Неактивные пункты меню (для гостей): видно, но не кликается */
        .menu-item-disabled {
            opacity: 0.45;
            cursor: not-allowed;
        }
        .menu-item-disabled:hover {
            background: none;
            color: inherit;
        }

.menu-item.inactive {
    opacity: 0.45;
    color: rgb(var(--color-text-muted));
    cursor: default;
    pointer-events: none;
}

.menu-item.inactive:hover {
    background: transparent;
    color: rgb(var(--color-text-muted));
}
        
        .menu-divider {
            height: 1px;
            background: rgb(var(--color-overlay-white) / 0.1);
            margin: 6px 0;
        }
        
        .menu-item .material-icons-outlined {
            font-size: 1.1rem;
            margin-right: 12px;
        }
        
        /* Стили для авторов трансляций */
        .stream-author {
            display: flex;
            align-items: center;
            padding: 12px;
            border-top: 1px solid rgb(var(--color-overlay-white) / 0.08);
        }
        
        .author-avatar {
            width: 32px;
            height: 32px;
            border-radius: 50%;
            margin-right: 10px;
            object-fit: cover;
            background: linear-gradient(135deg, rgb(var(--accent-indigo)) 0%, rgb(var(--accent-indigo-deep)) 100%);
        }
        
        /* Компактный хедер */
        .compact-header {
            padding-top: 0.75rem;
            padding-bottom: 0.75rem;
            height: var(--header-height);
        }

        .logo a {
            display: inline-flex;
            align-items: center;
        }

        .logo-img {
            height: 2.75rem;
            width: auto;
            display: block;
        }

        .logo-black-img {
            display: none;
        }

        .light-theme .logo-white-img {
            display: none;
        }

        .light-theme .logo-black-img {
            display: block;
        }
        
        .compact-nav-item {
            padding: 0.5rem 1rem;
            font-size: 0.875rem;
        }
        
        .compact-button {
            padding: 0.5rem 1rem;
            font-size: 0.875rem;
        }
        
        .compact-icon-button {
            padding: 0.5rem;
        }
        
        /* Мобильная навигация */
        .mobile-bottom-nav {
            display: none;
            position: fixed;
            bottom: 0;
            left: 0;
            right: 0;
            background: rgb(var(--color-bg));
            border-top: 1px solid rgb(var(--color-overlay-white) / 0.08);
            z-index: 100;
            padding: 8px 0;
        }
        
        .mobile-nav-item {
            flex: 1;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            padding: 5px 0;
            color: rgb(var(--color-text-muted));
            font-size: 10px;
        }
        
        .mobile-nav-item.active {
            color: rgb(var(--accent-primary));
        }
        
.mobile-nav-item .material-icons-outlined {
    font-size: 22px;
    margin-bottom: 2px;
}

/* Мобильная смена лиги (нижнее меню) */
.mobile-league-switch {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 5px 4px;
    color: rgb(var(--color-text-muted));
    font-size: 10px;
    cursor: pointer;
}

.mobile-league-switch .material-icons-outlined {
    font-size: 22px;
    margin-bottom: 2px;
    color: rgb(var(--accent-primary));
}

#mobileLeagueSelect {
    background: transparent;
    border: none;
    color: rgb(var(--color-text-muted));
    font-size: 10px;
    font-weight: 600;
    text-align: center;
    max-width: 92px;
    outline: none;
    cursor: pointer;
    font-family: inherit;
    -webkit-appearance: none;
    appearance: none;
}

#mobileLeagueSelect option {
    background: rgb(var(--color-card));
    color: rgb(var(--color-text));
}
        
        /* Модальные окна */
        .modal-overlay {
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: rgb(var(--color-overlay-black) / 0.8);
            display: flex;
            align-items: center;
            justify-content: center;
            z-index: 1000;
            padding: 20px;
        }
        
        .modal-overlay.hidden {
            display: none !important;
        }
        
        /* Модалка авторизации всегда поверх */
        #loginModal {
            z-index: 2000;
        }
        
        .modal-content {
            max-height: 90%;
            overflow: auto;
            border-radius: 12px;
        }
        
        .profile-tab {
            padding: 12px 16px;
            border-radius: 6px;
            cursor: pointer;
            transition: all var(--transition-duration);
        }
        
        .profile-tab.active {
            background: rgb(var(--accent-primary));
            color: white;
        }
        
        /* Видео контейнер */
        .video-container {
            position: relative;
            width: 100%;
            height: 0;
            padding-bottom: 56.25%; /* 16:9 aspect ratio */
        }
        
        .video-container iframe {
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            border-radius: 8px;
        }
        
        /* Кастомные скроллбары */
        ::-webkit-scrollbar {
            width: 6px;
        }
        
        ::-webkit-scrollbar-track {
            background: rgb(var(--color-card) / 0.5);
        }
        
        ::-webkit-scrollbar-thumb {
            background: linear-gradient(180deg, rgb(var(--accent-primary)), rgb(var(--accent-purple)));
            border-radius: 3px;
        }
        
        /* Светлая тема */
        .light-theme {
            background: linear-gradient(160deg, rgb(var(--color-text)) 0%, #e2e8f0 100%);
            color: rgb(var(--color-text-dark));
        }
        
        .light-theme .strict-card {
            background: rgb(var(--color-overlay-white) / 0.8);
            border: 1px solid rgb(var(--color-overlay-black) / 0.08);
            color: rgb(var(--color-text-dark));
        }
        
        .light-theme .strict-nav {
            background: rgb(var(--color-text) / 0.95);
            border-bottom: 1px solid rgb(var(--color-overlay-black) / 0.08);
        }
        
        .light-theme .strict-button-secondary {
            background: rgb(var(--color-overlay-black) / 0.05);
            border: 1px solid rgb(var(--color-overlay-black) / 0.1);
        }
        
        .light-theme .strict-button-secondary:hover {
            background: rgb(var(--color-overlay-black) / 0.1);
            border-color: rgb(var(--color-overlay-black) / 0.2);
        }
        
        .light-theme .strict-divider {
            background: linear-gradient(90deg, transparent, rgb(var(--accent-primary) / 0.2), transparent);
        }
        
        .light-theme .strict-tabs {
            background: rgb(var(--color-overlay-black) / 0.05);
        }
        
        .light-theme .strict-progress {
            background: rgb(var(--color-overlay-black) / 0.1);
        }
        
        .light-theme .news-card,
        .light-theme .stream-card {
            background: rgb(var(--color-overlay-white) / 0.8);
            border: 1px solid rgb(var(--color-overlay-black) / 0.08);
            color: rgb(var(--color-text-dark));
        }
        
        .light-theme .menu-item:hover {
            background: rgb(var(--accent-primary) / 0.1);
        }
        
        .light-theme .menu-item.active {
            background: rgb(var(--accent-primary) / 0.2);
        }
        
        .light-theme .menu-divider {
            background: rgb(var(--color-overlay-black) / 0.1);
        }
        
        /* Светлая тема для текста в различных элементах */
        .light-theme .text-white {
            color: rgb(var(--color-text-dark)) !important;
        }
        
        .light-theme .text-gray-400 {
            color: rgb(var(--color-text-faint)) !important;
        }
        
        .light-theme .text-gray-300 {
            color: rgb(var(--color-text-fainter)) !important;
        }
        
        .light-theme .text-gray-500 {
            color: rgb(var(--color-text-faint)) !important;
        }
        
        .light-theme .bg-dark-950 {
            color: rgb(var(--color-text-dark)) !important;
        }
        
        .light-theme .partner-card {
            background: rgb(var(--color-overlay-white) / 0.9) !important;
            color: rgb(var(--color-text-dark)) !important;
        }
        
        .light-theme .partner-content h3 {
            color: rgb(var(--color-text-dark)) !important;
        }
        
        .light-theme .partner-content p {
            color: rgb(var(--color-text-faint)) !important;
        }
        
        .light-theme .compact-card {
            color: rgb(var(--color-text-dark)) !important;
        }
        
        .light-theme .stream-author {
            border-top-color: rgb(var(--color-overlay-black) / 0.08);
        }
        
        .light-theme .stream-author div {
            color: rgb(var(--color-text-dark)) !important;
        }
        
        .light-theme .stream-author .text-gray-400 {
            color: rgb(var(--color-text-faint)) !important;
        }
        
        .light-theme .review-item {
            color: rgb(var(--color-text-dark)) !important;
        }
        
        .light-theme .review-item h3 {
            color: rgb(var(--color-text-dark)) !important;
        }
        
        .light-theme .review-item p {
            color: rgb(var(--color-text-faint)) !important;
        }
        
        .light-theme table th {
            color: rgb(var(--color-text-fainter)) !important;
        }
        
        .light-theme table td {
            color: rgb(var(--color-text-dark)) !important;
        }
        
        /* ===== Светлая тема: турниры, кнопки, таблицы, паттерны ===== */
        
        /* Фоновый паттерн (сетка + свечения) */
        .grid-lines {
            background-image:
                radial-gradient(circle at 18% 12%, rgb(var(--accent-primary) / 0.07) 0, transparent 38%),
                radial-gradient(circle at 82% 78%, rgb(var(--accent-purple) / 0.06) 0, transparent 38%),
                linear-gradient(rgb(var(--accent-primary) / 0.035) 1px, transparent 1px),
                linear-gradient(90deg, rgb(var(--accent-primary) / 0.035) 1px, transparent 1px);
            background-size: auto, auto, 40px 40px, 40px 40px;
        }
        
        .light-theme .grid-lines {
            background-image:
                radial-gradient(circle at 18% 12%, rgb(var(--accent-primary) / 0.09) 0, transparent 38%),
                radial-gradient(circle at 82% 78%, rgb(var(--accent-purple) / 0.08) 0, transparent 38%),
                linear-gradient(rgb(var(--accent-primary) / 0.06) 1px, transparent 1px),
                linear-gradient(90deg, rgb(var(--accent-primary) / 0.06) 1px, transparent 1px);
            background-size: auto, auto, 40px 40px, 40px 40px;
        }
        
        /* Меню турнира (вкладки) */
        .light-theme .tourney-tabs-nav {
            background: rgb(var(--color-overlay-white) / 0.85);
            border-color: rgb(var(--color-overlay-black) / 0.1);
        }
        
        .light-theme .tourney-tab {
            color: rgb(var(--color-text-fainter));
        }
        
        .light-theme .tourney-tab:hover {
            color: rgb(var(--color-text-dark));
            background: rgb(var(--color-overlay-black) / 0.05);
        }
        
        .light-theme .tourney-tab.content-filter__item--active {
            color: rgb(var(--color-text-strong));
            background: rgb(var(--accent-primary-dark));
        }
        
        /* Кнопки кругов */
        .light-theme .tourney-lap-btn {
            color: rgb(var(--color-text-fainter));
            background: rgb(var(--color-overlay-white) / 0.85);
            border-color: rgb(var(--color-overlay-black) / 0.12);
        }
        
        .light-theme .tourney-lap-btn:hover {
            color: rgb(var(--color-text-dark));
            background: rgb(var(--color-overlay-black) / 0.05);
        }
        
        .light-theme .tourney-lap-btn.active {
            color: rgb(var(--color-text-strong));
            background: rgb(var(--accent-primary-dark));
            border-color: rgb(var(--accent-primary-dark));
        }
        
        /* Панель смены лиги */
        .light-theme .league-menu-panel {
            background: rgb(var(--color-overlay-white) / 0.95);
            border-color: rgb(var(--color-overlay-black) / 0.1);
        }
        
        /* Поиск и поля форм */
        .light-theme .tourney-search,
        .light-theme .form-control {
            background: rgb(var(--color-overlay-white) / 0.9);
            border-color: rgb(var(--color-overlay-black) / 0.15);
            color: rgb(var(--color-text-dark));
        }
        
        .light-theme .tourney-search::placeholder,
        .light-theme .form-control::placeholder {
            color: rgb(var(--color-text-faint));
        }
        
        /* Синие кнопки и цветные бейджи — текст белый в обеих темах */
        .light-theme .strict-button,
        .light-theme .strict-button .text-white,
        .light-theme .tourney-reg-btn,
        .light-theme .tourney-notice-btn,
        .light-theme .bg-gradient-to-r .text-white {
            color: rgb(var(--color-text-strong)) !important;
        }
        
        /* Заголовок «Официальные партнеры чемпионата» — чёрный в светлой теме */
        .light-theme .accent-text {
            background: none;
            background-clip: border-box;
            -webkit-background-clip: border-box;
            -webkit-text-fill-color: rgb(var(--color-text-dark));
            color: rgb(var(--color-text-dark));
        }
        
        /* Рамки таблиц */
        .light-theme .divide-gray-800 > :not([hidden]) ~ :not([hidden]) {
            border-color: rgb(209 213 219 / var(--tw-divide-opacity, 1)) !important;
        }
        
        .light-theme .tourney-table thead th {
            border-bottom-color: rgb(var(--color-overlay-black) / 0.12);
            color: rgb(var(--color-text-fainter));
        }
        
        .light-theme .tourney-table tbody td {
            border-bottom-color: rgb(var(--color-overlay-black) / 0.08);
            color: rgb(var(--color-text-dark));
        }
        
        .light-theme .tourney-table tbody tr:hover {
            background: rgb(var(--accent-primary) / 0.05);
        }
        
        .light-theme .tourney-table a {
            color: rgb(var(--color-text-dark));
        }
        
        .light-theme .tourney-table a:hover {
            color: rgb(var(--accent-primary-dark));
        }
        
        .light-theme .tourney-info-table td {
            border-bottom-color: rgb(var(--color-overlay-black) / 0.08);
        }
        
        .light-theme .tourney-info-table td:first-child {
            color: rgb(var(--color-text-fainter));
        }
        
        /* Стили для поиска */
        .search-container {
            position: relative;
            transition: all var(--transition-duration) ease;
        }

        .search-form {
            display: flex;
            align-items: center;
            background: rgb(var(--color-overlay-white) / 0.05);
            border: 1px solid rgb(var(--color-overlay-white) / 0.1);
            border-radius: 12px;
            overflow: hidden;
            transition: all var(--transition-duration) ease;
            width: 100%;
            max-width: 400px;
        }

        .search-form:focus-within {
            border-color: rgb(var(--accent-primary));
            background: rgb(var(--color-overlay-white) / 0.08);
            box-shadow: 0 0 0 3px rgb(var(--accent-primary) / 0.1);
        }

        .search-input {
            flex: 1;
            padding: 12px 16px;
            background: transparent;
            border: none;
            color: white;
            font-size: 14px;
            font-family: inherit;
            outline: none;
            width: 100%;
        }

        .search-input::placeholder {
            color: rgb(var(--color-text-muted));
            transition: color var(--transition-duration) ease;
        }

        .search-form:focus-within .search-input::placeholder {
            color: rgb(var(--color-text-faint));
        }

        .search-button {
            background: transparent;
            border: none;
            padding: 12px 16px;
            color: rgb(var(--color-text-muted));
            cursor: pointer;
            transition: all var(--transition-duration) ease;
            display: flex;
            align-items: center;
            justify-content: center;
        }

        .search-button:hover {
            color: rgb(var(--accent-primary));
            background: rgb(var(--accent-primary) / 0.1);
        }

        .search-results {
            position: absolute;
            top: 100%;
            left: 0;
            right: 0;
            background: rgb(var(--color-card) / 0.98);
            backdrop-filter: blur(20px);
            border: 1px solid rgb(var(--color-overlay-white) / 0.1);
            border-radius: 12px;
            margin-top: 8px;
            box-shadow: 0 20px 40px rgb(var(--color-overlay-black) / 0.4);
            z-index: 1000;
            max-height: 400px;
            overflow-y: auto;
            opacity: 0;
            visibility: hidden;
            transform: translateY(-10px);
            transition: all 0.3s ease;
        }

        .search-results.active {
            opacity: 1;
            visibility: visible;
            transform: translateY(0);
        }

        .search-result-item {
            padding: 12px 16px;
            border-bottom: 1px solid rgb(var(--color-overlay-white) / 0.05);
            cursor: pointer;
            transition: all var(--transition-duration) ease;
            display: flex;
            align-items: center;
        }

        .search-result-item:hover {
            background: rgb(var(--accent-primary) / 0.1);
        }

        .search-result-item:last-child {
            border-bottom: none;
        }

        .search-result-avatar {
            width: 36px;
            height: 36px;
            border-radius: 8px;
            display: flex;
            align-items: center;
            justify-content: center;
            font-weight: bold;
            color: white;
            margin-right: 12px;
            flex-shrink: 0;
        }

        .search-result-content {
            flex: 1;
            min-width: 0;
        }

        .search-result-title {
            font-weight: 600;
            color: white;
            font-size: 14px;
            margin-bottom: 2px;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }

        .search-result-subtitle {
            color: rgb(var(--color-text-muted));
            font-size: 12px;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }

        .search-result-type {
            font-size: 10px;
            padding: 2px 6px;
            border-radius: 4px;
            margin-left: 8px;
            background: rgb(var(--accent-primary) / 0.2);
            color: rgb(var(--accent-primary));
            font-weight: 600;
        }

        .no-results {
            padding: 20px;
            text-align: center;
            color: rgb(var(--color-text-muted));
        }

        /* Стили для хлебных крошек */
        .breadcrumb {
            display: flex;
            align-items: center;
            margin-bottom: 1.5rem;
            font-size: 0.875rem;
            color: rgb(var(--color-text-muted));
        }

        .breadcrumb-item {
            display: flex;
            align-items: center;
        }

        .breadcrumb-item:not(:last-child)::after {
            content: "/";
            margin: 0 0.5rem;
            color: rgb(var(--color-text-faint));
        }

        .breadcrumb-item a {
            color: rgb(var(--color-text-muted));
            text-decoration: none;
            transition: color var(--transition-duration) ease;
        }

        .breadcrumb-item a:hover {
            color: rgb(var(--accent-primary));
        }

        .breadcrumb-item span {
            color: rgb(var(--accent-primary));
            font-weight: 500;
        }

        /* Стили для слайдера партнеров */
        .partners-slider {
            position: relative;
            overflow: hidden;
        }

        .partners-track {
            display: flex;
            transition: transform 0.3s ease;
            gap: 1rem;
        }

        .partner-slide {
            flex: 0 0 85%;
            min-width: 0;
        }

        .partner-card {
            background: rgb(var(--color-card) / 0.7);
            border-radius: 12px;
            padding: 1rem;
            display: flex;
            align-items: center;
            border: 1px solid rgb(var(--color-overlay-white) / 0.08);
        }

        .partner-logo-wrap {
            width: 5.5rem;
            height: 5.5rem;
            padding: 5px;
            border-radius: 0.75rem;
            display: flex;
            align-items: center;
            justify-content: center;
            flex-shrink: 0;
            margin-right: 0.75rem;
            overflow: hidden;
            background: rgb(var(--color-overlay-white) / 0.06);
            border: 1px solid rgb(var(--color-overlay-white) / 0.08);
        }

        .partner-logo {
            width: 100%;
            height: 100%;
            object-fit: contain;
            padding: 0.25rem;
        }

        .partner-logo.light {
            display: none;
        }

        .partner-logo-placeholder {
            width: 100%;
            height: 100%;
            display: flex;
            align-items: center;
            justify-content: center;
            color: rgb(var(--color-text-strong));
            font-weight: bold;
            font-size: 1.25rem;
            background: linear-gradient(135deg, rgb(var(--accent-primary)), rgb(var(--accent-purple)));
        }

        .light-theme .partner-logo-wrap {
            background: rgb(var(--color-overlay-black) / 0.04);
            border-color: rgb(var(--color-overlay-black) / 0.08);
        }

        .light-theme .partner-logo.dark {
            display: none;
        }

        .light-theme .partner-logo.light {
            display: block;
        }

        /* Слайдер партнеров на главной */
        .partners-track {
            display: flex;
            overflow-x: auto;
            scroll-snap-type: x mandatory;
            gap: 16px;
            padding-bottom: 8px;
            scrollbar-width: none;
            -ms-overflow-style: none;
            -webkit-overflow-scrolling: touch;
        }

        .partners-track::-webkit-scrollbar {
            display: none;
        }

        .partner-slide {
            flex: 0 0 100%;
            max-width: 100%;
            scroll-snap-align: start;
        }

        @media (min-width: 768px) {
            .partner-slide {
                flex: 0 0 calc((100% - 32px) / 3);
                max-width: calc((100% - 32px) / 3);
            }
        }

        .partners-controls {
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 10px;
            margin-top: 12px;
        }

        .partner-dots {
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
        }

        .partner-arrow {
            width: 28px;
            height: 28px;
            border-radius: 50%;
            border: 1px solid rgb(var(--color-overlay-white) / 0.15);
            background: rgb(var(--color-overlay-white) / 0.05);
            color: rgb(var(--color-text-muted));
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            transition: all 0.2s ease;
        }

        .partner-arrow .material-icons-outlined {
            font-size: 18px;
        }

        .partner-arrow:hover {
            background: rgb(var(--accent-primary) / 0.15);
            color: rgb(var(--color-text-strong));
            border-color: rgb(var(--accent-primary) / 0.4);
        }

        .partner-dot {
            width: 7px;
            height: 7px;
            border-radius: 50%;
            background: rgb(var(--color-overlay-white) / 0.15);
            border: none;
            cursor: pointer;
            transition: all 0.2s ease;
            padding: 0;
        }

        .partner-dot.active {
            background: rgb(var(--accent-primary));
            width: 16px;
            border-radius: 4px;
        }

        /* Ссылка «Все партнеры» (иконка-список) */
        .partner-all-link {
            margin-left: 20px;
            width: 28px;
            height: 28px;
            border-radius: 50%;
            border: 1px solid rgb(var(--color-overlay-white) / 0.15);
            background: rgb(var(--color-overlay-white) / 0.05);
            color: rgb(var(--color-text-muted));
            display: flex;
            align-items: center;
            justify-content: center;
            text-decoration: none;
            transition: all 0.2s ease;
        }

        .partner-all-link .material-icons-outlined {
            font-size: 18px;
        }

        .partner-all-link:hover {
            background: rgb(var(--accent-primary) / 0.15);
            color: rgb(var(--color-text-strong));
            border-color: rgb(var(--accent-primary) / 0.4);
        }

        .light-theme .partner-all-link {
            border-color: rgb(var(--color-overlay-black) / 0.15);
            background: rgb(var(--color-overlay-black) / 0.04);
            color: rgb(var(--color-text-fainter));
        }

        .light-theme .partner-all-link:hover {
            background: rgb(var(--accent-primary) / 0.12);
            color: rgb(var(--color-text-dark));
        }

        .light-theme .partner-arrow {
            border-color: rgb(var(--color-overlay-black) / 0.15);
            background: rgb(var(--color-overlay-black) / 0.04);
            color: rgb(var(--color-text-fainter));
        }

        .light-theme .partner-arrow:hover {
            background: rgb(var(--accent-primary) / 0.12);
            color: rgb(var(--color-text-dark));
        }

        .light-theme .partner-dot {
            background: rgb(var(--color-overlay-black) / 0.15);
        }

        .light-theme .partner-dot.active {
            background: rgb(var(--accent-primary-dark));
        }

/* Оценка судьи/секретаря — мячики */
.match-ball-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    cursor: pointer;
    color: rgb(var(--color-overlay-white) / 0.25);
    transition: all 0.2s ease;
}

.match-ball-icon .material-icons-outlined {
    font-size: 18px;
}

.match-ball-icon.active,
.match-rating-balls:hover .match-ball-icon {
    color: rgb(var(--color-warning-light));
}

.match-rating-balls .match-ball-icon:hover ~ .match-ball-icon {
    color: rgb(var(--color-overlay-white) / 0.25);
}

.light-theme .match-ball-icon {
    color: rgb(var(--color-overlay-black) / 0.25);
}

.light-theme .match-ball-icon.active,
.light-theme .match-rating-balls:hover .match-ball-icon {
    color: rgb(var(--color-warning));
}
        .home-review-bg {
            background:
                radial-gradient(circle at 20% 20%, rgb(var(--accent-primary) / 0.35) 0, transparent 45%),
                radial-gradient(circle at 80% 80%, rgb(var(--accent-purple) / 0.3) 0, transparent 45%),
                linear-gradient(135deg, rgb(var(--accent-primary-deepest)) 0%, rgb(var(--accent-primary-deep)) 45%, rgb(var(--accent-indigo-dark)) 100%);
            position: relative;
            overflow: hidden;
        }

        .home-review-bg::before {
            content: "";
            position: absolute;
            inset: 0;
            background-image:
                linear-gradient(rgb(var(--color-overlay-white) / 0.06) 1px, transparent 1px),
                linear-gradient(90deg, rgb(var(--color-overlay-white) / 0.06) 1px, transparent 1px);
            background-size: 18px 18px;
            pointer-events: none;
        }

        /* Строка тега партнера — фиксированная высота, чтобы названия были на одном уровне */
        .partner-tag-line {
            height: 24px;
            overflow: hidden;
            margin-bottom: 6px;
        }

        /* Тег/заголовок партнера (титульный, технический и т.п.) */
        .partner-tag {
            display: inline-block;
            vertical-align: middle;
            margin-left: 6px;
            padding: 2px 10px;
            border-radius: 999px;
            font-size: 12px;
            font-weight: 600;
            line-height: 1;
            letter-spacing: 0.03em;
            text-transform: uppercase;
            color: rgb(var(--accent-primary-light));
            background: rgb(var(--accent-primary) / 0.12);
            border: 1px solid rgb(var(--accent-primary) / 0.25);
        }

        /* Строка партнера (страница партнеров) */
        .partner-row {
            padding: 1.5rem;
        }

        .partner-row .partner-logo-wrap {
            width: 8rem;
            height: 8rem;
        }

        .partner-row-link {
            word-break: break-all;
        }

        .partner-desc-full {
            display: -webkit-box;
            -webkit-line-clamp: 3;
            -webkit-box-orient: vertical;
            overflow: hidden;
            transition: all 0.2s ease;
        }

        .partner-desc-full.expanded {
            -webkit-line-clamp: unset;
            display: block;
            overflow: visible;
        }

        .partner-expand-btn {
            background: none;
            border: none;
            cursor: pointer;
            padding: 0;
        }

        .partner-expand-btn:hover {
            text-decoration: underline;
        }

        .partner-content {
            flex: 1;
            margin-right: 0.75rem;
        }

        .partner-content h3 {
            font-size: 1rem;
            font-weight: bold;
            color: white;
            margin-bottom: 0.25rem;
        }

        .partner-content p {
            font-size: 0.75rem;
            color: rgb(var(--color-text-muted));
        }

        .partner-link {
            color: rgb(var(--accent-primary));
            display: flex;
            align-items: center;
            justify-content: center;
            flex-shrink: 0;
        }

        .slider-dots {
            display: flex;
            justify-content: center;
            margin-top: 1rem;
            gap: 0.5rem;
        }

        .slider-dot {
            width: 0.5rem;
            height: 0.5rem;
            border-radius: 50%;
            background: rgb(var(--color-overlay-white) / 0.2);
            cursor: pointer;
            transition: all var(--transition-duration) ease;
        }

        .slider-dot.active {
            background: rgb(var(--accent-primary));
            transform: scale(1.2);
        }

        /* МОБИЛЬНАЯ ВЕРСИЯ */
        @media (max-width: 768px) {
            .mobile-bottom-nav {
                display: flex;
            }
            
            .mobile-menu {
                display: none;
            }
            
            .mobile-menu.active {
                display: block;
            }
            
            body {
                padding-bottom: 70px;
            }
            
            .sidebar {
                position: static;
                height: auto;
                margin-bottom: 1rem;
                width: 100% !important;
            }
            
            .main-content {
                width: 100% !important;
                margin-left: 0 !important;
            }
            
            .main-container {
                flex-direction: column;
                max-width: 100%;
            }
            
            /* Скрываем левое меню в мобильной версии */
            .sidebar {
                display: none;
            }
            
            .sidebar.mobile-active {
                display: block;
                position: fixed;
                top: var(--header-height);
                left: 0;
                right: 0;
                bottom: 0;
                z-index: 90;
                width: 100% !important;
                height: calc(100vh - var(--header-height));
                background: rgb(var(--color-bg)) !important;
                backdrop-filter: blur(20px);
                -webkit-backdrop-filter: blur(20px);
                padding: 20px;
                overflow-y: auto;
            }
            
            .sidebar-placeholder {
                display: none;
            }

            /* Стили для кнопки закрытия в мобильном меню */
            .mobile-close-btn {
                display: block !important;
            }
            
            .desktop-toggle-btn {
                display: none !important;
            }

            /* Стили для поиска в мобильной версии */
            .search-container {
                position: static;
                width: auto;
                margin: 0;
                order: 2;
            }

            .search-form {
                display: none;
            }

            .mobile-search-button {
                display: flex;
                align-items: center;
                justify-content: center;
                width: 40px;
                height: 40px;
                border-radius: 10px;
                background: rgb(var(--color-overlay-white) / 0.05);
                color: rgb(var(--color-text-muted));
                cursor: pointer;
                transition: all var(--transition-duration) ease;
                border: 1px solid rgb(var(--color-overlay-white) / 0.1);
                margin-left: 8px;
            }

            .mobile-search-button:hover {
                background: rgb(var(--color-overlay-white) / 0.1);
                color: rgb(var(--accent-primary));
                border-color: rgb(var(--accent-primary) / 0.3);
            }

            .mobile-search-form {
                display: none;
                position: fixed;
                top: 0;
                left: 0;
                right: 0;
                height: var(--header-height);
                background: rgb(var(--color-bg) / 0.98);
                backdrop-filter: blur(20px);
                border-bottom: 1px solid rgb(var(--color-overlay-white) / 0.1);
                z-index: 1001;
                padding: 0 16px;
                align-items: center;
            }

            .mobile-search-form.active {
                display: flex;
                animation: slideDown 0.3s ease;
            }

            .mobile-search-input {
                flex: 1;
                background: transparent;
                border: none;
                color: white;
                font-size: 16px;
                padding: 0 16px;
                outline: none;
                height: 100%;
            }

            .mobile-search-input::placeholder {
                color: rgb(var(--color-text-muted));
            }

            .mobile-search-close {
                background: transparent;
                border: none;
                color: rgb(var(--color-text-muted));
                cursor: pointer;
                padding: 8px;
                border-radius: 6px;
                transition: all var(--transition-duration) ease;
                display: flex;
                align-items: center;
                justify-content: center;
            }

            .mobile-search-close:hover {
                color: white;
                background: rgb(var(--accent-primary) / 0.2);
            }

            .mobile-search-results {
                position: fixed;
                top: var(--header-height);
                left: 0;
                right: 0;
                bottom: 0;
                background: rgb(var(--color-card) / 0.98);
                backdrop-filter: blur(20px);
                z-index: 1000;
                overflow-y: auto;
                padding: 16px;
                display: none;
            }

            .mobile-search-results.active {
                display: block;
            }

            .search-active .logo,
            .search-active .user-actions,
            .search-active .mobile-search-button {
                display: none !important;
            }

            /* Показываем заголовки в мобильном меню всегда */
            .sidebar.mobile-active .menu-text {
                display: inline !important;
            }

            /* Хлебные крошки в мобильной версии */
            .breadcrumb {
                font-size: 0.75rem;
                margin-bottom: 1rem;
                overflow-x: auto;
                white-space: nowrap;
                padding-bottom: 0.5rem;
            }

            .breadcrumb-item:not(:last-child)::after {
                margin: 0 0.25rem;
            }

            /* Кнопка профиля в мобильной версии */
            .profile-button-mobile {
                width: 40px;
                height: 40px;
                border-radius: 10px;
                display: flex;
                align-items: center;
                justify-content: center;
            }
            
            /* Перемещение кнопки поиска вправо к кнопке логина */
            .user-actions {
                display: flex;
                align-items: center;
                order: 1;
            }
            
            .logo {
                order: 0;
            }
            
            .search-container {
                order: 2;
            }
        }
        
        @keyframes slideDown {
            from {
                opacity: 0;
                transform: translateY(-10px);
            }
            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        /* Основная сетка с плавающим меню */
        .main-container {
            display: flex;
            transition: all var(--transition-duration) ease;
            max-width: 88rem;
            margin: 0 auto;
            gap: 1.5rem;
            align-items: flex-start;
        }
        
        .main-content {
            flex: 1;
            transition: all var(--transition-duration) ease;
            min-width: 0;
            padding-bottom: 1.5rem;
        }

        /* Стили для фиксированного меню при прокрутке */
        .sidebar.fixed {
            position: fixed;
            top: calc(var(--header-height) + 20px);
            z-index: 40;
        }

        .sidebar-placeholder {
            width: var(--sidebar-width);
            flex-shrink: 0;
            transition: all var(--transition-duration) ease;
        }

        .sidebar-placeholder.collapsed {
            width: var(--sidebar-collapsed-width);
        }

        /* Стили для аватаров по умолчанию */
        .default-avatar {
            background: linear-gradient(135deg, rgb(var(--accent-indigo)) 0%, rgb(var(--accent-indigo-deep)) 100%);
            display: flex;
            align-items: center;
            justify-content: center;
            color: white;
            font-weight: bold;
        }

        /* Стили для выравнивания кнопки сворачивания меню */
        .sidebar-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 1rem;
        }

        .sidebar-header.collapsed {
            justify-content: center;
        }

        /* Светлая тема для поиска */
        .light-theme .search-form {
            background: rgb(var(--color-overlay-white) / 0.9);
            border-color: rgb(var(--color-overlay-black) / 0.1);
        }

        .light-theme .search-form:focus-within {
            background: rgb(var(--color-overlay-white) / 0.95);
            border-color: rgb(var(--accent-primary));
        }

        .light-theme .search-input {
            color: rgb(var(--color-text-dark));
        }

        .light-theme .search-input::placeholder {
            color: rgb(var(--color-text-faint));
        }

        .light-theme .search-results {
            background: rgb(var(--color-overlay-white) / 0.98);
            border-color: rgb(var(--color-overlay-black) / 0.1);
        }

        .light-theme .search-result-item:hover {
            background: rgb(var(--accent-primary) / 0.08);
        }

        .light-theme .search-result-title {
            color: rgb(var(--color-text-dark));
        }

        .light-theme .search-result-subtitle {
            color: rgb(var(--color-text-faint));
        }

        .light-theme .mobile-search-form {
            background: rgb(var(--color-text) / 0.98);
        }

        .light-theme .mobile-search-input {
            color: rgb(var(--color-text-dark));
        }

        .light-theme .mobile-search-results {
            background: rgb(var(--color-overlay-white) / 0.98);
        }

        /* Десктоп версия - скрываем крестик и мобильные элементы поиска */
        @media (min-width: 769px) {
            .mobile-close-btn {
                display: none !important;
            }
            
            .desktop-toggle-btn {
                display: flex !important;
            }
            
            .mobile-search-button {
                display: none !important;
            }
            
            .mobile-search-form {
                display: none !important;
            }
            
            .search-container {
                width: 400px;
            }

            /* Исправление двойного меню в десктопной версии */
            .sidebar nav:first-of-type {
                display: block !important;
            }
            
            .sidebar nav:not(:first-of-type) {
                display: none !important;
            }
        }

        /* Скрываем элементы при активном поиске в мобильной версии */
        .search-active .logo,
        .search-active .user-actions {
            display: none !important;
        }
        
        /* Стили для достижений */
        .achievement-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
            gap: 1rem;
        }
        
        .achievement-card {
            background: rgb(var(--color-card) / 0.7);
            border-radius: 12px;
            padding: 1rem;
            text-align: center;
            border: 1px solid rgb(var(--color-overlay-white) / 0.08);
            transition: all var(--transition-duration) ease;
        }
        
        .achievement-card:hover {
            transform: translateY(-2px);
            box-shadow: 0 4px 15px rgb(var(--color-overlay-black) / 0.3);
        }
        
        .achievement-icon {
            width: 50px;
            height: 50px;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            margin: 0 auto 0.75rem;
        }
        
        .achievement-progress {
            height: 4px;
            background: rgb(var(--color-overlay-white) / 0.1);
            border-radius: 2px;
            overflow: hidden;
            margin-bottom: 0.5rem;
        }
        
        .achievement-progress-bar {
            height: 100%;
            background: linear-gradient(90deg, rgb(var(--accent-primary)), rgb(var(--accent-purple)));
            border-radius: 2px;
        }
        
        /* Стили для команд */
        .current-teams {
            display: flex;
            flex-direction: column;
            gap: 0.75rem;
        }
        
        .team-card {
            display: flex;
            align-items: center;
            padding: 0.75rem;
            background: rgb(var(--color-overlay-white) / 0.05);
            border-radius: 8px;
        }
        
        .team-logo {
            width: 2.5rem;
            height: 2.5rem;
            border-radius: 8px;
            display: flex;
            align-items: center;
            justify-content: center;
            color: white;
            font-weight: bold;
            margin-right: 0.75rem;
        }
        
        /* Стили для компактных табов */
        .compact-tab {
            padding: 0.5rem 1rem;
            border-radius: 6px;
            cursor: pointer;
            transition: all var(--transition-duration);
            font-weight: 500;
        }
        
        .compact-tab.active {
            background: rgb(var(--accent-primary));
            color: white;
        }
        
        /* Стили для сетки в один ряд */
        .single-row-grid {
            display: grid;
            grid-template-columns: 1fr auto 1fr;
            gap: 0.5rem;
            align-items: center;
        }
        
        /* Стили для ввода счета */
        .score-input {
            background: rgb(var(--color-overlay-white) / 0.05);
            border: 1px solid rgb(var(--color-overlay-white) / 0.1);
            border-radius: 4px;
            text-align: center;
            font-weight: 600;
        }
        
        .score-input:focus {
            outline: none;
            border-color: rgb(var(--accent-primary));
        }
        
        /* Стили для задач */
        .tasks-container {
            display: flex;
            flex-direction: column;
            gap: 1rem;
        }
        
        .task-item {
            background: rgb(var(--color-card) / 0.7);
            border-radius: 12px;
            padding: 1rem;
            border: 1px solid rgb(var(--color-overlay-white) / 0.08);
            transition: all var(--transition-duration) ease;
            display: flex;
            align-items: center;
            gap: 1rem;
        }
        
        .task-item:hover {
            transform: translateY(-2px);
            box-shadow: 0 4px 15px rgb(var(--color-overlay-black) / 0.3);
        }
        
        .task-icon {
            width: 3rem;
            height: 3rem;
            border-radius: 10px;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 1.25rem;
            flex-shrink: 0;
        }
        
        .task-content {
            flex: 1;
        }
        
        .task-title {
            font-weight: 600;
            font-size: 0.9rem;
            margin-bottom: 0.25rem;
            color: white;
        }
        
        .task-description {
            font-size: 0.75rem;
            color: rgb(var(--color-text-muted));
            margin-bottom: 0.5rem;
        }
        
        .task-reward {
            display: flex;
            align-items: center;
            gap: 0.5rem;
            font-size: 0.75rem;
            color: rgb(var(--color-warning-light));
        }
        
        .task-action {
            flex-shrink: 0;
        }
        
        .task-completed {
            opacity: 0.7;
            background: rgb(var(--color-success-strong) / 0.1);
            border-color: rgb(var(--color-success-strong) / 0.3);
        }
        
        /* Стили для контактов партнеров */
        .partner-contacts {
            display: flex;
            flex-direction: column;
            gap: 0.5rem;
            margin-top: 0.5rem;
        }
        
        .partner-contact {
            display: flex;
            align-items: center;
            gap: 0.5rem;
            font-size: 0.75rem;
            color: rgb(var(--color-text-muted));
        }
        
        .partner-contact a {
            color: rgb(var(--accent-primary));
            text-decoration: none;
            transition: color var(--transition-duration) ease;
        }
        
        .partner-contact a:hover {
            color: rgb(var(--accent-primary-light));
        }

/* Фикс: модальные окна скрываются классом .hidden */
.modal-overlay.hidden {
    display: none !important;
}

/* Фиксированная кнопка смены лиги */
.league-switcher {
    position: fixed;
    bottom: 96px;
    left: 16px;
    z-index: 45;
}

.league-switcher-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: 12px;
    background: rgb(var(--accent-primary-dark));
    color: rgb(var(--color-text-strong));
    font-weight: 600;
    font-size: 13px;
    cursor: pointer;
    border: none;
    box-shadow: 0 8px 24px rgb(var(--color-overlay-black) / 0.45);
    transition: background 0.2s ease;
}

.league-switcher-btn:hover {
    background: rgb(var(--accent-primary-deep));
}

.league-switcher-panel {
    position: absolute;
    bottom: 100%;
    left: 0;
    margin-bottom: 8px;
    width: 240px;
    max-height: 340px;
    overflow-y: auto;
    background: rgb(var(--color-card));
    border: 1px solid rgb(var(--color-card-soft));
    border-radius: 12px;
    padding: 6px;
    box-shadow: 0 12px 32px rgb(var(--color-overlay-black) / 0.5);
    display: none;
}

.league-switcher-panel.open {
    display: block;
}

.league-switcher-item {
    display: block;
    width: 100%;
    text-align: left;
    padding: 9px 12px;
    border-radius: 8px;
    color: rgb(var(--color-text-secondary));
    font-size: 13px;
    cursor: pointer;
    background: transparent;
    border: none;
    transition: background 0.2s ease;
}

.league-switcher-item:hover {
    background: rgb(var(--color-overlay-white) / 0.06);
}

.league-switcher-item.active {
    background: rgb(var(--accent-primary-dark));
    color: rgb(var(--color-text-strong));
}

/* Пункт меню выбора лиги */
.league-menu-wrap {
    position: relative;
}

.league-menu-btn {
    color: rgb(var(--accent-primary-light));
    background: rgb(var(--accent-primary) / 0.12);
    border: 1px solid rgb(var(--accent-primary) / 0.25);
    border-radius: 8px;
    cursor: pointer;
}

.league-menu-btn:hover {
    background: rgb(var(--accent-primary) / 0.18);
}

.league-menu-panel {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 6px;
    padding: 6px;
    background: rgb(var(--color-card));
    border: 1px solid rgb(var(--color-card-soft));
    border-radius: 8px;
    max-height: 280px;
    overflow-y: auto;
    z-index: 60;
    box-shadow: 0 12px 30px rgb(var(--color-overlay-black) / 0.5);
}

.league-menu-panel.open {
    display: block;
}

/* Фиксированные размеры изображений в виджетах */
.home-match-logo {
    width: 1.7rem;
    height: 1.7rem;
}

.home-avatar {
    width: 2rem;
    height: 2rem;
}

/* Адаптивность для небольших телефонов */
@media (max-width: 480px) {
    body {
        overflow-x: hidden;
    }

    .compact-header {
        padding-left: 8px;
        padding-right: 8px;
    }

    .logo a {
        font-size: 1rem;
        width: auto;
        height: auto;
    }

    .logo-img {
        height: 2rem;
    }

    .user-actions .strict-button {
        padding: 6px 10px;
        font-size: 12px;
    }

    .user-actions .material-icons-outlined {
        font-size: 14px;
    }

    .main-container {
        padding-left: 12px;
        padding-right: 12px;
    }

    .strict-card {
        padding: 1rem;
    }

    .league-switcher {
        bottom: 84px;
        left: 12px;
    }

    .league-switcher-btn {
        padding: 8px 12px;
        font-size: 12px;
    }

    .league-switcher-panel {
        width: 210px;
    }
}

/* Заголовки групп в результатах поиска */
.search-result-group-title {
    padding: 8px 12px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: rgb(var(--color-text-muted));
    background: rgb(var(--color-overlay-white) / 0.03);
    border-top: 1px solid rgb(var(--color-overlay-white) / 0.06);
}

.search-result-group-title:first-child {
    border-top: none;
}

/* Кнопка "Посмотреть все" в результатах поиска */
.search-result-view-all {
    display: block;
    padding: 10px;
    text-align: center;
    font-size: 13px;
    font-weight: 600;
    color: rgb(var(--accent-primary));
    border-top: 1px solid rgb(var(--color-overlay-white) / 0.06);
    text-decoration: none;
    transition: background 0.2s ease;
}

.search-result-view-all:hover {
    background: rgb(var(--accent-primary) / 0.08);
}

/* Полная страница результатов поиска */
.sr-logo {
    width: 2rem;
    height: 2rem;
    border-radius: 8px;
    object-fit: cover;
    flex-shrink: 0;
}

.sr-logo-letter {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgb(var(--accent-primary)), rgb(var(--accent-purple)));
    color: rgb(var(--color-text-strong));
    font-weight: 700;
}

.sr-team {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 10px;
    background: rgb(var(--color-overlay-white) / 0.03);
    border: 1px solid rgb(var(--color-overlay-white) / 0.06);
    text-decoration: none;
    transition: background 0.2s ease, border-color 0.2s ease;
}

.sr-team:hover {
    background: rgb(var(--color-overlay-white) / 0.06);
    border-color: rgb(var(--accent-primary) / 0.4);
}

.sr-team-info {
    display: flex;
    flex-direction: column;
}

.sr-team-name {
    color: rgb(var(--color-text-strong));
    font-weight: 600;
    font-size: 14px;
}

.sr-team-meta {
    color: rgb(var(--color-text-muted));
    font-size: 12px;
}

.sr-match {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 10px;
    background: rgb(var(--color-overlay-white) / 0.03);
    border: 1px solid rgb(var(--color-overlay-white) / 0.06);
    text-decoration: none;
    color: rgb(var(--color-text-secondary));
    font-size: 14px;
    transition: background 0.2s ease, border-color 0.2s ease;
}

.sr-match:hover {
    background: rgb(var(--color-overlay-white) / 0.06);
    border-color: rgb(var(--accent-primary) / 0.4);
}

.sr-match-score {
    font-weight: 700;
    color: rgb(var(--accent-primary));
}

.sr-match-date {
    color: rgb(var(--color-text-muted));
    font-size: 12px;
}

.sr-review {
    display: block;
    padding: 10px 12px;
    border-radius: 10px;
    background: rgb(var(--color-overlay-white) / 0.03);
    border: 1px solid rgb(var(--color-overlay-white) / 0.06);
    text-decoration: none;
    transition: background 0.2s ease, border-color 0.2s ease;
}

.sr-review:hover {
    background: rgb(var(--color-overlay-white) / 0.06);
    border-color: rgb(var(--accent-primary) / 0.4);
}

.sr-review-title {
    color: rgb(var(--color-text-strong));
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 2px;
}

.sr-review-date {
    color: rgb(var(--color-text-muted));
    font-size: 12px;
}

/* Хлебные крошки (speedbar) */
.speedbar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    font-size: 13px;
    color: rgb(var(--color-text-faint));
    margin-bottom: 16px;
}

.speedbar a {
    color: rgb(var(--color-text-muted));
    text-decoration: none;
    transition: color 0.2s ease;
}

.speedbar a:hover {
    color: rgb(var(--accent-primary));
}

/* Навигация турнира */
.tourney-tabs-nav {
    border: 1px solid rgb(var(--color-card-soft));
    border-radius: 12px;
    background: rgb(var(--color-card));
    padding: 4px;
}

.tourney-tab {
    display: inline-block;
    padding: 8px 14px;
    border-radius: 8px;
    font-size: 13px;
    color: rgb(var(--color-text-muted));
    text-decoration: none;
    white-space: nowrap;
    transition: all 0.2s ease;
}

.tourney-tab:hover {
    color: rgb(var(--color-text-strong));
    background: rgb(var(--color-overlay-white) / 0.04);
}

.tourney-tab.content-filter__item--active {
    color: rgb(var(--color-text-strong));
    background: rgb(var(--accent-primary-dark));
}

.tourney-league-list {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin: 16px 0;
}

.tourney-league-card {
    width: 100%;
}

@media (min-width: 768px) {
    .tourney-league-card {
        width: calc(33.333% - 12px);
    }
}

.tourney-layout {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

@media (min-width: 1024px) {
    .tourney-layout {
        flex-direction: row;
        align-items: flex-start;
    }
}

.tourney-sidebar {
    width: 100%;
    flex-shrink: 0;
}

@media (min-width: 1024px) {
    .tourney-sidebar {
        width: 300px;
    }
}

/* Контентная колонка страниц турнира */
.col-sm-9,
.col-sm-12,
.review-page {
    flex: 1;
    min-width: 0;
}

.site-content {
    padding: 16px 0;
}

/* Таблицы турнира */
.tourney-table-wrap {
    overflow-x: auto;
}

.tourney-table {
    width: 100%;
    font-size: 13px;
    border-collapse: collapse;
}

.tourney-table thead th {
    text-align: center;
    padding: 10px 12px;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: rgb(var(--color-text-muted));
    border-bottom: 1px solid rgb(var(--color-card-soft));
    white-space: nowrap;
}

.tourney-table tbody td {
    padding: 10px 12px;
    border-bottom: 1px solid rgb(var(--color-card-line));
    color: rgb(var(--color-text-secondary));
}

.tourney-table tbody tr:hover {
    background: rgb(var(--color-overlay-white) / 0.03);
}

/* Чередование строк таблицы */
.tourney-table tbody tr:nth-child(odd) {
    background: rgb(var(--color-overlay-white) / 0.02);
}

.light-theme .tourney-table tbody tr:nth-child(odd) {
    background: rgb(var(--color-overlay-black) / 0.02);
}

/* Серия последних матчей (точки) — цвета Lakers: золото (победа) / пурпур (поражение) */
.series-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    margin: 0 2px;
    vertical-align: middle;
}

.series-win {
    background: rgb(var(--accent-gold));
    box-shadow: 0 0 4px rgb(var(--accent-gold) / 0.6);
}

.series-lose {
    background: rgb(var(--color-purple-lakers));
    box-shadow: 0 0 6px rgb(var(--color-purple-lakers) / 0.7);
    border: 1px solid rgb(var(--color-overlay-white) / 0.18);
}

/* Стрелки изменения позиции */
.position-col {
    width: 28px;
}

.position-arrow {
    font-size: 12px;
}

.arrow-up {
    color: rgb(var(--color-success-strong));
}

.arrow-down {
    color: rgb(var(--color-danger));
}

.arrow-stay {
    color: rgb(var(--color-text-faint));
}

.tourney-table a {
    color: rgb(var(--color-text-secondary));
    text-decoration: none;
    transition: color 0.2s ease;
}

.tourney-table a:hover {
    color: rgb(var(--accent-primary-light));
}

.tac {
    text-align: center;
}

.mobile_hide,
.hide_mobile {
}

@media (max-width: 768px) {
    .mobile_hide,
    .hide_mobile {
        display: none;
    }
}

/* Кнопки кругов */
.tourney-lap-btn {
    display: inline-block;
    padding: 6px 14px;
    border-radius: 8px;
    font-size: 13px;
    color: rgb(var(--color-text-muted));
    background: rgb(var(--color-card));
    border: 1px solid rgb(var(--color-card-soft));
    text-decoration: none;
    transition: all 0.2s ease;
}

.tourney-lap-btn:hover {
    color: rgb(var(--color-text-strong));
    background: rgb(var(--color-card-soft));
}

.tourney-lap-btn.active {
    color: rgb(var(--color-text-strong));
    background: rgb(var(--accent-primary-dark));
    border-color: rgb(var(--accent-primary-dark));
}

/* Поиск в таблицах */
.tourney-search {
    width: 100%;
    max-width: 320px;
    padding: 8px 12px;
    border-radius: 8px;
    border: 1px solid rgb(var(--color-card-soft));
    background: rgb(var(--color-bg-soft));
    color: rgb(var(--color-text-secondary));
    font-size: 14px;
    font-family: inherit;
}

.tourney-search:focus {
    outline: none;
    border-color: rgb(var(--accent-primary));
}

/* Информационные таблицы (общая информация) */
.tourney-info-table {
    width: 100%;
    font-size: 14px;
}

.tourney-info-table td {
    padding: 8px 12px;
    border-bottom: 1px solid rgb(var(--color-card-line));
}

.tourney-info-table td:first-child {
    color: rgb(var(--color-text-muted));
    width: 45%;
}

/* Карточки команд (участники) */
.team-card-item:hover {
    transform: translateY(-2px);
    border-color: rgb(var(--accent-primary));
}

/* Сетка списка турниров */
.tourney-list-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}

/* Сетка плей-офф (bracket) */
.tournament-bracket {
    display: flex;
    gap: 24px;
    align-items: flex-start;
    padding-bottom: 16px;
}

.tournament-bracket__round {
    display: flex;
    flex-direction: column;
    gap: 12px;
    min-width: 220px;
}

.tournament-bracket__round-title {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: rgb(var(--color-text-muted));
    margin: 0 0 4px;
}

.tournament-bracket__list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    list-style: none;
    padding: 0;
    margin: 0;
}

.tournament-bracket__match {
    background: rgb(var(--color-card));
    border: 1px solid rgb(var(--color-card-soft));
    border-radius: 10px;
    padding: 8px;
}

.tournament-bracket__caption {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11px;
    color: rgb(var(--color-text-muted));
    padding: 0 6px 4px;
}

.tournament-bracket__caption a {
    color: rgb(var(--color-text-muted));
    text-decoration: none;
}

.tournament-bracket__caption a:hover {
    color: rgb(var(--accent-primary-light));
}

.tournament-bracket__table {
    width: 100%;
    border-collapse: collapse;
}

.tournament-bracket__country {
    padding: 4px 6px;
    color: rgb(var(--color-text-secondary));
    font-size: 13px;
}

.tournament-bracket__score {
    text-align: right;
    padding: 4px 6px;
    white-space: nowrap;
}

.tournament-bracket__number {
    color: rgb(var(--color-text-strong));
    font-weight: 600;
}

.tournament-bracket__team.winner .tournament-bracket__country,
.tournament-bracket__team.winner .tournament-bracket__number {
    color: rgb(var(--accent-primary-light));
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

.float-right {
    float: right;
}

/* Формы (совместимость с Bootstrap-классами) */
.form-control {
    width: 100%;
    padding: 8px 12px;
    border-radius: 8px;
    border: 1px solid rgb(var(--color-card-soft));
    background: rgb(var(--color-bg-soft));
    color: rgb(var(--color-text-secondary));
    font-size: 14px;
    font-family: inherit;
}

.form-control:focus {
    outline: none;
    border-color: rgb(var(--accent-primary));
}

.form-group {
    margin-bottom: 12px;
}

.btn {
    display: inline-block;
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    border: 1px solid transparent;
}

.btn-primary {
    background: rgb(var(--accent-primary-dark));
    color: rgb(var(--color-text-strong));
}

.btn-primary:hover {
    background: rgb(var(--accent-primary-deep));
}

.btn-success {
    background: #16a34a;
    color: rgb(var(--color-text-strong));
}

.btn-danger {
    background: rgb(var(--color-danger-strong));
    color: rgb(var(--color-text-strong));
}

.btn-sm {
    padding: 5px 12px;
    font-size: 12px;
}

.btn-block {
    display: block;
    width: 100%;
}

/* Сетка Bootstrap (совместимость) */
.col-xs-12,
.col-sm-12,
.col-md-12 {
    width: 100%;
}

.col-sm-6,
.col-md-4,
.col-md-6 {
    width: 100%;
}

@media (min-width: 768px) {
    .col-sm-6 {
        width: 50%;
    }

    .col-md-4 {
        width: 33.333%;
    }

    .col-md-6 {
        width: 50%;
    }
}

/* Сетка списка новостей */
.news-list-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1rem;
}

/* Пагинация */
.dle-navigation {
    padding: 20px 0;
    grid-column: 1 / -1;
}

.dle-nav-pages {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    flex-wrap: wrap;
}

.dle-nav-pages a,
.dle-nav-pages span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 38px;
    height: 38px;
    padding: 0 12px;
    border-radius: 10px;
    font-size: 14px;
    margin: 0 2px;
}

.dle-nav-pages a {
    color: rgb(var(--color-text-secondary));
    background: rgb(var(--color-card));
    border: 1px solid rgb(var(--color-card-soft));
    text-decoration: none;
    transition: all 0.2s ease;
}

.dle-nav-pages a:hover {
    background: rgb(var(--color-card-soft));
    color: rgb(var(--color-text-strong));
    border-color: rgb(var(--accent-primary));
}

.dle-nav-pages span {
    color: rgb(var(--color-text-strong));
    background: rgb(var(--accent-primary-dark));
    font-weight: 600;
}

.dle-nav-pages span.nav_ext {
    background: transparent;
    border: none;
    color: rgb(var(--color-text-muted));
    min-width: auto;
    padding: 0 4px;
}

/* ============================================
   СТРАНИЦА КОМАНДЫ (дизайн по .team)
   ============================================ */

/* Градиенты для цветов */
.gradient-blue { background: linear-gradient(135deg, rgb(var(--accent-primary)) 0%, rgb(var(--accent-primary-deep)) 100%); }
.gradient-red { background: linear-gradient(135deg, rgb(var(--color-danger)) 0%, rgb(var(--color-danger-strong)) 100%); }
.gradient-green { background: linear-gradient(135deg, rgb(var(--color-success-deep)) 0%, #059669 100%); }
.gradient-purple { background: linear-gradient(135deg, rgb(var(--accent-purple)) 0%, rgb(var(--accent-purple-light)) 100%); }
.gradient-yellow { background: linear-gradient(135deg, rgb(var(--color-warning)) 0%, rgb(var(--color-warning-dark)) 100%); }
.gradient-indigo { background: linear-gradient(135deg, #6366f1 0%, rgb(var(--accent-indigo-dark)) 100%); }
.gradient-pink { background: linear-gradient(135deg, #ec4899 0%, #db2777 100%); }
.gradient-teal { background: linear-gradient(135deg, #14b8a6 0%, #0d9488 100%); }
.gradient-orange { background: linear-gradient(135deg, #f97316 0%, #ea580c 100%); }
.gradient-cyan { background: linear-gradient(135deg, #06b6d4 0%, #0891b2 100%); }

/* Универсальные классы для аватаров и иконок */
.avatar-circle {
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgb(var(--color-text-strong));
    font-weight: bold;
}

.avatar-sm { width: 2rem; height: 2rem; font-size: 0.75rem; }
.avatar-md { width: 2.5rem; height: 2.5rem; font-size: 0.875rem; }
.avatar-lg { width: 3rem; height: 3rem; font-size: 1rem; }

.icon-sm { width: 1.5rem; height: 1.5rem; font-size: 0.75rem; }
.icon-md { width: 2rem; height: 2rem; font-size: 1rem; }
.icon-lg { width: 2.5rem; height: 2.5rem; font-size: 1.25rem; }

/* Компактные классы для отступов и текста */
.p-compact { padding: 0.75rem; }
.px-compact { padding-left: 0.75rem; padding-right: 0.75rem; }
.py-compact { padding-top: 0.75rem; padding-bottom: 0.75rem; }
.text-compact { font-size: 0.875rem; }
.text-xs-compact { font-size: 0.75rem; }

/* Карточка матча */
.card-match { border-left-width: 4px; }
.card-match-blue { border-left-color: rgb(var(--accent-primary)); }
.card-match-red { border-left-color: rgb(var(--color-danger)); }
.card-match-green { border-left-color: rgb(var(--color-success-deep)); }
.card-match-purple { border-left-color: rgb(var(--accent-purple)); }

/* Фоновые градиенты для потоков */
.stream-bg-red { background: linear-gradient(to right, rgb(var(--color-danger) / 0.3), rgb(var(--color-danger-strong) / 0.3)); }
.stream-bg-blue { background: linear-gradient(to right, rgb(var(--accent-primary) / 0.3), rgb(var(--accent-primary-dark) / 0.3)); }
.stream-bg-purple { background: linear-gradient(to right, rgb(var(--accent-purple) / 0.3), rgb(var(--accent-purple-light) / 0.3)); }

/* Фото игрока */
.player-photo {
    width: 96px;
    height: 96px;
    object-fit: cover;
    border-radius: 12px;
    background: linear-gradient(135deg, rgb(var(--color-card)) 0%, rgb(var(--color-card-soft)) 100%);
}

.player-photo-modal img {
    max-width: 90vw;
    max-height: 90vh;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgb(var(--color-overlay-black) / 0.5);
}

@media (max-width: 768px) {
    .player-photo {
        width: 72px;
        height: 72px;
    }
}

/* Карточка игрока (состав / дозаявки / фанаты) */
.player-card {
    position: relative;
    background: rgb(var(--color-card) / 0.7);
    border-radius: 12px;
    border: 1px solid rgb(var(--color-overlay-white) / 0.08);
    padding: 1rem;
    text-align: center;
    transition: all var(--transition-duration) ease;
}

.player-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgb(var(--color-overlay-black) / 0.3);
    border-color: rgb(var(--accent-primary) / 0.3);
}

.player-card-status {
    position: absolute;
    top: 8px;
    left: 8px;
    font-size: 10px;
    padding: 3px 10px;
    border-radius: 999px;
    background: rgb(var(--accent-primary) / 0.9);
    color: rgb(var(--color-text-strong));
    font-weight: 600;
    z-index: 1;
    white-space: nowrap;
}

.player-card-status .green {
    color: rgb(var(--color-success-pale));
}

.player-card-status .blue {
    color: #bfdbfe;
}

.player-card .btn,
.player-card a.btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    padding: 5px 12px;
    border-radius: 6px;
    color: rgb(var(--color-text-secondary));
    background: rgb(var(--color-overlay-white) / 0.06);
    border: 1px solid rgb(var(--color-overlay-white) / 0.1);
    text-decoration: none;
    transition: all 0.3s ease;
    margin: 2px;
}

.player-card .btn:hover,
.player-card a.btn:hover {
    background: rgb(var(--accent-primary) / 0.15);
    border-color: rgb(var(--accent-primary) / 0.4);
    color: rgb(var(--color-text-strong));
}

/* Шестеренка управления игроком */
.player-gear-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 28px;
    height: 28px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgb(var(--color-overlay-white) / 0.06);
    border: 1px solid rgb(var(--color-overlay-white) / 0.1);
    color: rgb(var(--color-text-muted));
    cursor: pointer;
    transition: all var(--transition-duration) ease;
    z-index: 2;
}

.player-gear-btn:hover {
    background: rgb(var(--accent-primary) / 0.15);
    color: rgb(var(--accent-primary-light));
    border-color: rgb(var(--accent-primary) / 0.4);
}

.player-gear-menu {
    position: absolute;
    top: 40px;
    right: 8px;
    width: 180px;
    background: rgb(var(--color-card));
    border: 1px solid rgb(var(--color-overlay-white) / 0.1);
    border-radius: 10px;
    padding: 4px;
    box-shadow: 0 20px 40px rgb(var(--color-overlay-black) / 0.4);
    z-index: 40;
    text-align: left;
}

.player-gear-item {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    text-align: left;
    padding: 8px 10px;
    font-size: 0.75rem;
    color: rgb(var(--color-text));
    border-radius: 6px;
    text-decoration: none;
    transition: background 0.3s ease;
    margin: 0;
}

.player-gear-item:hover {
    background: rgb(var(--color-overlay-white) / 0.06);
}

.player-gear-item.danger {
    color: rgb(var(--color-danger-light));
}

.player-gear-item.danger:hover {
    background: rgb(var(--color-danger) / 0.1);
}

.player-gear-divider {
    height: 1px;
    background: rgb(var(--color-overlay-white) / 0.08);
    margin: 6px 4px;
}

.player-gear-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    font-size: 0.7rem;
    color: rgb(var(--color-text-muted));
    line-height: 1.4;
}

.player-gear-meta .material-icons-outlined {
    font-size: 0.9rem;
    color: rgb(var(--color-text-faint));
}

.team-staff-divider {
    height: 1px;
    background: rgb(var(--color-overlay-white) / 0.06);
}

/* Страница редактирования команды */
.edit-file-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 14px;
    border-radius: 8px;
    background: rgb(var(--color-overlay-white) / 0.05);
    border: 1px dashed rgb(var(--color-overlay-white) / 0.2);
    color: rgb(var(--color-text-muted));
    font-size: 0.75rem;
    cursor: pointer;
    transition: all var(--transition-duration) ease;
}

.edit-file-label:hover {
    border-color: rgb(var(--accent-primary));
    color: rgb(var(--accent-primary-light));
    background: rgb(var(--accent-primary) / 0.1);
}

.edit-file-label input {
    display: none;
}

.team-role-badge {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 999px;
    background: rgb(var(--accent-primary) / 0.15);
    color: rgb(var(--accent-primary-light));
    font-size: 0.68rem;
    font-weight: 600;
    margin-top: 4px;
}

/* Результаты поиска игроков */
.search-user-item {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 10px 12px;
    border-radius: 10px;
    background: rgb(var(--color-overlay-white) / 0.04);
    border: 1px solid rgb(var(--color-overlay-white) / 0.08);
    color: rgb(var(--color-text-secondary));
    font-size: 0.8rem;
    text-align: left;
    cursor: pointer;
    transition: all var(--transition-duration) ease;
}

.search-user-item:hover {
    background: rgb(var(--accent-primary) / 0.1);
    border-color: rgb(var(--accent-primary) / 0.35);
    color: rgb(var(--color-text-strong));
}

.search-user-foto {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    object-fit: cover;
    flex-shrink: 0;
}

.search-user-name {
    display: block;
    color: rgb(var(--color-text-secondary));
    font-size: 0.8rem;
}

.search-user-birth {
    display: block;
    color: rgb(var(--color-text-muted));
    font-size: 0.7rem;
    margin-top: 2px;
}

.search-user-item .material-icons-outlined {
    color: rgb(var(--accent-primary));
}

/* Замена фото игрока внутри шестерёнки */
.player-gear-menu .edit-file-label {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    margin: 2px 0;
    padding: 8px 10px;
    font-size: 0.75rem;
    border: none;
    border-radius: 6px;
    background: transparent;
    color: rgb(var(--color-text));
    cursor: pointer;
    transition: background 0.3s ease;
}

.player-gear-menu .edit-file-label:hover {
    background: rgb(var(--color-overlay-white) / 0.06);
}

.player-gear-menu .edit-file-label input {
    display: none;
}

/* Логотип спонсора */
.partner-logo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: inherit;
}

/* Профиль пользователя (userinfo.tpl) */
.timezoneselect,
.twofactorselect,
select.form-control {
    width: 100%;
    padding: 9px 12px;
    border-radius: 8px;
    background: rgb(var(--color-overlay-white) / 0.05);
    border: 1px solid rgb(var(--color-overlay-white) / 0.1);
    color: rgb(var(--color-text));
    font-size: 0.8rem;
    outline: none;
}

.timezoneselect:focus,
.twofactorselect:focus,
select.form-control:focus {
    border-color: rgb(var(--accent-primary));
}

.timezoneselect option,
.twofactorselect option,
select.form-control option {
    background: rgb(var(--color-card));
    color: rgb(var(--color-text));
}

.xfields {
    width: 100%;
    border-collapse: collapse;
}

.xfields td {
    padding: 6px 0;
    color: rgb(var(--color-text-secondary));
    font-size: 0.8rem;
    vertical-align: middle;
}

.xfields input[type="text"],
.xfields input[type="password"],
.xfields select,
.xfields textarea {
    width: 100%;
    padding: 9px 12px;
    border-radius: 8px;
    background: rgb(var(--color-overlay-white) / 0.05);
    border: 1px solid rgb(var(--color-overlay-white) / 0.1);
    color: rgb(var(--color-text));
    font-size: 0.8rem;
    outline: none;
}

.xfields input:focus,
.xfields select:focus,
.xfields textarea:focus {
    border-color: rgb(var(--accent-primary));
}

.ignore-list-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    margin: 2px;
    border-radius: 8px;
    background: rgb(var(--color-overlay-white) / 0.05);
    border: 1px solid rgb(var(--color-overlay-white) / 0.08);
}

.profile-team-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    border-radius: 8px;
    background: rgb(var(--color-overlay-white) / 0.04);
    border: 1px solid rgb(var(--color-overlay-white) / 0.07);
    font-size: 0.8rem;
}

.profile-team-item .material-icons-outlined {
    color: rgb(var(--accent-primary));
    flex-shrink: 0;
}

.profile-team-item span:nth-child(2) {
    flex: 1;
    min-width: 0;
}

/* Навигация по турниру (страницы редактирования) */
.tourney-nav {
    background: rgb(var(--color-overlay-white) / 0.03);
    border: 1px solid rgb(var(--color-overlay-white) / 0.07);
}

.tourney-nav-link {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    border-radius: 8px;
    background: rgb(var(--color-overlay-white) / 0.04);
    border: 1px solid rgb(var(--color-overlay-white) / 0.08);
    color: rgb(var(--color-text-secondary));
    font-size: 0.75rem;
    text-decoration: none;
    transition: all var(--transition-duration) ease;
}

.tourney-nav-link:hover {
    background: rgb(var(--accent-primary) / 0.12);
    border-color: rgb(var(--accent-primary) / 0.35);
    color: rgb(var(--color-text-strong));
}

.tourney-nav-sep {
    width: 1px;
    height: 18px;
    background: rgb(var(--color-overlay-white) / 0.12);
    margin: 0 4px;
}

/* Иконка уведомления (info.tpl / msgbox) */
.info-icon {
    width: 56px;
    height: 56px;
}

/* Шахматка: подсветка строки и столбца при наведении */
.tourney-table tr.shakhmat-row-active td {
    background: rgb(var(--accent-primary) / 0.08);
}

.tourney-table td.shakhmat-col-active {
    background: rgb(var(--accent-primary) / 0.08);
}

.tourney-table td.shakhmat-col-active.shakhmat-row-active {
    background: rgb(var(--accent-primary) / 0.18);
}

/* Редактирование матча */
.add_address {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    border-radius: 8px;
    background: rgb(var(--color-overlay-white) / 0.04);
    border: 1px solid rgb(var(--color-overlay-white) / 0.08);
    color: rgb(var(--color-text-secondary));
    font-size: 0.75rem;
    cursor: pointer;
    transition: all var(--transition-duration) ease;
}

.add_address:hover {
    background: rgb(var(--accent-primary) / 0.12);
    border-color: rgb(var(--accent-primary) / 0.35);
    color: rgb(var(--color-text-strong));
}

.remove_address {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    border-radius: 8px;
    background: rgb(var(--color-danger) / 0.08);
    border: 1px solid rgb(var(--color-danger) / 0.2);
    color: rgb(var(--color-danger-pale));
    font-size: 0.75rem;
    cursor: pointer;
    transition: all var(--transition-duration) ease;
}

.remove_address:hover {
    background: rgb(var(--color-danger) / 0.15);
    border-color: rgb(var(--color-danger) / 0.4);
    color: rgb(var(--color-text-strong));
}

/* Статистика матча: сетка полей игрока */
.stat-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 8px;
}

@media (max-width: 768px) {
    .stat-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.stat_input input[type="checkbox"] {
    accent-color: rgb(var(--accent-primary));
}

.team-stat-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
    flex-shrink: 0;
}

/* Сообщение о сохранении */
#saveResultMsg.success-message {
    border-color: rgb(var(--color-success-deep) / 0.3);
    background: rgb(var(--color-success-deep) / 0.08);
    color: rgb(var(--color-success-pale));
}

#saveResultMsg.error-message {
    border-color: rgb(var(--color-danger) / 0.3);
    background: rgb(var(--color-danger) / 0.08);
    color: rgb(var(--color-danger-pale));
}

/* Выпадающий список с поиском (судья/секретарь) */
.searchable-select {
    position: relative;
}

.searchable-select-btn {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 9px 12px;
    border-radius: 8px;
    background: rgb(var(--color-overlay-white) / 0.05);
    border: 1px solid rgb(var(--color-overlay-white) / 0.1);
    color: rgb(var(--color-text));
    font-size: 0.8rem;
    text-align: left;
    cursor: pointer;
    transition: all var(--transition-duration) ease;
}

.searchable-select-btn:hover,
.searchable-select-btn:focus {
    border-color: rgb(var(--accent-primary));
    outline: none;
}

.searchable-select-btn .material-icons-outlined {
    color: rgb(var(--color-text-muted));
    font-size: 1rem;
    flex-shrink: 0;
}

.searchable-select-dropdown {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    right: 0;
    z-index: 50;
    background: rgb(var(--color-card));
    border: 1px solid rgb(var(--color-overlay-white) / 0.1);
    border-radius: 10px;
    box-shadow: 0 20px 40px rgb(var(--color-overlay-black) / 0.4);
    padding: 6px;
}

.searchable-select-search {
    width: 100%;
    padding: 8px 10px;
    margin-bottom: 6px;
    border-radius: 6px;
    background: rgb(var(--color-overlay-white) / 0.05);
    border: 1px solid rgb(var(--color-overlay-white) / 0.1);
    color: rgb(var(--color-text));
    font-size: 0.75rem;
    outline: none;
}

.searchable-select-search:focus {
    border-color: rgb(var(--accent-primary));
}

.searchable-select-search::placeholder {
    color: rgb(var(--color-text-faint));
}

.searchable-select-list {
    max-height: 240px;
    overflow-y: auto;
}

.searchable-select-option {
    display: block;
    width: 100%;
    text-align: left;
    padding: 8px 10px;
    border-radius: 6px;
    background: transparent;
    border: none;
    color: rgb(var(--color-text-secondary));
    font-size: 0.75rem;
    cursor: pointer;
    transition: background 0.3s ease;
}

.searchable-select-option:hover {
    background: rgb(var(--accent-primary) / 0.12);
    color: rgb(var(--color-text-strong));
}

.searchable-select-option.selected {
    background: rgb(var(--accent-primary) / 0.18);
    color: rgb(var(--accent-primary-light));
    font-weight: 600;
}

/* Страница матча: крупный счёт */
.match-score .game-result__score-result {
    font-size: 1.5rem;
    font-weight: 800;
    line-height: 1;
}

.match-score .game-result__score-result--winner {
    color: rgb(var(--color-success));
}

.match-score .game-result__score-result--loser {
    color: rgb(var(--color-danger-light));
}

.match-score .game-result__score-dash {
    color: rgb(var(--color-text-faint));
    font-size: 1.25rem;
    font-weight: 700;
    margin: 0 4px;
}

@media (min-width: 768px) {
    .match-score .game-result__score-result {
        font-size: 2.5rem;
    }

    .match-score .game-result__score-dash {
        font-size: 2rem;
        margin: 0 6px;
    }
}

/* Лучшие игроки матча: номер места */
.best-player-rank {
    position: absolute;
    top: -6px;
    left: -6px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: rgb(var(--accent-primary));
    color: rgb(var(--color-text-strong));
    font-size: 0.65rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 6px rgb(var(--color-overlay-black) / 0.3);
}

/* Компактная статистика игрока */
.player-stats {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 0.7rem;
    font-weight: 600;
    color: rgb(var(--color-text-muted));
    white-space: nowrap;
}

.ps-sep {
    color: rgb(var(--color-text-fainter));
    font-weight: 400;
}

.ps-total {
    color: rgb(var(--accent-primary-light));
    font-size: 0.8rem;
    font-weight: 700;
}

.roster-table tbody td {
    padding: 5px 10px;
    border-bottom: 1px solid rgb(var(--color-overlay-white) / 0.04);
}

.roster-table tbody tr:last-child td {
    border-bottom: none;
}

/* Лучшие по амплуа */
.role-badge {
    position: absolute;
    top: -6px;
    left: -6px;
    min-width: 20px;
    height: 20px;
    padding: 0 5px;
    border-radius: 999px;
    background: rgb(var(--accent-primary));
    color: rgb(var(--color-text-strong));
    font-size: 0.6rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 6px rgb(var(--color-overlay-black) / 0.3);
}

.mvp-card {
    border-color: rgb(var(--color-warning) / 0.35) !important;
    background: rgb(var(--color-warning) / 0.06) !important;
}

.mvp-card .role-badge {
    background: rgb(var(--color-warning));
}

/* Карточка MVP на всю ширину */
.mvp-trophy {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 18px rgb(var(--color-overlay-black) / 0.3);
}

.mvp-trophy .material-icons-outlined {
    font-size: 2.2rem;
}

.mvp-fullwidth {
    border-color: rgb(var(--color-warning) / 0.4) !important;
    background: rgb(var(--color-warning) / 0.06) !important;
}

/* Спонсор матча (заглушка) */
.match-sponsor-placeholder {
    min-height: 240px;
    border: 2px dashed rgb(var(--color-overlay-white) / 0.12);
    background: rgb(var(--color-overlay-white) / 0.03);
}

/* Кнопка «Смотреть» (трансляция матча) */
.stream-watch-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    border-radius: 10px;
    background: linear-gradient(135deg, rgb(var(--color-danger)) 0%, rgb(var(--color-danger-strong)) 100%);
    color: rgb(var(--color-text-strong));
    font-size: 0.85rem;
    font-weight: 700;
    text-decoration: none;
    box-shadow: 0 4px 14px rgb(var(--color-danger-strong) / 0.35);
    transition: all var(--transition-duration) ease;
}

.stream-watch-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgb(var(--color-danger-strong) / 0.45);
    color: rgb(var(--color-text-strong));
}

.stream-watch-btn .material-icons-outlined {
    font-size: 1.2rem;
}

.stream-live-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgb(var(--color-text-strong));
    animation: stream-live-pulse 1.2s ease-in-out infinite;
}

@keyframes stream-live-pulse {
    0%,
    100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.5;
        transform: scale(0.75);
    }
}

/* Карточка трансляции на главной (структура из .other, тёмная тема) */
.stream-card {
    padding: 16px;
    position: relative;
}

.stream-thumb {
    border-radius: 12px;
    height: 140px;
    background: linear-gradient(135deg, #0b1220 0%, #1c2c4d 100%);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 12px;
    overflow: hidden;
    transition: all var(--transition-duration) ease;
}

a.block:hover .stream-thumb {
    background: linear-gradient(135deg, #111c33 0%, #223c66 100%);
}

.stream-thumb .material-icons-outlined {
    font-size: 46px;
    color: rgb(var(--color-overlay-white) / 0.85);
}

.badge-live {
    position: absolute;
    top: 10px;
    left: 10px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: rgb(var(--color-danger) / 0.15);
    color: rgb(var(--color-danger-light));
    font-size: 11px;
    font-weight: 800;
    padding: 3px 9px;
    border-radius: 999px;
    z-index: 1;
}

.badge-live .dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgb(var(--color-danger));
    animation: stream-live-pulse 1.4s infinite;
}

.badge-live.badge-soon {
    background: rgb(var(--accent-primary) / 0.15);
    color: rgb(var(--accent-primary-light));
}

.badge-live .dot.dot-soon {
    background: rgb(var(--accent-primary));
    animation: none;
}

.stream-thumb .viewers {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background: rgb(var(--color-overlay-black) / 0.5);
    color: rgb(var(--color-text-strong));
    font-size: 11px;
    padding: 3px 8px;
    border-radius: 999px;
    display: flex;
    gap: 4px;
    align-items: center;
}

.stream-person {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid rgb(var(--color-overlay-white) / 0.08);
}

.avatar-round {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgb(var(--accent-primary) / 0.15);
    color: rgb(var(--accent-primary-light));
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 12px;
    flex-shrink: 0;
}

/* Название команды в карточке матча: перенос до 2 строк */
.match-team-name {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.25;
    word-break: break-word;
    min-width: 0;
}

/* Буква-аватар команды в карточке трансляции */
.stream-team-letter {
    width: 26px;
    height: 26px;
    border-radius: 8px;
    background: rgb(var(--accent-primary) / 0.15);
    color: rgb(var(--accent-primary-light));
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    flex-shrink: 0;
}

/* Список команд в модальном окне (игрок / фанат) */
.team-list-item {
    transition: all var(--transition-duration) ease;
}

.team-list-item:hover {
    border-color: rgb(var(--accent-primary) / 0.4) !important;
    background: rgb(var(--accent-primary) / 0.06) !important;
}

/* Чекбоксы на страницах редактирования */
.admin-checkbox {
    width: 16px;
    height: 16px;
    accent-color: rgb(var(--accent-primary));
    flex-shrink: 0;
}

/* Карточка обзора матча на главной */
.home-review-card {
    transition: all var(--transition-duration) ease;
}

.home-review-card:hover {
    border-color: rgb(var(--accent-primary) / 0.4) !important;
    background: rgb(var(--accent-primary) / 0.04) !important;
}

/* Шапка команды */
.team-header-logo {
    width: 80px;
    height: 80px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    overflow: hidden;
    font-weight: 800;
    font-size: 1.5rem;
    color: rgb(var(--color-text-strong));
}

.team-header-logo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.team-stats-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
    margin-top: 1.25rem;
}

@media (min-width: 768px) {
    .team-stats-row {
        grid-template-columns: repeat(6, 1fr);
    }
}

.team-stat {
    background: rgb(var(--color-overlay-white) / 0.04);
    border: 1px solid rgb(var(--color-overlay-white) / 0.07);
    border-radius: 12px;
    padding: 0.75rem 0.5rem;
    text-align: center;
}

.team-stat-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: rgb(var(--color-text-strong));
    line-height: 1.2;
}

.team-stat-label {
    font-size: 0.7rem;
    color: rgb(var(--color-text-muted));
    margin-top: 2px;
}

/* Выпадающее меню настроек команды */
.team-dropdown {
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    width: 240px;
    background: rgb(var(--color-card));
    border: 1px solid rgb(var(--color-overlay-white) / 0.1);
    border-radius: 12px;
    padding: 6px;
    box-shadow: 0 20px 40px rgb(var(--color-overlay-black) / 0.4);
    z-index: 40;
}

.team-dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    text-align: left;
    padding: 9px 12px;
    font-size: 0.8rem;
    color: rgb(var(--color-text));
    border-radius: 8px;
    text-decoration: none;
    transition: background 0.3s ease;
}

.team-dropdown-item:hover {
    background: rgb(var(--color-overlay-white) / 0.06);
}

.team-dropdown-item.danger {
    color: rgb(var(--color-danger-light));
}

.team-dropdown-item.danger:hover {
    background: rgb(var(--color-danger) / 0.1);
}

/* Таблицы (таблица лиги, статистика игроков, календарь) */
.team-table {
    width: 100%;
    font-size: 0.8rem;
    border-collapse: collapse;
}

.team-table thead th {
    text-align: left;
    padding: 8px 10px;
    color: rgb(var(--color-text-muted));
    font-weight: 500;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    border-bottom: 1px solid rgb(var(--color-overlay-white) / 0.08);
}

.team-table tbody td {
    padding: 8px 10px;
    color: rgb(var(--color-text-secondary));
    border-bottom: 1px solid rgb(var(--color-overlay-white) / 0.05);
}

.team-table tbody tr:last-child td {
    border-bottom: none;
}

.team-table tbody tr:hover {
    background: rgb(var(--color-overlay-white) / 0.03);
}

.team-table td.tac,
.team-table th.tac {
    text-align: center;
}

.team-table tbody tr td[colspan] {
    background: rgb(var(--color-overlay-white) / 0.03);
    color: rgb(var(--color-text-muted));
    font-weight: 600;
    text-align: center;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.team-table tr.b {
    background: rgb(var(--accent-primary) / 0.08);
}

.team-table tr.b td {
    color: rgb(var(--accent-primary-light));
    font-weight: 600;
}

.team-table a {
    color: rgb(var(--color-text-secondary));
    text-decoration: none;
    transition: color 0.2s ease;
}

.team-table a:hover {
    color: rgb(var(--accent-primary));
}

/* Последний матч — счёт (обёртка из last_match.php) */
.team-last-match .game-result__score-result {
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1;
}

.team-last-match .game-result__score-result--winner {
    color: rgb(var(--color-success));
}

.team-last-match .game-result__score-result--loser {
    color: rgb(var(--color-danger-light));
}

.team-last-match .game-result__score-dash {
    color: rgb(var(--color-text-faint));
    margin: 0 2px;
    font-weight: 600;
}

/* Информация о команде */
.team-info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid rgb(var(--color-overlay-white) / 0.06);
    font-size: 0.85rem;
    gap: 12px;
}

.team-info-row:last-child {
    border-bottom: none;
}

.team-info-label {
    color: rgb(var(--color-text-muted));
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.team-info-label .material-icons-outlined {
    font-size: 1rem;
}

.team-info-value {
    color: rgb(var(--color-text));
    font-weight: 500;
    text-align: right;
    word-break: break-word;
}

.team-info-value a {
    color: rgb(var(--accent-primary));
    text-decoration: none;
}

.team-info-value a:hover {
    color: rgb(var(--accent-primary-light));
}

/* Руководство команды */
.team-staff-row {
    display: flex;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid rgb(var(--color-overlay-white) / 0.06);
}

.team-staff-row:last-child {
    border-bottom: none;
}

.team-staff-badge {
    display: inline-block;
    font-size: 0.65rem;
    padding: 2px 10px;
    border-radius: 999px;
    margin-top: 4px;
}

/* Контактные карточки (капитан / менеджер) */
.team-contact-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: rgb(var(--color-overlay-white) / 0.04);
    border: 1px solid rgb(var(--color-overlay-white) / 0.07);
    border-radius: 12px;
    margin-top: 10px;
}

.team-contact-card img {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    object-fit: cover;
    flex-shrink: 0;
}

.team-contact-card a {
    color: rgb(var(--accent-primary));
    text-decoration: none;
}

.team-contact-card a:hover {
    color: rgb(var(--accent-primary-light));
}

.team-contact-meta {
    font-size: 0.75rem;
    color: rgb(var(--color-text-muted));
    margin-top: 2px;
    line-height: 1.5;
}

.team-contact-meta li {
    list-style: none;
}

/* Плашки активных турниров */
.active-tourney-tile {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 18px 12px;
    border-radius: 14px;
    background: rgb(var(--color-card) / 0.7);
    border: 1px solid rgb(var(--color-overlay-white) / 0.08);
    color: rgb(var(--color-text-secondary));
    text-decoration: none;
    transition: all var(--transition-duration) ease;
    gap: 8px;
    min-height: 110px;
}

.active-tourney-tile:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgb(var(--color-overlay-black) / 0.3);
    border-color: rgb(var(--accent-primary));
    color: rgb(var(--color-text-secondary));
}

.active-tourney-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: rgb(var(--accent-primary) / 0.15);
    color: rgb(var(--accent-primary-light));
    display: flex;
    align-items: center;
    justify-content: center;
}

.active-tourney-title {
    font-weight: 600;
    font-size: 0.85rem;
    line-height: 1.25;
}

.active-tourney-meta {
    font-size: 0.7rem;
    color: rgb(var(--color-text-muted));
}

/* Кнопка «Турниры» / «Регистрация» и модальное окно активных турниров */
.active-tourneys-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 10px 14px;
    border-radius: 8px;
    background: transparent;
    color: rgb(var(--color-text-muted));
    font-size: 0.9rem;
    font-weight: 400;
    border: none;
    cursor: pointer;
    transition: all var(--transition-duration);
    text-align: left;
}

.active-tourneys-btn:hover {
    background: rgb(var(--accent-primary) / 0.1);
    color: rgb(var(--accent-primary));
}

.active-tourneys-btn .material-icons-outlined {
    font-size: 1.1rem;
    flex-shrink: 0;
    margin-right: 12px;
}

.active-tourneys-label {
    flex: 1;
    text-align: left;
}

.active-tourneys-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 999px;
    background: rgb(var(--color-overlay-white) / 0.06);
    color: rgb(var(--color-text-faint));
    font-size: 0.7rem;
    font-weight: 500;
    flex-shrink: 0;
}

.tourney-modal-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border-radius: 12px;
    background: rgb(var(--color-card) / 0.7);
    border: 1px solid rgb(var(--color-overlay-white) / 0.08);
    color: rgb(var(--color-text-secondary));
    flex-wrap: wrap;
    text-decoration: none;
    transition: all var(--transition-duration) ease;
}

.tourney-modal-item:hover {
    border-color: rgb(var(--accent-primary));
    background: rgb(var(--accent-primary) / 0.08);
}

/* Компактные ссылки меню турнира под каждым турниром */
.tourney-modal-links {
    width: 100%;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.tourney-modal-link {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 600;
    color: rgb(var(--color-text-secondary));
    background: rgb(var(--accent-primary) / 0.10);
    border: 1px solid rgb(var(--accent-primary) / 0.2);
    text-decoration: none;
    transition: all 0.2s ease;
}

.tourney-modal-link:hover {
    color: rgb(var(--color-text-strong));
    background: rgb(var(--accent-primary));
    border-color: rgb(var(--accent-primary));
}

/* Кнопка «Регистрация» в модальном окне турниров */
.tourney-reg-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 12px;
    border-radius: 8px;
    background: linear-gradient(135deg, rgb(var(--accent-primary)) 0%, rgb(var(--accent-primary-deep)) 100%);
    color: rgb(var(--color-text-strong));
    font-size: 0.72rem;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    flex-shrink: 0;
    transition: all var(--transition-duration) ease;
}

.tourney-reg-btn:hover {
    background: linear-gradient(135deg, rgb(var(--accent-primary-dark)) 0%, rgb(var(--accent-primary-deep)) 100%);
    color: rgb(var(--color-text-strong));
}

/* Переключатель лиг */
.league-toggle {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 6px;
    flex: 1;
    min-width: 0;
}

.league-toggle-btn {
    width: 100%;
    padding: 6px 10px;
    border-radius: 8px;
    background: transparent;
    border: 1px solid rgb(var(--color-overlay-white) / 0.15);
    color: rgb(var(--color-text-muted));
    font-size: 0.75rem;
    text-align: left;
    cursor: pointer;
    transition: all var(--transition-duration) ease;
    white-space: normal;
    line-height: 1.3;
}

.league-toggle-btn:hover {
    border-color: rgb(var(--accent-primary));
    color: rgb(var(--color-text-strong));
}

.league-toggle-btn.active {
    background: rgb(var(--accent-primary) / 0.15);
    border-color: rgb(var(--accent-primary));
    color: rgb(var(--color-text-strong));
}

/* Шаги регистрации */
.reg-steps {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.reg-step {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 16px;
    border-radius: 999px;
    background: rgb(var(--color-overlay-white) / 0.04);
    border: 1px solid rgb(var(--color-overlay-white) / 0.08);
    color: rgb(var(--color-text-muted));
    font-size: 0.75rem;
    font-weight: 600;
    text-decoration: none;
    transition: all var(--transition-duration) ease;
}

.reg-step.active {
    background: rgb(var(--accent-primary) / 0.15);
    border-color: rgb(var(--accent-primary));
    color: rgb(var(--color-text-strong));
}

.reg-step.done {
    background: rgb(var(--color-success-deep) / 0.1);
    border-color: rgb(var(--color-success-deep) / 0.3);
    color: rgb(var(--color-success));
}

.reg-step.done:hover {
    border-color: rgb(var(--color-success));
}

/* Карточка выбора лиги */
.reg-league-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px;
    border-radius: 12px;
    background: rgb(var(--color-card) / 0.7);
    border: 1px solid rgb(var(--color-overlay-white) / 0.08);
    color: rgb(var(--color-text-secondary));
    text-decoration: none;
    transition: all var(--transition-duration) ease;
}

.reg-league-card:hover {
    border-color: rgb(var(--accent-primary));
    background: rgb(var(--accent-primary) / 0.08);
}

/* Единое уведомление об отсутствии данных */
.empty-notice {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 32px 20px;
    border-radius: 14px;
    background: var(--card);
    border: 1px solid var(--line);
    color: var(--muted);
    font-size: 0.9rem;
    text-align: center;
}

.empty-notice .material-icons-outlined {
    font-size: 2rem;
    color: var(--blue);
    opacity: 0.7;
}

/* Вы уже с ними играли */
.played-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.played-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 6px 10px;
    border-radius: 8px;
    background: rgb(var(--color-overlay-white) / 0.03);
    border: 1px solid rgb(var(--color-overlay-white) / 0.06);
}

.played-name {
    font-size: 0.8rem;
    color: rgb(var(--color-text-secondary));
    font-weight: 500;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Вы уже с ними играли — collapse по чемпионатам */
.played-group {
    border: 1px solid rgb(var(--color-overlay-white) / 0.08);
    border-radius: 10px;
    overflow: hidden;
}

.played-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 9px 12px;
    background: rgb(var(--color-overlay-white) / 0.04);
    border: none;
    color: rgb(var(--color-text-secondary));
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: background var(--transition-duration) ease;
}

.played-toggle:hover {
    background: rgb(var(--accent-primary) / 0.1);
}

.played-toggle .expand-icon {
    transition: transform var(--transition-duration) ease;
    color: rgb(var(--color-text-muted));
}

.played-group.open .expand-icon {
    transform: rotate(180deg);
}

.played-collapse {
    display: none;
    padding: 6px 8px;
}

.played-group.open .played-collapse {
    display: block;
}

/* Hero «Создай историю своей команды» на странице турнира */
.tourney-hero {
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
    padding: 24px 28px;
    border-radius: 18px;
    background: linear-gradient(120deg, var(--blue-soft) 0%, var(--navy) 60%);
    border: 1px solid var(--line);
}

.tourney-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    opacity: 0.08;
    background-image: repeating-linear-gradient(90deg, rgb(var(--color-text-strong)) 0 2px, transparent 2px 90px);
    pointer-events: none;
}

.tourney-hero::after {
    content: "";
    position: absolute;
    right: -70px;
    top: -70px;
    width: 260px;
    height: 260px;
    border-radius: 50%;
    border: 2px dashed rgb(var(--color-overlay-white) / 0.18);
    animation: hero-orbit 22s linear infinite;
    pointer-events: none;
}

@keyframes hero-orbit {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.tourney-hero > * {
    position: relative;
    z-index: 1;
}

.tourney-hero-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 26px;
    border-radius: 12px;
    background: linear-gradient(135deg, rgb(var(--accent-primary)) 0%, rgb(var(--accent-primary-deep)) 100%);
    color: rgb(var(--color-text-strong));
    font-weight: 700;
    font-size: 0.9rem;
    text-decoration: none;
    flex-shrink: 0;
    box-shadow: 0 8px 24px rgb(var(--accent-primary-deep) / 0.4);
    transition: all var(--transition-duration) ease;
    animation: hero-btn-pulse 2.4s ease-in-out infinite;
}

.tourney-hero-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgb(var(--accent-primary-deep) / 0.55);
    color: rgb(var(--color-text-strong));
}

@keyframes hero-btn-pulse {
    0%, 100% { box-shadow: 0 8px 24px rgb(var(--accent-primary-deep) / 0.4); }
    50% { box-shadow: 0 8px 34px rgb(var(--accent-primary) / 0.7); }
}

/* Уведомление «Турнир не начался» (единый стиль на вкладках) */
.tourney-notice {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    padding: 40px 24px;
    border-radius: 18px;
    background: var(--card);
    border: 1px solid var(--line);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.tourney-notice::before {
    content: "";
    position: absolute;
    inset: 0;
    opacity: 0.05;
    background-image: repeating-linear-gradient(90deg, rgb(var(--color-text-strong)) 0 2px, transparent 2px 90px);
    pointer-events: none;
}

.tourney-notice-icon {
    width: 60px;
    height: 60px;
    border-radius: 16px;
    background: var(--blue-soft);
    color: var(--blue);
    display: flex;
    align-items: center;
    justify-content: center;
}

.tourney-notice-icon .material-icons-outlined {
    font-size: 30px;
}

.tourney-notice-text {
    color: var(--muted);
    font-size: 0.95rem;
    max-width: 460px;
    line-height: 1.5;
}

.tourney-notice-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 11px 24px;
    border-radius: 12px;
    background: linear-gradient(135deg, rgb(var(--accent-primary)) 0%, rgb(var(--accent-primary-deep)) 100%);
    color: rgb(var(--color-text-strong));
    font-weight: 700;
    font-size: 0.9rem;
    text-decoration: none;
    box-shadow: 0 8px 24px rgb(var(--accent-primary-deep) / 0.4);
    transition: all var(--transition-duration) ease;
}

.tourney-notice-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgb(var(--accent-primary-deep) / 0.55);
    color: rgb(var(--color-text-strong));
}

/* ===== Toast-уведомления rgdevAlert (контейнер и карточка) ===== */
#rgdevToastContainer {
    position: fixed;
    top: 1.25rem;
    right: 1.25rem;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    width: 100%;
    max-width: 24rem;
    pointer-events: none;
}

/* На ПК тосты показываем ниже шапки (#mainHeader) */
@media (min-width: 769px) {
    #rgdevToastContainer {
        top: calc(var(--header-height) + 0.75rem);
    }
}

#rgdevToastContainer .rgdev-toast {
    pointer-events: auto;
    background-color: rgb(var(--color-card));
    border: 1px solid rgb(var(--color-card-soft));
    border-radius: 0.75rem;
    padding: 1rem;
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    box-shadow: 0 10px 30px rgb(var(--color-overlay-black) / 0.5);
    opacity: 0;
    transform: translateX(0.75rem);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

#rgdevToastContainer .rgdev-toast.show {
    opacity: 1;
    transform: translateX(0);
}

#rgdevToastContainer .rgdev-toast.rgdev-toast-success { border-color: rgb(var(--color-success-deep) / 0.4); }
#rgdevToastContainer .rgdev-toast.rgdev-toast-error { border-color: rgb(var(--color-danger) / 0.4); }
#rgdevToastContainer .rgdev-toast.rgdev-toast-info { border-color: rgb(var(--accent-primary) / 0.4); }
#rgdevToastContainer .rgdev-toast.rgdev-toast-warning { border-color: rgb(var(--color-warning) / 0.4); }

#rgdevToastContainer .rgdev-toast-icon {
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

#rgdevToastContainer .rgdev-toast-success .rgdev-toast-icon { background: rgb(var(--color-success-deep) / 0.15); color: rgb(var(--color-success)); }
#rgdevToastContainer .rgdev-toast-error .rgdev-toast-icon { background: rgb(var(--color-danger) / 0.15); color: rgb(var(--color-danger-light)); }
#rgdevToastContainer .rgdev-toast-info .rgdev-toast-icon { background: rgb(var(--accent-primary) / 0.15); color: rgb(var(--accent-primary-light)); }
#rgdevToastContainer .rgdev-toast-warning .rgdev-toast-icon { background: rgb(var(--color-warning) / 0.15); color: rgb(var(--color-warning-light)); }

#rgdevToastContainer .rgdev-toast-title { font-size: 0.875rem; font-weight: 600; }
#rgdevToastContainer .rgdev-toast-success .rgdev-toast-title { color: rgb(var(--color-success)); }
#rgdevToastContainer .rgdev-toast-error .rgdev-toast-title { color: rgb(var(--color-danger-light)); }
#rgdevToastContainer .rgdev-toast-info .rgdev-toast-title { color: rgb(var(--accent-primary-light)); }
#rgdevToastContainer .rgdev-toast-warning .rgdev-toast-title { color: rgb(var(--color-warning-light)); }

#rgdevToastContainer .rgdev-toast-message { color: rgb(var(--color-text-soft)); font-size: 0.875rem; word-break: break-word; }
#rgdevToastContainer .rgdev-toast-link { display: inline-block; margin-top: 6px; color: rgb(var(--accent-primary-light)); font-size: 0.8125rem; font-weight: 600; text-decoration: none; }
#rgdevToastContainer .rgdev-toast-link:hover { text-decoration: underline; }
#rgdevToastContainer .rgdev-toast-close { color: rgb(var(--color-text-faint)); background: none; border: none; cursor: pointer; flex-shrink: 0; padding: 0; }
#rgdevToastContainer .rgdev-toast-close:hover { color: rgb(var(--color-text-strong)); }

        /* Содержимое полной новости (fullstory.tpl) */
        .post__content {
            font-size: 0.95rem;
            line-height: 1.75;
            color: rgb(var(--color-text-soft));
        }
        .post__content p {
            margin: 0 0 1rem;
        }
        .post__content img {
            max-width: 100%;
            height: auto;
            border-radius: 12px;
            margin: 1rem 0;
        }
        .post__content a {
            color: rgb(var(--accent-primary-light));
            text-decoration: underline;
            text-underline-offset: 3px;
            transition: color 0.2s ease;
        }
        .post__content a:hover {
            color: #93c5fd;
        }
        .post__content h1, .post__content h2, .post__content h3, .post__content h4 {
            color: rgb(var(--color-text));
            font-weight: 700;
            margin: 1.5rem 0 0.75rem;
            line-height: 1.3;
        }
        .post__content blockquote {
            border-left: 3px solid rgb(var(--accent-primary));
            padding: 0.5rem 1rem;
            margin: 1rem 0;
            color: rgb(var(--color-text-muted));
            font-style: italic;
            background: rgb(var(--color-overlay-white) / 0.03);
            border-radius: 0 8px 8px 0;
        }
        .post__content ul, .post__content ol {
            margin: 0 0 1rem 1.25rem;
        }
        .post__content li {
            margin-bottom: 0.35rem;
        }
        .post__content table {
            width: 100%;
            max-width: 100%;
            overflow-x: auto;
            display: block;
            border-collapse: collapse;
            margin: 1rem 0;
        }
        .post__content table th, .post__content table td {
            border: 1px solid rgb(var(--color-overlay-white) / 0.12);
            padding: 0.5rem 0.75rem;
            font-size: 0.85rem;
        }
        .post__content iframe {
            max-width: 100%;
            border-radius: 12px;
            margin: 1rem 0;
        }

        /* Кнопки-фильтры драфта */
        .draft-filter-btn {
            padding: 6px 14px;
            border-radius: 999px;
            font-size: 12px;
            font-weight: 600;
            color: rgb(var(--color-text-muted));
            background: rgb(var(--color-overlay-white) / 0.04);
            border: 1px solid rgb(var(--color-overlay-white) / 0.08);
            cursor: pointer;
            white-space: nowrap;
            transition: color 0.2s ease, background 0.2s ease, border-color 0.2s ease;
        }
        .draft-filter-btn:hover {
            color: rgb(var(--color-text));
            border-color: rgb(var(--accent-primary) / 0.45);
            background: rgb(var(--color-overlay-white) / 0.07);
        }
        .draft-filter-btn.active {
            color: rgb(var(--accent-primary-light));
            background: rgb(var(--accent-primary) / 0.15);
            border-color: rgb(var(--accent-primary) / 0.45);
        }

        /* Блок «Забери своё» (баллы турнира) */
        .tourney-points-card {
            position: relative;
            overflow: hidden;
            border-radius: 16px;
            border: 1px solid rgb(var(--accent-primary) / 0.35);
            background: linear-gradient(135deg, rgb(var(--accent-primary) / 0.14), rgb(var(--accent-purple) / 0.12) 50%, rgb(var(--accent-primary) / 0.14));
            background-size: 300% 300%;
            animation: tourney-points-bg 9s ease infinite;
            box-shadow: 0 0 24px rgb(var(--accent-primary) / 0.12);
        }
        @keyframes tourney-points-bg {
            0%, 100% { background-position: 0% 50%; }
            50% { background-position: 100% 50%; }
        }

        .tourney-points-inner {
            position: relative;
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 1rem;
            flex-wrap: wrap;
            padding: 1.5rem;
        }

        .tourney-points-icon {
            width: 54px;
            height: 54px;
            border-radius: 14px;
            flex-shrink: 0;
            display: flex;
            align-items: center;
            justify-content: center;
            background: linear-gradient(135deg, rgb(var(--color-warning)), rgb(var(--color-warning-light)));
            color: rgb(var(--color-card));
            animation: tourney-points-pulse 2.6s ease-in-out infinite;
        }
        .tourney-points-icon .material-icons-outlined {
            font-size: 28px;
        }
        @keyframes tourney-points-pulse {
            0%, 100% { box-shadow: 0 0 16px rgb(var(--color-warning) / 0.35); transform: scale(1); }
            50% { box-shadow: 0 0 30px rgb(var(--color-warning) / 0.6); transform: scale(1.06); }
        }

        .tourney-points-text {
            flex: 1;
            min-width: 240px;
        }
        .tourney-points-text p {
            color: #cbd5e1;
            font-size: 0.85rem;
            line-height: 1.6;
            margin: 0;
        }

        .tourney-points-btn {
            flex-shrink: 0;
            padding: 12px 22px;
            border-radius: 12px;
            font-weight: 600;
            font-size: 0.85rem;
            color: rgb(var(--color-text-strong));
            background: linear-gradient(135deg, rgb(var(--accent-primary)), rgb(var(--accent-purple)));
            border: none;
            cursor: pointer;
            transition: transform 0.2s ease, box-shadow 0.2s ease;
            box-shadow: 0 4px 18px rgb(var(--accent-primary) / 0.35);
            display: inline-flex;
            align-items: center;
            justify-content: center;
        }
        .tourney-points-btn .material-icons-outlined {
            font-size: 16px;
            margin-right: 6px;
        }
        .tourney-points-btn:hover {
            transform: translateY(-2px);
            box-shadow: 0 6px 24px rgb(var(--accent-primary) / 0.5);
        }

        .tourney-points-shimmer {
            position: absolute;
            top: 0;
            left: -100%;
            width: 55%;
            height: 100%;
            background: linear-gradient(105deg, transparent, rgb(var(--color-overlay-white) / 0.07), transparent);
            transform: skewX(-20deg);
            animation: tourney-points-shimmer 4.5s ease-in-out infinite;
            pointer-events: none;
        }
        @keyframes tourney-points-shimmer {
            0% { left: -100%; }
            55%, 100% { left: 150%; }
        }

        .tourney-points-card::after {
            content: "✦";
            position: absolute;
            top: 14px;
            right: 38%;
            font-size: 16px;
            color: rgb(var(--color-warning) / 0.45);
            animation: tourney-points-float 5s ease-in-out infinite;
            pointer-events: none;
        }
        @keyframes tourney-points-float {
            0%, 100% { transform: translateY(0) rotate(0deg); opacity: 0.35; }
            50% { transform: translateY(-16px) rotate(25deg); opacity: 0.85; }
        }

        .tourney-points-btn:disabled {
            cursor: not-allowed;
            opacity: 0.6;
            transform: none;
            box-shadow: 0 2px 10px rgb(var(--accent-primary) / 0.2);
        }
        .tourney-points-btn:disabled:hover {
            transform: none;
            box-shadow: 0 2px 10px rgb(var(--accent-primary) / 0.2);
        }

        /* ===== Тема Lakers (пурпур rgb(var(--color-purple-lakers)) + золото rgb(var(--accent-gold))) =====
           Тёмная тема на базе основного дизайна. Включается при нажатии «Сменить тему».
           Синие акценты заменяются на оттенки пурпура через переменные
           --accent-primary / --accent-primary-light. */
        .lakers-theme {
            --accent-primary: 85 37 131;
            --accent-primary-light: 124 58 237;
            /* Тёмный градиент сверху (как в базовой теме) + едва заметные пурпурно-золотые свечения */
            background:
                radial-gradient(circle at 15% 8%, rgb(var(--accent-primary) / 0.08) 0, transparent 45%),
                radial-gradient(circle at 85% 90%, rgb(var(--accent-gold) / 0.05) 0, transparent 40%),
                linear-gradient(160deg, rgb(var(--color-bg)) 0%, rgb(var(--color-bg-soft)) 100%);
            background-color: #12101a;
        }

        .lakers-theme .strict-card,
        .lakers-theme .news-card,
        .lakers-theme .stream-card,
        .lakers-theme .partner-card {
            background: rgb(var(--color-lakers-card) / 0.92);
            border-color: rgb(var(--color-overlay-white) / 0.08);
        }

        /* Акцентные цвета: пурпур и золото Lakers */
        .lakers-theme .text-primary-400 { color: #c4b5fd !important; }
        .lakers-theme .text-primary-500 { color: rgb(var(--accent-gold)) !important; }
        .lakers-theme .text-primary-600 { color: #eab308 !important; }
        .lakers-theme .text-yellow-500 { color: rgb(var(--accent-gold)) !important; }
        .lakers-theme .bg-primary-400 { background-color: rgb(var(--accent-primary-light)) !important; }
        .lakers-theme .bg-primary-500 { background-color: rgb(var(--accent-primary)) !important; }
        .lakers-theme .bg-primary-600 { background-color: rgb(var(--color-purple-deep)) !important; }

        /* Кнопки и градиенты */
        .lakers-theme .strict-button {
            background: linear-gradient(135deg, rgb(var(--accent-primary)) 0%, rgb(var(--accent-primary-light)) 100%) !important;
        }
        .lakers-theme .strict-button:hover {
            background: linear-gradient(135deg, rgb(var(--accent-gold)) 0%, rgb(var(--color-warning-dark)) 100%) !important;
            box-shadow: 0 4px 15px rgb(var(--accent-gold) / 0.3) !important;
        }
        .lakers-theme .gradient-blue {
            background: linear-gradient(135deg, rgb(var(--accent-primary)) 0%, rgb(var(--accent-primary-light)) 100%) !important;
        }
        .lakers-theme .from-blue-500 { --tw-gradient-from: rgb(var(--accent-primary)) var(--tw-gradient-from-position) !important; }
        .lakers-theme .to-blue-700 { --tw-gradient-to: rgb(var(--color-purple-deep)) var(--tw-gradient-to-position) !important; }

        /* Скроллбар */
        .lakers-theme ::-webkit-scrollbar-thumb {
            background: linear-gradient(180deg, rgb(var(--accent-primary)), rgb(var(--accent-gold))) !important;
        }

        /* Разделители и фоновая сетка */
        .lakers-theme .strict-divider {
            background: linear-gradient(90deg, transparent, rgb(var(--accent-gold) / 0.25), transparent);
        }
        .lakers-theme .grid-lines {
            background-image:
                radial-gradient(circle at 18% 12%, rgb(var(--accent-primary) / 0.08) 0, transparent 38%),
                radial-gradient(circle at 82% 78%, rgb(var(--accent-gold) / 0.05) 0, transparent 38%),
                linear-gradient(rgb(var(--accent-purple) / 0.05) 1px, transparent 1px),
                linear-gradient(90deg, rgb(var(--accent-purple) / 0.05) 1px, transparent 1px);
            background-size: auto, auto, 40px 40px, 40px 40px;
        }

        /* Меню */
        .lakers-theme .menu-item:hover { background: rgb(var(--accent-gold) / 0.12); color: rgb(var(--accent-gold)); }
        .lakers-theme .menu-item.active { background: rgb(var(--accent-gold) / 0.18); color: rgb(var(--accent-gold)); }

        /* Турнирные вкладки и кнопки кругов */
        .lakers-theme .tourney-tab.content-filter__item--active {
            background: rgb(var(--accent-primary));
        }
        .lakers-theme .tourney-lap-btn.active {
            background: rgb(var(--accent-primary));
            border-color: rgb(var(--accent-primary));
            color: rgb(var(--color-text-strong));
        }

        /* Турнирная таблица */
        .lakers-theme .tourney-table a:hover { color: rgb(var(--accent-gold)); }
        .lakers-theme .tourney-table tbody tr:hover { background: rgb(var(--accent-primary) / 0.30); }
        .lakers-theme .tourney-table thead th { color: #e9d5ff; }

        /* Поиск и партнёры */
        .lakers-theme .search-form:focus-within { border-color: rgb(var(--accent-gold)); }
        .lakers-theme .search-result-item:hover { background: rgb(var(--accent-primary) / 0.30); }
        .lakers-theme .partner-all-link:hover,
        .lakers-theme .partner-arrow:hover { background: rgb(var(--accent-gold) / 0.12); color: rgb(var(--accent-gold)); }
        .lakers-theme .partner-dot.active { background: rgb(var(--accent-primary)); }

        /* Блок «Возможно вы искали» в поиске (при фокусе на поле) */
        .search-suggest-title {
            padding: 10px 16px 2px;
            font-size: 11px;
            font-weight: 600;
            color: rgb(var(--color-text-muted));
            text-transform: uppercase;
            letter-spacing: 0.05em;
        }
        .search-suggest-subtitle {
            padding: 0 16px 8px;
            font-size: 12px;
            font-weight: 600;
            color: rgb(var(--accent-primary-light));
        }
        .lakers-theme .search-suggest-subtitle {
            color: rgb(var(--accent-gold));
        }
        .search-suggest-avatar {
            background: linear-gradient(135deg, rgb(var(--accent-purple)) 0%, rgb(var(--accent-purple-dark)) 100%) !important;
            font-size: 18px;
        }
        .lakers-theme .search-suggest-avatar {
            background: linear-gradient(135deg, rgb(var(--accent-primary)) 0%, rgb(var(--accent-primary-light)) 100%) !important;
        }

        /* Синие элементы → оттенки пурпура Lakers */
        .lakers-theme .league-menu-btn {
            color: rgb(var(--accent-primary-light));
            background: rgb(var(--accent-primary) / 0.12);
            border-color: rgb(var(--accent-primary) / 0.25);
        }
        .lakers-theme .league-menu-btn:hover {
            background: rgb(var(--accent-primary) / 0.18);
        }
        .lakers-theme .accent-text {
            background: linear-gradient(90deg, rgb(var(--accent-primary)), rgb(var(--accent-gold)));
            background-clip: text;
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
        }
        .lakers-theme .partner-tag-line {
            color: rgb(var(--accent-primary-light));
        }
        .lakers-theme .partner-contact a {
            color: rgb(var(--accent-primary-light));
        }
        .lakers-theme .partner-contact a:hover {
            color: rgb(var(--accent-primary-light));
        }
        .lakers-theme .speedbar a:hover {
            color: rgb(var(--accent-primary));
        }
        .lakers-theme .text-blue-400,
        .lakers-theme .text-blue-500 { color: rgb(var(--accent-primary-light)) !important; }
        .lakers-theme .border-blue-500 { border-color: rgb(var(--accent-primary)) !important; }
        .lakers-theme .bg-blue-500\/20 { background-color: rgb(var(--accent-primary) / 0.2) !important; }
        .lakers-theme .from-blue-600\/15 { --tw-gradient-from: rgb(var(--accent-primary) / 0.15) var(--tw-gradient-from-position) !important; }
        .lakers-theme .home-review-bg {
            background:
                radial-gradient(circle at 20% 20%, rgb(var(--accent-primary) / 0.35) 0, transparent 45%),
                radial-gradient(circle at 80% 80%, rgb(var(--accent-purple) / 0.3) 0, transparent 45%),
                linear-gradient(135deg, #2a1040 0%, rgb(var(--accent-primary)) 45%, rgb(var(--accent-primary-light)) 100%);
        }
        .lakers-theme .team-table a:hover { color: rgb(var(--accent-primary)); }
        .lakers-theme .team-table tr.b { background: rgb(var(--accent-primary) / 0.08); }
        .lakers-theme .team-table tr.b td { color: rgb(var(--accent-primary-light)); }
        .lakers-theme .best-player-rank { background: rgb(var(--accent-primary)); }
        .lakers-theme .profile-tab.active,
        .lakers-theme .compact-tab.active,
        .lakers-theme .strict-tab.active {
            background: rgb(var(--accent-primary));
            color: rgb(var(--color-text-strong));
        }
        .lakers-theme .active-tourneys-btn:hover {
            background: rgb(var(--accent-primary) / 0.10);
            color: rgb(var(--accent-primary));
        }
        .lakers-theme .ps-total {
            color: rgb(var(--accent-primary-light));
        }
        .lakers-theme .home-review-card:hover {
            border-color: rgb(var(--accent-primary) / 0.40) !important;
            background: rgb(var(--accent-primary) / 0.04) !important;
        }
        .lakers-theme .partner-tag {
            color: rgb(var(--accent-primary-light));
            background: rgb(var(--accent-primary) / 0.12);
            border-color: rgb(var(--accent-primary) / 0.25);
        }
        .lakers-theme .partner-logo-placeholder {
            background: linear-gradient(135deg, rgb(var(--accent-primary)), rgb(var(--accent-primary-light)));
        }
        .lakers-theme .active-tourney-icon {
            background: rgb(var(--accent-primary) / 0.15);
            color: rgb(var(--accent-primary-light));
        }

        /* Цветная кнопка «Перейти в бота» */
        .max-bot-link {
            display: inline-block;
            padding: 2px 10px;
            border-radius: 8px;
            background: linear-gradient(135deg, rgb(var(--accent-primary)), rgb(var(--accent-purple)));
            color: rgb(var(--color-text-strong)) !important;
            font-weight: 600;
            text-decoration: none;
            transition: opacity 0.2s ease;
            vertical-align: middle;
        }
        .max-bot-link:hover {
            opacity: 0.85;
        }
        .lakers-theme .max-bot-link {
            background: linear-gradient(135deg, rgb(var(--accent-primary)), rgb(var(--accent-gold)));
        }

        /* Бейдж счётчика новых ответов в меню */
        .menu-badge {
            margin-left: auto;
            min-width: 20px;
            height: 20px;
            padding: 0 6px;
            border-radius: 9999px;
            background: linear-gradient(135deg, rgb(var(--color-warning)), rgb(var(--color-danger)));
            color: rgb(var(--color-text-strong));
            font-size: 11px;
            font-weight: 700;
            align-items: center;
            justify-content: center;
            flex-shrink: 0;
            box-shadow: 0 0 8px rgb(var(--color-danger) / 0.5);
        }
        .sidebar.collapsed .menu-badge {
            display: none !important;
        }

        /* Колокольчик уведомлений в шапке */
        #notifyBell {
            position: relative;
        }
        #notifyBell .material-icons-outlined,
        .admin-head-icon {
            font-size: 1.725rem !important;
        }
        #notifyBell .menu-badge {
            position: absolute;
            top: -5px;
            right: -6px;
            margin-left: 0;
            min-width: 17px;
            height: 17px;
            padding: 0 4px;
            font-size: 10px;
        }

        /* Страница «Команда РГ»: табы по турнирам */
        .teamrg-avatar-7 {
            width: 7rem;
            height: 7rem;
        }

        /* Блок «Организаторы» — особый фон */
        #teamrg-organizers {
            background:
                radial-gradient(circle at 15% 10%, rgb(var(--accent-primary) / 0.22) 0, transparent 45%),
                radial-gradient(circle at 85% 90%, rgb(var(--accent-gold) / 0.12) 0, transparent 40%),
                rgb(var(--color-card) / 0.6);
            border: 1px solid rgb(var(--accent-primary) / 0.25);
        }
        .lakers-theme #teamrg-organizers {
            background:
                radial-gradient(circle at 15% 10%, rgb(var(--accent-primary) / 0.35) 0, transparent 45%),
                radial-gradient(circle at 85% 90%, rgb(var(--accent-gold) / 0.18) 0, transparent 40%),
                rgb(var(--color-card) / 0.6);
        }

        /* Рамка с телефоном организатора (пользователь 1) */
        .teamrg-organizer-contact {
            margin-top: 12px;
            width: 100%;
            padding: 10px 12px;
            border-radius: 12px;
            border: 1px solid rgb(var(--accent-primary) / 0.35);
            background: rgb(var(--accent-primary) / 0.10);
            text-align: center;
        }
        .teamrg-organizer-contact a {
            display: block;
        }
        .teamrg-tab {
            padding: 6px 12px;
            border-radius: 8px;
            font-size: 12px;
            font-weight: 600;
            color: rgb(var(--color-text-muted));
            background: rgb(var(--color-overlay-white) / 0.04);
            border: 1px solid rgb(var(--color-overlay-white) / 0.1);
            cursor: pointer;
            transition: all 0.2s ease;
        }
        .teamrg-tab:hover {
            color: rgb(var(--color-text-strong));
            background: rgb(var(--accent-primary) / 0.12);
        }
        .teamrg-tab.active {
            color: rgb(var(--color-text-strong));
            background: rgb(var(--accent-primary-dark));
            border-color: rgb(var(--accent-primary-dark));
        }
        .lakers-theme .teamrg-tab:hover {
            background: rgb(var(--accent-gold) / 0.15);
        }
        .lakers-theme .teamrg-tab.active {
            background: rgb(var(--accent-primary));
            border-color: rgb(var(--accent-primary));
        }
        .teamrg-panel {
            display: none;
        }
        .teamrg-panel.active {
            display: block;
        }
        .teamrg-table-wrap {
            overflow-x: auto;
            border: 1px solid rgb(var(--color-card-soft));
            border-radius: 12px;
        }
        .teamrg-table {
            width: 100%;
            border-collapse: collapse;
        }
        .teamrg-table thead th {
            padding: 10px 12px;
            text-align: left;
            font-size: 12px;
            font-weight: 600;
            color: rgb(var(--color-text-muted));
            border-bottom: 1px solid rgb(var(--color-card-soft));
            background: rgb(var(--color-overlay-white) / 0.02);
        }
        .teamrg-table tbody td {
            padding: 10px 12px;
            font-size: 13px;
            color: rgb(var(--color-text-soft));
            border-bottom: 1px solid rgb(var(--color-overlay-white) / 0.05);
        }
        .teamrg-table tbody tr:last-child td {
            border-bottom: none;
        }
        .teamrg-table tbody tr:nth-child(odd) {
            background: rgb(var(--color-overlay-white) / 0.02);
        }
        .teamrg-table tbody tr:hover {
            background: rgb(var(--accent-primary) / 0.06);
        }
        .lakers-theme .teamrg-table tbody tr:hover {
            background: rgb(var(--accent-primary) / 0.25);
        }
        .teamrg-empty {
            color: rgb(var(--color-text-muted));
            font-size: 13px;
            padding: 16px;
            text-align: center;
        }

        /* ПК: увеличенный хедер */
        @media (min-width: 769px) {
            :root {
                --header-height: 85px;
            }
            .compact-header {
                padding-top: 1rem;
                padding-bottom: 1rem;
            }
            .logo-img {
                height: 3.75rem;
            }
        }

        /* Недостающие Tailwind-утилиты */
        .w-9 { width: 2.25rem; }
        .h-9 { height: 2.25rem; }

        /* Мобильная версия: модалка турниров на всю высоту, отступы в меню */
        @media (max-width: 768px) {
            #tourneysModal .modal-content {
                height: 100%;
                max-height: 100vh;
                border-radius: 0;
                margin: 0;
            }
            #tourneysModal .modal-content > .flex-1 {
                padding: 1.25rem 1rem;
            }
            #tourneysModal .tourney-modal-item {
                padding: 14px;
            }
            /* Выпадающая панель лиги в пределах экрана */
            .league-menu-panel {
                max-height: 55vh;
                position: absolute;
                top: 100%;
                left: 0;
                right: 0;
                z-index: 70;
            }
            .mobile-league-switch select {
                max-width: 100%;
            }
        }

        /* Модальное окно выбора лиги (мобильная версия) */
        #matches, #standings {
            scroll-margin-top: calc(var(--header-height) + 70px);
        }
        .league-mobile-item {
            display: block;
            width: 100%;
            padding: 10px 14px;
            border-radius: 10px;
            font-size: 13px;
            font-weight: 600;
            color: rgb(var(--color-text-secondary));
            background: rgb(var(--color-card) / 0.5);
            border: 1px solid rgb(var(--color-overlay-white) / 0.08);
            transition: all 0.2s ease;
        }
        .league-mobile-item:hover {
            background: rgb(var(--accent-primary) / 0.12);
            color: rgb(var(--color-text-strong));
        }
        .league-mobile-item--active {
            background: rgb(var(--accent-primary));
            border-color: rgb(var(--accent-primary));
            color: rgb(var(--color-text-strong));
        }

        /* Модальное окно подписок */
        .subscription-item {
            border: 1px solid rgb(var(--color-overlay-white) / 0.08);
            border-radius: 12px;
            padding: 12px 14px;
            margin-bottom: 10px;
            background: rgb(var(--color-card) / 0.4);
        }
        .subscription-head {
            display: flex;
            align-items: center;
            gap: 12px;
            margin-bottom: 8px;
        }
        .subscription-logo {
            width: 2.75rem;
            height: 2.75rem;
            border-radius: 12px;
            object-fit: cover;
            flex-shrink: 0;
        }
        .subscription-logo-fallback {
            display: flex;
            align-items: center;
            justify-content: center;
            background: linear-gradient(135deg, rgb(var(--accent-primary)), rgb(var(--accent-purple)));
            color: rgb(var(--color-text-strong));
            font-weight: 700;
        }
        .subscription-name {
            font-weight: 600;
            color: rgb(var(--color-text-strong));
            font-size: 14px;
        }
        .subscription-name:hover {
            color: rgb(var(--accent-primary-light));
        }
        .subscription-meta {
            color: rgb(var(--color-text-faint));
            font-size: 12px;
        }
        .subscription-match {
            display: flex;
            align-items: center;
            gap: 10px;
            padding: 8px 10px;
            border-radius: 10px;
            background: rgb(var(--accent-primary) / 0.06);
            border: 1px solid rgb(var(--accent-primary) / 0.15);
            margin-top: 6px;
        }
        .subscription-match-icon {
            color: rgb(var(--accent-primary-light));
            font-size: 18px;
        }
        .subscription-match-info {
            flex: 1;
            min-width: 0;
        }
        .subscription-match-teams {
            font-size: 13px;
            color: rgb(var(--color-text-secondary));
            font-weight: 600;
        }
        .subscription-match-date {
            font-size: 12px;
            color: rgb(var(--color-text-faint));
            display: flex;
            align-items: center;
            gap: 4px;
            margin-top: 2px;
        }
        .subscription-nomatch {
            font-size: 12px;
            color: rgb(var(--color-text-faint));
            padding: 6px 10px;
            font-style: italic;
        }

        /* Файлы (документы турнира): иконка расширения + дата */
        .tourney-file-item {
            display: flex;
            align-items: center;
            gap: 12px;
            padding: 10px 12px;
            border-radius: 10px;
            border: 1px solid rgb(var(--color-overlay-white) / 0.08);
            background: rgb(var(--color-card) / 0.4);
            margin-bottom: 8px;
        }
        .tourney-file-icon {
            width: 42px;
            height: 42px;
            border-radius: 10px;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 10px;
            font-weight: 800;
            letter-spacing: 0.02em;
            color: rgb(var(--color-text-strong));
            flex-shrink: 0;
        }
        .tourney-file-icon--pdf { background: #dc2626; }
        .tourney-file-icon--doc, .tourney-file-icon--docx { background: #2563eb; }
        .tourney-file-icon--xls, .tourney-file-icon--xlsx { background: #16a34a; }
        .tourney-file-icon--file { background: rgb(var(--accent-purple)); }
        .tourney-file-info {
            flex: 1;
            min-width: 0;
        }
        .tourney-file-name {
            display: block;
            font-size: 13px;
            font-weight: 600;
            color: rgb(var(--color-text-secondary));
            word-break: break-word;
        }
        .tourney-file-name:hover {
            color: rgb(var(--accent-primary-light));
        }
        .tourney-file-date {
            display: inline-flex;
            align-items: center;
            gap: 4px;
            font-size: 11px;
            color: rgb(var(--color-text-faint));
            margin-top: 2px;
        }
        .tourney-file-date .material-icons-outlined {
            font-size: 14px;
            color: rgb(var(--accent-primary-light));
        }
