        :root {
            --bg-primary: #0a0a0a;
            --bg-secondary: #111111;
            --bg-card: #161616;
            --text-primary: #e6e6e6;
            --text-secondary: #888888;
            --text-muted: #7a7a7a;
            --accent-green: #8AFBDE;
            --accent-amber: #ffb000;
            --accent-cyan: #00d4ff;
            --accent-purple: #b380ff;
            --accent-red: #ff4444;
            --border-color: #222222;
            --glow-green: rgba(138, 251, 222, 0.3);
            --glow-amber: rgba(255, 176, 0, 0.3);
            --row-hover: rgba(138, 251, 222, 0.05);
        }

        [data-theme="light"] {
            --bg-primary: #f5f5f5;
            --bg-secondary: #ffffff;
            --bg-card: #ffffff;
            --text-primary: #1a1a1a;
            --text-secondary: #555555;
            --text-muted: #767676;
            --accent-green: #542E9A;
            --accent-amber: #d97706;
            --accent-cyan: #542E9A;
            --accent-purple: #542E9A;
            --accent-red: #dc2626;
            --border-color: #e0e0e0;
            --glow-green: rgba(84, 46, 154, 0.2);
            --glow-amber: rgba(217, 119, 6, 0.2);
            --row-hover: rgba(84, 46, 154, 0.05);
        }

        *, *::before, *::after {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }

        html { overflow-x: hidden; }

        body {
            font-family: 'JetBrains Mono', monospace;
            background: var(--bg-primary);
            color: var(--text-primary);
            line-height: 1.6;
            min-height: 100vh;
            overflow-x: hidden;
        }

        ::-webkit-scrollbar { width: 8px; }
        ::-webkit-scrollbar-track { background: var(--bg-secondary); }
        ::-webkit-scrollbar-thumb { background: var(--text-muted); border-radius: 4px; }
        ::-webkit-scrollbar-thumb:hover { background: var(--text-secondary); }

        /* Navigation */
        .nav {
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            z-index: 1000;
            background: rgba(10, 10, 10, 0.95);
            backdrop-filter: blur(10px);
            border-bottom: 1px solid var(--border-color);
            padding: 16px 40px;
            display: flex;
            justify-content: center;
            align-items: center;
        }

        [data-theme="light"] .nav { background: rgba(245, 245, 245, 0.95); }

        .nav .logo {
            position: absolute;
            left: 40px;
        }

        .logo {
            font-size: 20px;
            font-weight: 700;
            color: var(--accent-green);
            text-decoration: none;
            display: flex;
            align-items: center;
            gap: 8px;
        }

        .logo-icon { width: 32px; height: 32px; }
        .logo:hover { text-shadow: 0 0 20px var(--glow-green); }

        .nav-links {
            display: flex;
            gap: 32px;
            list-style: none;
        }

        .nav-links a {
            color: var(--text-secondary);
            text-decoration: none;
            font-size: 14px;
            transition: all 0.3s;
            position: relative;
        }

        .nav-links a:hover {
            color: var(--accent-green);
            text-shadow: 0 0 10px var(--glow-green);
        }

        .nav-links a::before {
            content: '>';
            position: absolute;
            left: -15px;
            opacity: 0;
            color: var(--accent-green);
            transition: all 0.3s;
        }

        .nav-links a:hover::before { opacity: 1; }

        .nav-links a.active {
            color: var(--accent-green);
            text-shadow: 0 0 10px var(--glow-green);
        }

        .nav-right {
            position: absolute;
            right: 40px;
            display: flex;
            align-items: center;
            gap: 12px;
        }

        .theme-toggle {
            background: transparent;
            border: 1px solid var(--border-color);
            color: var(--text-secondary);
            width: 40px;
            height: 40px;
            border-radius: 8px;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 18px;
            transition: all 0.3s;
        }

        .theme-toggle:hover {
            border-color: var(--accent-green);
            color: var(--accent-green);
            box-shadow: 0 0 15px var(--glow-green);
        }




        /* Container */
        .container {
            max-width: 1400px;
            margin: 0 auto;
            padding: 90px 30px 40px;
        }

        .page-header {
            margin-bottom: 25px;
        }

        .page-header h1 {
            font-size: 1.8rem;
            font-weight: 700;
            color: var(--text-primary);
            margin-bottom: 5px;
        }

        .page-header p {
            color: var(--text-secondary);
            font-size: 0.85rem;
        }

        /* Stats Bar */
        .stats-bar {
            display: flex;
            gap: 20px;
            margin-bottom: 20px;
            flex-wrap: wrap;
        }

        .stat-item {
            background: var(--bg-card);
            border: 1px solid var(--border-color);
            padding: 12px 20px;
            border-radius: 8px;
        }

        .stat-label {
            font-size: 0.7rem;
            color: var(--text-secondary);
            margin-bottom: 3px;
        }

        .stat-value {
            font-size: 1.2rem;
            font-weight: 700;
            color: var(--accent-green);
        }
        .stat-of { color: var(--text-muted); font-size: .62em; font-weight: 600; }
        .stat-note { display: block; color: var(--accent-amber); font-size: .58em; font-weight: 600; margin-top: 2px; white-space: nowrap; }

        .stat-value-with-flows {
            display: flex;
            align-items: baseline;
            gap: 10px;
            flex-wrap: wrap;
        }

        .stat-flows {
            display: inline-flex;
            align-items: baseline;
            gap: 8px;
            font-size: 0.72rem;
            font-weight: 600;
        }

        .epoch-stat {
            min-width: 210px;
        }

        .epoch-value-row {
            display: flex;
            justify-content: space-between;
            align-items: baseline;
            gap: 10px;
            margin-bottom: 6px;
        }

        .epoch-title {
            color: var(--accent-green);
            font-size: 1.05rem;
            font-weight: 700;
            white-space: nowrap;
        }

        .epoch-time {
            color: var(--text-secondary);
            font-size: 0.7rem;
            font-weight: 600;
            white-space: nowrap;
        }

        .epoch-progress {
            height: 5px;
            background: var(--bg-secondary);
            border-radius: 999px;
            overflow: hidden;
            margin-bottom: 5px;
        }

        .epoch-progress-fill {
            height: 100%;
            width: 0%;
            background: linear-gradient(90deg, var(--accent-green), var(--accent-purple));
            border-radius: 999px;
            transition: width 0.35s ease;
        }

        .epoch-meta {
            color: var(--text-muted);
            font-size: 0.64rem;
            white-space: nowrap;
        }

        /* Search */
        .search-bar {
            display: flex;
            gap: 12px;
            margin-bottom: 15px;
            flex-wrap: wrap;
            align-items: center;
        }

        .search-input {
            flex: 1;
            min-width: 250px;
            padding: 10px 14px;
            background: var(--bg-secondary);
            border: 1px solid var(--border-color);
            border-radius: 6px;
            color: var(--text-primary);
            font-family: inherit;
            font-size: 0.85rem;
        }

        .search-input:focus {
            outline: none;
            border-color: var(--accent-green);
        }

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


        /* Table */
        .table-wrap {
            overflow-x: auto;
            border: 1px solid var(--border-color);
            border-radius: 8px;
            background: var(--bg-card);
        }

        table {
            width: 100%;
            border-collapse: collapse;
            font-size: 0.8rem;
            white-space: nowrap;
        }

        thead th {
            position: sticky;
            top: 0;
            background: var(--bg-secondary);
            border-bottom: 2px solid var(--border-color);
            padding: 10px 12px;
            text-align: left;
            color: var(--text-secondary);
            font-weight: 500;
            font-size: 0.72rem;
            text-transform: uppercase;
            letter-spacing: 0.5px;
            cursor: pointer;
            user-select: none;
            transition: color 0.2s;
        }

        thead th:hover {
            color: var(--accent-green);
        }

        thead th.sorted {
            color: var(--accent-green);
        }

        thead th .sort-arrow {
            margin-left: 4px;
            font-size: 0.65rem;
            opacity: 0.4;
        }

        thead th.sorted .sort-arrow {
            opacity: 1;
        }

        .col-hint {
            display: inline-block;
            position: relative;
            width: 13px;
            height: 13px;
            line-height: 13px;
            text-align: center;
            font-size: 0.6rem;
            font-weight: 700;
            border-radius: 50%;
            background: var(--text-muted);
            color: var(--bg-primary);
            cursor: help;
            vertical-align: middle;
            margin-left: 3px;
            opacity: 0.7;
        }
        .col-hint:hover {
            opacity: 1;
            background: var(--accent-green);
        }
        .col-hint .hint-tip {
            display: none;
            position: absolute;
            top: 20px;
            left: 50%;
            transform: translateX(-50%);
            background: var(--bg-card);
            border: 1px solid var(--border-color);
            color: var(--text-secondary);
            font-size: 0.7rem;
            font-weight: 400;
            padding: 6px 10px;
            border-radius: 4px;
            white-space: nowrap;
            z-index: 100;
            pointer-events: none;
        }
        .col-hint:hover .hint-tip {
            display: block;
        }

        tbody tr {
            border-bottom: 1px solid var(--border-color);
            transition: background 0.15s;
        }

        tbody tr:last-child {
            border-bottom: none;
        }

        tbody tr:hover {
            background: var(--row-hover);
        }

        td {
            padding: 8px 12px;
            color: var(--text-primary);
        }

        .col-rank {
            text-align: center;
            color: var(--text-muted);
            width: 50px;
        }

        .col-name {
            min-width: 200px;
        }

        .validator-name-cell {
            display: flex;
            align-items: center;
            gap: 8px;
        }

        .validator-avatar {
            width: 24px;
            height: 24px;
            border-radius: 50%;
            object-fit: cover;
            flex-shrink: 0;
            background: var(--bg-secondary);
        }

        /* Валидаторы без логотипа: буква вместо пустого кружка. Пустой кружок
           читается как сломанная картинка, буква — как «логотипа нет». */
        .validator-avatar-letter {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            font-size: 0.72rem;
            font-weight: 700;
            color: #fff;
            line-height: 1;
            user-select: none;
        }

        .validator-name-link {
            min-width: 0;
            color: var(--text-primary);
            text-decoration: none;
            overflow: hidden;
            text-overflow: ellipsis;
            max-width: 220px;
            display: inline-block;
        }

        .validator-name-link:hover {
            color: var(--accent-green);
        }

        /* Score bar */
        .score-cell {
            display: flex;
            align-items: center;
            gap: 6px;
        }

        .score-bar {
            width: 50px;
            height: 6px;
            background: var(--bg-secondary);
            border-radius: 3px;
            overflow: hidden;
            flex-shrink: 0;
        }

        .score-bar-fill {
            height: 100%;
            border-radius: 3px;
        }

        .score-val {
            font-size: 0.78rem;
            font-weight: 500;
        }

        /* Color classes */
        .text-green { color: #00cc66; }
        /* тот же зелёный на белом читается плохо (контраст 1.97) */
        [data-theme="light"] .text-green,
        [data-theme="light"] .score-val { color: #0a8f4d; }
        .text-yellow { color: #ffb000; }
        .text-orange { color: #ff8c00; }
        .text-red { color: #ff4444; }
        [data-theme="light"] .text-green { color: #16803c; }
        [data-theme="light"] .text-yellow { color: #d97706; }
        [data-theme="light"] .text-orange { color: #ea580c; }
        [data-theme="light"] .text-red { color: #dc2626; }

        .badge-delinquent {
            background: var(--accent-red);
            color: #fff;
            font-size: 0.65rem;
            padding: 2px 6px;
            border-radius: 4px;
            font-weight: 700;
        }

        .badge-ok {
            color: var(--text-muted);
            font-size: 0.75rem;
        }

        /* Pagination */
        .pagination {
            display: flex;
            justify-content: center;
            align-items: center;
            gap: 8px;
            margin-top: 20px;
            flex-wrap: wrap;
        }

        .page-btn {
            padding: 6px 12px;
            background: var(--bg-card);
            border: 1px solid var(--border-color);
            border-radius: 6px;
            color: var(--text-secondary);
            font-family: inherit;
            font-size: 0.78rem;
            cursor: pointer;
            transition: all 0.2s;
        }

        .page-btn:hover {
            border-color: var(--accent-green);
            color: var(--accent-green);
        }

        .page-btn.active {
            background: var(--accent-green);
            color: var(--bg-primary);
            border-color: var(--accent-green);
            font-weight: 700;
        }

        .page-btn:disabled {
            opacity: 0.3;
            cursor: default;
        }

        .page-info {
            font-size: 0.75rem;
            color: var(--text-muted);
            padding: 0 8px;
        }

        /* Loading */
        .loading {
            text-align: center;
            padding: 60px 20px;
            color: var(--text-secondary);
            font-size: 0.9rem;
        }

        .loading-spinner {
            display: inline-block;
            width: 20px;
            height: 20px;
            border: 2px solid var(--border-color);
            border-top-color: var(--accent-green);
            border-radius: 50%;
            animation: spin 0.8s linear infinite;
            margin-right: 8px;
            vertical-align: middle;
        }

        @keyframes spin {
            to { transform: rotate(360deg); }
        }

        .error-msg {
            text-align: center;
            padding: 40px 20px;
            color: var(--accent-red);
            font-size: 0.85rem;
        }

        /* Footer */
        .footer {
            border-top: 1px solid var(--border-color);
            padding: 40px;
            text-align: center;
            margin-top: 60px;
        }

        .footer-links {
            display: flex;
            justify-content: center;
            gap: 32px;
            margin-bottom: 24px;
        }

        .footer-links a {
            color: var(--text-secondary);
            text-decoration: none;
            font-size: 14px;
            transition: all 0.3s;
        }

        .footer-links a:hover {
            color: var(--accent-green);
        }

        .footer-text {
            color: var(--text-muted);
            font-size: 12px;
        }

        .prompt { color: #00ff00; }
        [data-theme="light"] .prompt { color: #542E9A; }

        /* Wallet button */
        .wallet-btn {
            background: transparent;
            border: 1px solid var(--border-color);
            color: var(--text-secondary);
            padding: 6px 12px;
            font-family: 'JetBrains Mono', monospace;
            font-size: 12px;
            border-radius: 8px;
            cursor: pointer;
            transition: all 0.3s;
            white-space: nowrap;
        }

        .wallet-btn:hover {
            border-color: var(--accent-green);
            color: var(--accent-green);
            box-shadow: 0 0 15px var(--glow-green);
        }

        .wallet-btn.connected {
            border-color: var(--accent-green);
            color: var(--accent-green);
        }

        .wallet-btn .wallet-short {
            display: none;
        }

        /* Modal system */
        .modal-overlay {
            position: fixed;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: rgba(0, 0, 0, 0.9);
            backdrop-filter: blur(4px);
            display: flex;
            align-items: center;
            justify-content: center;
            z-index: 2000;
        }

        .modal {
            background: var(--bg-card);
            border: 1px solid var(--border-color);
            border-radius: 8px;
            padding: 24px;
            max-width: 400px;
            width: 90%;
            animation: modalIn 0.3s ease;
        }

        @keyframes modalIn {
            from { opacity: 0; transform: scale(0.95); }
            to { opacity: 1; transform: scale(1); }
        }

        .modal h3 {
            margin-bottom: 20px;
            font-size: 1.1rem;
            color: var(--accent-green);
        }

        .modal-input {
            width: 100%;
            padding: 12px;
            background: var(--bg-primary);
            border: 1px solid var(--border-color);
            border-radius: 4px;
            color: var(--text-primary);
            font-size: 1rem;
            font-family: 'JetBrains Mono', monospace;
            margin-bottom: 12px;
        }

        .modal-input:focus {
            outline: none;
            border-color: var(--accent-green);
        }

        .modal-info {
            font-size: 0.8rem;
            color: var(--text-secondary);
            margin-bottom: 20px;
        }

        .modal-buttons {
            display: flex;
            gap: 12px;
        }

        .modal-buttons .btn {
            flex: 1;
            padding: 10px;
        }

        /* Buttons */
        .btn {
            width: 100%;
            padding: 12px 20px;
            border: 1px solid var(--accent-green);
            border-radius: 4px;
            font-size: 0.9rem;
            font-weight: 500;
            font-family: 'JetBrains Mono', monospace;
            cursor: pointer;
            transition: all 0.3s ease;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 10px;
            background: transparent;
            color: var(--accent-green);
        }

        .btn:hover {
            background: var(--accent-green);
            color: var(--bg-primary);
            box-shadow: 0 0 20px var(--glow-green);
        }

        .btn:disabled {
            opacity: 0.4;
            cursor: not-allowed;
            box-shadow: none;
        }

        .btn:disabled:hover {
            background: transparent;
            color: var(--accent-green);
        }

        .btn-secondary {
            color: var(--text-secondary);
            border-color: var(--border-color);
        }

        .btn-secondary:hover {
            border-color: var(--text-secondary);
            color: var(--text-primary);
            background: transparent;
            box-shadow: none;
        }

        /* Wallet options */
        .wallet-option {
            padding: 12px 16px;
            background: var(--bg-primary);
            border: 1px solid var(--border-color);
            border-radius: 4px;
            margin-bottom: 8px;
            cursor: pointer;
            transition: all 0.2s;
            display: flex;
            align-items: center;
            gap: 12px;
            font-family: 'JetBrains Mono', monospace;
            color: var(--text-primary);
        }

        .wallet-option:hover {
            border-color: var(--accent-green);
            background: rgba(138, 251, 222, 0.05);
        }

        .wallet-option .wallet-name {
            flex: 1;
        }

        .wallet-option .wallet-status {
            font-size: 0.75rem;
            color: var(--text-muted);
        }

        /* Stake button in table */
        .stake-btn {
            padding: 4px 10px;
            font-size: 0.7rem;
            font-family: 'JetBrains Mono', monospace;
            background: transparent;
            border: 1px solid var(--accent-green);
            color: var(--accent-green);
            border-radius: 4px;
            cursor: pointer;
            transition: all 0.2s;
        }

        .stake-btn:hover {
            background: var(--accent-green);
            color: var(--bg-primary);
            box-shadow: 0 0 10px var(--glow-green);
        }

        .col-stake {
            width: 60px;
            text-align: center;
        }

        .stake-presets {
            display: flex;
            gap: 8px;
            margin-bottom: 12px;
        }

        .stake-preset {
            flex: 1;
            padding: 6px;
            background: transparent;
            border: 1px solid var(--border-color);
            border-radius: 4px;
            color: var(--text-secondary);
            font-family: 'JetBrains Mono', monospace;
            font-size: 0.75rem;
            cursor: pointer;
            transition: all 0.2s;
        }

        .stake-preset:hover {
            border-color: var(--accent-green);
            color: var(--accent-green);
        }

        /* Toast notifications */
        .toast-container {
            position: fixed;
            top: 80px;
            right: 20px;
            z-index: 10000;
            display: flex;
            flex-direction: column;
            gap: 10px;
            max-width: 380px;
        }

        .toast {
            background: var(--bg-secondary);
            border-radius: 8px;
            padding: 16px 20px;
            box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
            animation: slideIn 0.3s ease;
            display: flex;
            align-items: flex-start;
            gap: 12px;
            border-left: 3px solid var(--accent-amber);
        }

        .toast.success { border-left-color: var(--accent-green); }
        .toast.error { border-left-color: var(--accent-red); }
        .toast.info { border-left-color: var(--accent-amber); }

        .toast-icon {
            font-size: 1.2rem;
            flex-shrink: 0;
        }

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

        .toast-title {
            font-weight: 600;
            margin-bottom: 4px;
            color: var(--text-primary);
        }

        .toast-message {
            font-size: 0.85rem;
            color: var(--text-secondary);
            word-break: break-word;
        }

        .toast-message a {
            color: var(--accent-green);
            text-decoration: none;
        }

        .toast-message a:hover { text-decoration: underline; }

        .toast-close {
            background: none;
            border: none;
            color: var(--text-muted);
            cursor: pointer;
            padding: 0;
            font-size: 1.2rem;
            line-height: 1;
        }

        .toast-close:hover { color: var(--text-primary); }

        .toast-progress {
            display: flex;
            align-items: center;
            gap: 8px;
            margin-top: 8px;
        }

        .toast-spinner {
            width: 14px;
            height: 14px;
            border: 2px solid var(--border-color);
            border-top-color: var(--accent-green);
            border-radius: 50%;
            animation: spin 1s linear infinite;
        }

        @keyframes slideIn {
            from { transform: translateX(100%); opacity: 0; }
            to { transform: translateX(0); opacity: 1; }
        }

        @keyframes slideOut {
            from { transform: translateX(0); opacity: 1; }
            to { transform: translateX(100%); opacity: 0; }
        }

        .toast.hiding {
            animation: slideOut 0.3s ease forwards;
        }

        .hidden {
            display: none !important;
        }

        /* Responsive */
        @media (max-width: 768px) {
            .nav {
                padding: 10px 16px;
                flex-wrap: wrap;
                justify-content: space-between;
                gap: 8px;
            }
            .nav .logo {
                position: static;
                font-size: 16px;
            }
            .nav .logo-icon {
                width: 24px;
                height: 24px;
            }
            .nav-right {
                position: static;
                gap: 8px;
            }
            .nav-links {
                order: 3;
                width: 100%;
                justify-content: center;
                gap: 16px;
                font-size: 0.65rem;
            }
            .nav-links a {
                font-size: 11px;
            }
            .nav-links a::before {
                display: none;
            }
            .theme-toggle {
                width: 36px;
                height: 36px;
            }
            .container { padding: 110px 12px 24px; }
            .page-header h1 { font-size: 1.2rem; }
            .stats-bar { gap: 8px; }
            .stat-item { padding: 8px 12px; flex: 1; min-width: 120px; }
            .stat-value { font-size: 1rem; }
            .stat-label { font-size: 0.65rem; }
            .search-input { min-width: 150px; }
            table { font-size: 0.72rem; }
            td, thead th { padding: 6px 8px; }
            .validator-name-link { max-width: 140px; }
            .wallet-btn { padding: 4px 8px; font-size: 11px; }
            .wallet-btn .wallet-full { display: none; }
            .wallet-btn .wallet-short { display: inline; }
            .modal { width: 95%; max-width: none; margin: 16px; }
            .toast-container { top: auto; bottom: 20px; right: 10px; left: 10px; max-width: none; }
            .toast { padding: 12px 16px; }
        }

        @media (max-width: 480px) {
            .stats-bar { flex-direction: column; }
            .stat-item { min-width: unset; }
            .col-lux8, .col-version { display: none; }
        }
        .stake-up { color: var(--accent-green); font-size: 0.8em; }
        .stake-down { color: var(--accent-red); font-size: 0.8em; }
        .stake-flow { font-size: 0.85em; }

        /* Commission-change badge (validators that raised commission last epoch) */
        .comm-flag {
            display: inline-block;
            margin-left: 5px;
            font-size: 0.7em;
            font-weight: 700;
            padding: 1px 5px;
            border-radius: 3px;
            vertical-align: middle;
            white-space: nowrap;
            cursor: help;
            color: var(--accent-amber);
            background: rgba(255, 176, 0, 0.12);
        }
        .comm-flag-hike {
            color: var(--accent-red);
            background: rgba(255, 68, 68, 0.15);
        }
        /* Светлая тема: янтарь темы (#d97706) на своей же янтарной подложке даёт
           контраст 2.95 при пороге 3.0. Глобальный цвет не трогаем — на обычном
           фоне он проходит; темнее только текст пометки. */
        [data-theme="light"] .comm-flag:not(.comm-flag-hike) { color: #b45309; }

        /* Clickable stat that toggles the commission-cheater filter — kept compact */
        .stat-toggle {
            cursor: pointer;
            transition: border-color 0.15s, background 0.15s;
            padding: 8px 12px;
            display: flex;
            align-items: center;
            gap: 8px;
        }
        .stat-toggle .stat-label { margin-bottom: 0; font-size: 0.65rem; }
        .stat-toggle .stat-value { font-size: 0.95rem; }
        .stat-toggle:hover { border-color: var(--accent-red); }
        .stat-toggle.active {
            border-color: var(--accent-red);
            background: rgba(255, 68, 68, 0.08);
        }

        /* Pin control */
        .col-pin { width: 24px; text-align: center; }
        th.col-pin, td.col-pin {
            width: 24px;
            padding-left: 4px;
            padding-right: 4px;
            text-align: center;
        }
        .pin-cb {
            appearance: none;
            -webkit-appearance: none;
            width: 12px;
            height: 12px;
            margin: 0;
            display: inline-grid;
            place-content: center;
            cursor: pointer;
            vertical-align: middle;
            border: 1px solid var(--border-color);
            border-radius: 3px;
            background: var(--bg-secondary);
            transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
        }
        .pin-cb:hover {
            border-color: var(--accent-green);
            box-shadow: 0 0 8px var(--glow-green);
        }
        .pin-cb::before {
            content: "";
            width: 3px;
            height: 6px;
            border-right: 1.5px solid var(--bg-primary);
            border-bottom: 1.5px solid var(--bg-primary);
            transform: rotate(45deg) scale(0);
            transform-origin: center;
            transition: transform 0.12s ease;
        }
        .pin-cb:checked {
            background: var(--accent-green);
            border-color: var(--accent-green);
            box-shadow: 0 0 10px var(--glow-green);
        }
        .pin-cb:checked::before {
            transform: rotate(45deg) scale(1);
        }
        tr.pinned-row { background: rgba(138, 251, 222, 0.04); }
        [data-theme="light"] tr.pinned-row { background: rgba(84, 46, 154, 0.04); }
        tr.pinned-row:hover { background: rgba(138, 251, 222, 0.09); }
        [data-theme="light"] tr.pinned-row:hover { background: rgba(84, 46, 154, 0.09); }
        tr.pinned-separator td { border-top: 2px solid var(--accent-green); }
        [data-theme="light"] tr.pinned-separator td { border-top: 2px solid var(--accent-purple); }

        @media (prefers-reduced-motion: reduce) {
            *, *::before, *::after {
                animation-duration: 0.01ms !important;
                animation-iteration-count: 1 !important;
                transition-duration: 0.01ms !important;
            }
            html {
                scroll-behavior: auto;
            }
        }

        /* Network switcher (SOL <-> X1) */
        .net-switch {
            position: absolute;
            left: 88px;
            top: 50%;
            transform: translateY(-50%);
            display: inline-flex;
            border: 1px solid var(--border-color);
            border-radius: 8px;
            overflow: hidden;
        }
        .net-switch .net-opt {
            padding: 4px 10px;
            font-size: 11px;
            font-weight: 700;
            letter-spacing: 0.5px;
            line-height: 1.4;
            color: var(--text-muted);
            text-decoration: none;
            transition: all 0.2s;
        }
        .net-switch a.net-opt:hover {
            color: var(--accent-green);
            text-shadow: 0 0 8px var(--glow-green);
        }
        .net-switch .net-opt.active {
            background: var(--accent-green);
            color: var(--bg-primary);
        }
        @media (max-width: 768px) {
            .net-switch {
                position: static;
                transform: none;
            }
            .net-switch .net-opt {
                padding: 3px 8px;
                font-size: 10px;
            }
        }

        th[tabindex]:focus-visible { outline: 2px solid var(--accent-green); outline-offset: -2px; }
        @media (max-width: 900px) {
            .nav {
                flex-wrap: wrap;
                justify-content: center;
                gap: 10px;
                padding: 10px 12px;
            }
            .nav .logo, .nav-right, .net-switch {
                position: static;
                transform: none;
                left: auto;
                right: auto;
            }
            .nav-links {
                order: 3;
                width: 100%;
                justify-content: center;
                gap: 16px;
                flex-wrap: wrap;
            }
            .nav-links a { font-size: 12px; }
            /* the bar wraps to 2-3 rows on a phone; keeping it fixed would
               hide the top of the page under it */
            .nav { position: static; }
            .container { padding-top: 24px; }
        }
        .col-info {
            display: inline-block; position: relative;
            width: 13px; height: 13px; line-height: 13px;
            text-align: center; font-size: .6rem; font-weight: 700; font-style: italic;
            border-radius: 50%; background: var(--text-muted); color: var(--bg-primary);
            cursor: pointer; vertical-align: middle; margin-left: 4px; opacity: .7;
            font-family: Georgia, 'Times New Roman', serif;
        }
        .col-info:hover, .col-info.open { opacity: 1; background: var(--accent-green); }
        .info-pop {
            display: none; position: absolute; top: 20px; left: 50%; transform: translateX(-50%);
            background: var(--bg-card); border: 1px solid var(--border-color); color: var(--text-secondary);
            font-size: .72rem; font-weight: 400; font-style: normal; font-family: 'JetBrains Mono', monospace;
            text-transform: none; letter-spacing: 0; line-height: 1.5; text-align: left;
            padding: 9px 11px; border-radius: 6px; width: 260px; max-width: calc(100vw - 16px);
            white-space: normal; z-index: 2000;
            box-shadow: 0 6px 20px rgba(0,0,0,.18);
        }
        .col-info.open .info-pop { display: block; }
        .col-provider { max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
        /* validators we run ourselves — disclosed, not decorated. The
           explanation is our own popup rather than a native title: title never
           appears on touch and is easy to miss on desktop. */
        /* Цвета D-Score по темам. На тёмном оставлены прежние — там они
           хороши. На светлом заменены на читаемые: замерено, #00cc66 давал
           контраст 1.97, #88cc00 — столько же, а это главная цифра страницы. */
        .sc-none { color: var(--text-muted); }
        .sc-90 { color: #00cc66; } .sc-70 { color: #88cc00; }
        .sc-50 { color: #ffb000; } .sc-30 { color: #ff8c00; } .sc-low { color: #ff4444; }
        .score-bar-fill.sc-none { background: var(--text-muted); }
        .score-bar-fill.sc-90 { background: #00cc66; } .score-bar-fill.sc-70 { background: #88cc00; }
        .score-bar-fill.sc-50 { background: #ffb000; } .score-bar-fill.sc-30 { background: #ff8c00; }
        .score-bar-fill.sc-low { background: #ff4444; }
        [data-theme="light"] .score-val.sc-90 { color: #0a8f4d; }
        [data-theme="light"] .score-val.sc-70 { color: #4d7c0f; }
        [data-theme="light"] .score-val.sc-50 { color: #b45309; }
        [data-theme="light"] .score-val.sc-30 { color: #c2410c; }
        [data-theme="light"] .score-val.sc-low { color: #dc2626; }
    
        /* На узком экране карточка эпохи всего 178 px, а строка «Swept 4 h ago —
           the full scan runs once per epoch» занимает 294 px: при nowrap она
           просто вылезала за карточку. Перенос разрешён там, где места нет, и
           запрещён там, где оно есть, — иначе фраза ломалась бы посередине на
           широком экране без всякой нужды. Замерено: 294 px текста в поле 152. */
        @media (max-width: 900px) {
            .epoch-meta { white-space: normal; line-height: 1.35; }
        }

        /* Снимок для краулеров без JavaScript: людям его рисует скрипт (класс js — из theme-boot.js) */
        .js [data-static-validators], .js [data-static-validator] { display: none; }
            /* ссылка на методику: цвет акцента, иначе браузерный синий не читается в тёмной теме */
        .method-link { color: var(--accent-green); }
