        /* Network Map Styles */
        #networkView {
            margin-top: -32px;
            padding: 0 !important;
            min-width: 1200px;
            margin-left: calc(-50vw + 50%);
            margin-right: calc(-50vw + 50%);
        }

        /* Map section */
        #networkView > section:first-child {
            width: 100%;
            min-width: 1200px;
            padding: 0;
            margin-bottom: 0;
        }

        #networkMapWrapper {
            position: relative;
            width: 100%;
            min-width: 1200px;
        }

        #networkMap {
            min-width: 1200px !important;
            width: 100%;
            height: calc(100vh - 180px);
            border-radius: 0;
            border: none;
            background: #111934;
        }

        #mapOverlayTitle {
            position: absolute;
            top: 20px;
            left: 50%;
            transform: translateX(-50%);
            font-size: 1.25rem;
            font-weight: 600;
            color: var(--text-primary);
            background: rgba(9, 9, 11, 0.7);
            padding: 8px 20px;
            border-radius: var(--radius-lg);
            border: 1px solid var(--border);
            z-index: 1000;
            display: flex;
            align-items: center;
            gap: 10px;
        }

        #mapOverlayTitle .title-logo {
            height: 30px;
            width: auto;
        }

        #mapOverlayLegend {
            position: absolute;
            top: 20px;
            right: 20px;
            display: flex;
            align-items: center;
            justify-content: space-between;
            font-size: 13px;
            color: var(--text-helper);
            background: rgba(9, 9, 11, 0.7);
            padding: 8px 24px;
            border-radius: var(--radius-lg);
            border: 1px solid var(--border);
            z-index: 1000;
        }

        /* Leaflet zoom controls positioning (10px + 10px Leaflet margin = 20px total) */
        .leaflet-top {
            top: 10px !important;
        }

        .leaflet-left {
            left: 10px !important;
        }

        .leaflet-right {
            right: 10px !important;
        }

        /* Leaflet zoom/bar controls styling - dark theme (high specificity to override leaflet.css) */
        .leaflet-bar {
            border: none !important;
            box-shadow: none !important;
        }

        .leaflet-bar a,
        .leaflet-bar a:hover,
        .leaflet-bar a:focus,
        .leaflet-control-zoom-in,
        .leaflet-control-zoom-out {
            background-color: #000 !important;
            color: #fff !important;
            border: 1px solid var(--border) !important;
            border-bottom: 1px solid var(--border) !important;
        }

        .leaflet-bar a:first-child {
            border-top-left-radius: 4px !important;
            border-top-right-radius: 4px !important;
        }

        .leaflet-bar a:last-child {
            border-bottom-left-radius: 4px !important;
            border-bottom-right-radius: 4px !important;
        }

        .leaflet-bar a.leaflet-disabled {
            background-color: #222 !important;
            color: #666 !important;
        }

        #mapOverlayLegend .legend-item {
            display: flex;
            align-items: center;
            gap: 8px;
        }

        /* Validator list section below map */
        #networkView > section:nth-child(2) {
            width: 100%;
            padding: 0;
        }

        /* Metrics box below legend */
        #mapMetrics {
            position: absolute;
            top: 60px;
            right: 20px;
            background: rgba(9, 9, 11, 0.7);
            padding: 12px 16px;
            border-radius: var(--radius-lg);
            border: 1px solid var(--border);
            z-index: 1000;
            font-size: 12px;
        }

        #mapMetrics .metrics-title {
            color: var(--text-helper);
            font-size: 10px;
            text-transform: uppercase;
            letter-spacing: 0.5px;
            margin-bottom: 8px;
        }

        #mapMetrics .metric-row {
            display: flex;
            justify-content: space-between;
            gap: 24px;
            margin-bottom: 4px;
        }

        #mapMetrics .metric-label {
            color: var(--text-helper);
            display: flex;
            align-items: center;
        }

        #mapMetrics .metric-label .info-icon-wrapper {
            position: relative;
            margin-left: 3px;
        }

        #mapMetrics .metric-label .info-icon {
            width: 11px;
            height: 11px;
        }

        #mapMetrics .metric-label .info-tooltip {
            position: absolute;
            top: calc(100% + 6px);
            right: 0;
            left: auto;
            transform: none;
            width: 220px;
        }

        #mapMetrics .metric-value {
            color: var(--text-primary);
            font-weight: 600;
        }

        /* Search Overlay (bottom right of map) */
        #mapSearchOverlay {
            position: absolute;
            bottom: 20px;
            right: 20px;
            z-index: 1000;
        }

        #mapSearchOverlay input {
            background: rgba(9, 9, 11, 0.7);
            border: 1px solid var(--border);
            border-radius: var(--radius-lg);
            color: var(--text-primary);
            padding: 10px 14px;
            font-size: 13px;
            width: 200px;
            outline: none;
        }

        #mapSearchOverlay input:focus {
            border-color: var(--accent);
        }

        #mapSearchOverlay input::placeholder {
            color: var(--text-helper);
        }

        /* Leader display elements (used by leader.js DOM builders) */
        .leader-icon-placeholder {
            width: 32px;
            height: 32px;
            border-radius: 50%;
            background: var(--bg-app);
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 14px;
            font-weight: 700;
            color: var(--text-primary);
        }
        .leader-row-wrapper {
            display: flex;
            align-items: center;
            gap: 10px;
        }
        .leader-loading-cell {
            text-align: center;
            color: var(--text-disabled);
            padding: 20px;
        }

        /* Leader popup and detail text styles */
        .leader-popup-name {
            font-size: 13px;
            font-weight: 600;
            color: var(--text-primary);
        }
        .leader-detail-name {
            font-size: 14px;
            font-weight: 600;
            color: var(--text-primary);
        }
        .leader-detail-location {
            font-size: 11px;
            color: var(--text-helper);
            margin-top: 2px;
        }
        .leader-detail-ip {
            font-size: 11px;
            color: var(--text-secondary);
            margin-top: 2px;
            font-family: monospace;
        }

        /* Map popup text styles (used by map.js DOM builders) */
        .map-popup-name-mobile {
            font-size: 13px;
            font-weight: 600;
            color: var(--text-primary);
        }
        .map-popup-pubkey {
            font-size: 11px;
            text-transform: uppercase;
            letter-spacing: 0.5px;
            color: var(--text-helper);
            margin-bottom: 8px;
        }
        .map-popup-name {
            font-size: 16px;
            font-weight: 600;
            color: var(--text-primary);
            margin-bottom: 10px;
        }
        .map-popup-details {
            font-size: 12px;
            color: var(--text-secondary);
            line-height: 1.8;
        }
        .map-popup-label { color: var(--text-helper); }

        /* Leaflet pane and control overrides */
        .leader-pane { z-index: 650; }
        .leaflet-reset-container {
            margin-top: -1px;
            border-top: none;
        }

        /* Table utility classes */
        .empty-table-cell {
            text-align: center;
            padding: 20px;
        }
        .virtual-spacer-cell {
            padding: 0;
            border: none;
        }

        /* Map reset zoom button */
        .leaflet-reset-btn {
            font-weight: normal;
            font-size: 18px;
            line-height: 30px;
            width: 30px;
            height: 30px;
            display: block;
            text-align: center;
            text-decoration: none;
            color: var(--text-primary);
            background: var(--bg-app);
            border: none;
            border-radius: 0 0 4px 4px;
        }

        /* Current Leader Overlay (right of leader schedule) */
        #currentLeaderOverlay {
            position: absolute;
            bottom: 20px;
            left: 360px;
            width: 320px;
            background: rgba(9, 9, 11, 0.7);
            border: 1px solid var(--border);
            border-radius: var(--radius-lg);
            z-index: 1000;
            padding: 16px;
        }

        .current-leader-title {
            font-size: 11px;
            /* Removed font-weight: 600 to match leader schedule header */
            color: var(--text-helper);
            text-transform: uppercase;
            letter-spacing: 0.5px;
            margin-bottom: 12px;
        }

        .current-leader-main {
            display: flex;
            align-items: center;
            gap: 12px;
            margin-bottom: 12px;
        }

        .current-leader-icon {
            width: 48px;
            height: 48px;
            border-radius: 50%;
            background: var(--accent);
            flex-shrink: 0;
            object-fit: cover;
        }

        .current-leader-icon-placeholder {
            width: 48px;
            height: 48px;
            border-radius: 50%;
            background-color: #000;
            background-size: cover;
            background-position: center;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 20px;
            font-weight: 600;
            color: white;
            flex-shrink: 0;
        }

        .current-leader-info {
            flex: 1;
            min-width: 0;
        }

        .current-leader-name {
            font-size: 16px;
            font-weight: 600;
            color: var(--text-primary);
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }

        .current-leader-slot {
            font-size: 12px;
            color: var(--text-helper);
            margin-top: 2px;
        }

        /* 4 Slot Bars - CSS Animation Based (can't be interrupted by JS) */
        .slot-bars {
            display: flex;
            gap: 6px;
            margin-bottom: 16px;
        }

        .slot-bar {
            flex: 1;
            height: 8px;
            background: rgba(1, 104, 229, 0.15);
            border: 1px solid rgba(1, 104, 229, 0.3);
            border-radius: 4px;
            overflow: hidden;
            position: relative;
        }

        /* CSS Keyframe animation for bar fill */
        @keyframes fillBar {
            0% { background: rgba(1, 104, 229, 0.15); border-color: rgba(1, 104, 229, 0.3); }
            100% { background: linear-gradient(to right, rgba(1, 104, 229, 0.5) 0%, rgba(1, 104, 229, 0.2) 100%); border-color: #0168E5; }
        }

        /* When .animating class is on container, each bar fills with CSS delay */
        .slot-bars.animating .slot-bar:nth-child(1) {
            animation: fillBar 0.01s ease-out forwards;
            animation-delay: 0ms;
        }
        .slot-bars.animating .slot-bar:nth-child(2) {
            animation: fillBar 0.01s ease-out forwards;
            animation-delay: 350ms;
        }
        .slot-bars.animating .slot-bar:nth-child(3) {
            animation: fillBar 0.01s ease-out forwards;
            animation-delay: 700ms;
        }
        .slot-bars.animating .slot-bar:nth-child(4) {
            animation: fillBar 0.01s ease-out forwards;
            animation-delay: 1050ms;
        }

        /* Upcoming Leaders */
        .upcoming-leaders {
            display: flex;
            align-items: center;
            gap: 8px;
            padding-top: 12px;
            border-top: 1px solid var(--border);
        }

        .upcoming-label {
            font-size: 10px;
            color: var(--text-helper);
            text-transform: uppercase;
            letter-spacing: 0.5px;
            white-space: nowrap;
        }

        .upcoming-icons {
            display: flex;
            gap: 4px;
            flex: 1;
            justify-content: flex-end;
        }

        .upcoming-icon {
            width: 28px;
            height: 28px;
            border-radius: 50%;
            background-color: #000;
            background-size: cover;
            background-position: center;
            border: 1px solid var(--border);
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 11px;
            font-weight: 600;
            color: white;
            opacity: 0.7;
            transition: opacity 0.2s, transform 0.2s;
        }

        .upcoming-icon:hover {
            opacity: 1;
            transform: scale(1.1);
        }

        /* Block Production Overlay (right of Current Leader) */
        #blockProductionOverlay {
            position: absolute;
            bottom: 20px;
            left: 700px;
            width: 320px;
            background: rgba(9, 9, 11, 0.7);
            border: 1px solid var(--border);
            border-radius: var(--radius-lg);
            z-index: 1000;
            padding: 14px 16px;
        }

        .block-prod-title {
            font-size: 11px;
            /* Removed font-weight: 600 to match other section headers */
            color: var(--text-helper);
            text-transform: uppercase;
            letter-spacing: 0.5px;
            margin-bottom: 12px;
        }

        .block-prod-chart {
            display: flex;
            align-items: flex-end;
            gap: 2px;
            height: 60px;
            margin-bottom: 12px;
        }

        .epoch-bar {
            flex: 1;
            display: flex;
            flex-direction: column;
            border-radius: 2px;
            overflow: hidden;
            cursor: pointer;
            transition: opacity 0.2s;
        }

        .epoch-bar:hover {
            opacity: 0.8;
        }

        .bar-prod {
            background: linear-gradient(to bottom, rgba(1, 104, 229, 0.35) 0%, rgba(1, 104, 229, 0.1) 100%);
            border: 1px solid #0168E5;
            border-top: none;
            width: 100%;
        }

        .bar-skip {
            background: linear-gradient(to top, rgba(239, 68, 68, 0.35) 0%, rgba(239, 68, 68, 0.1) 100%);
            border: 1px solid #ef4444;
            border-bottom: none;
            width: 100%;
        }

        .block-prod-stats {
            font-size: 11px;
            color: var(--text-secondary);
        }

        .block-prod-row {
            display: flex;
            align-items: center;
            gap: 6px;
            margin-bottom: 3px;
        }

        .block-prod-row:last-child {
            margin-bottom: 0;
        }

        .prod-dot {
            width: 8px;
            height: 8px;
            border-radius: 50%;
            background: #0168E5;
        }

        .skip-dot {
            width: 8px;
            height: 8px;
            border-radius: 50%;
            background: #ef4444;
        }

        /* Leader Schedule Overlay (left side, above bottom) */
        #leaderScheduleOverlay {
            position: absolute;
            bottom: 20px;
            left: 20px;
            width: 320px;
            background: rgba(9, 9, 11, 0.7);
            border: 1px solid var(--border);
            border-radius: var(--radius-lg);
            z-index: 1000;
            overflow: visible;
        }

        .leader-schedule-header {
            font-size: 11px;
            color: var(--text-helper);
            text-transform: uppercase;
            letter-spacing: 0.5px;
            padding: 10px 14px;
            border-bottom: 1px solid var(--border);
        }

        #leaderScheduleTable {
            width: 100%;
            border-collapse: collapse;
            font-size: 12px;
            display: block;
        }

        #leaderScheduleTable thead,
        #leaderScheduleTable tbody {
            display: block;
        }

        #leaderScheduleTable tbody {
            max-height: none;
            overflow-y: visible;
        }

        #leaderScheduleTable tbody tr:last-child td {
            padding-bottom: 10px;
        }

        #leaderScheduleTable tr {
            display: table;
            width: 100%;
            table-layout: fixed;
        }

        /* Column widths: Slot (narrow), Leader (wide), Time (narrow) */
        #leaderScheduleTable th:nth-child(1),
        #leaderScheduleTable td:nth-child(1) {
            width: 70px;
        }
        #leaderScheduleTable th:nth-child(2),
        #leaderScheduleTable td:nth-child(2) {
            width: 150px;
        }
        #leaderScheduleTable th:nth-child(3),
        #leaderScheduleTable td:nth-child(3) {
            width: 90px;
            text-align: right;
            white-space: nowrap;
        }

        #leaderScheduleTable td.no-data {
            color: var(--text-secondary);
        }

        #leaderScheduleTable thead th {
            padding: 8px 12px;
            text-align: left;
            font-weight: 500;
            color: var(--text-helper);
            border-bottom: 1px solid var(--border);
        }

        #leaderScheduleTable tbody td {
            padding: 6px 12px;
            color: var(--text-secondary);
            border-bottom: 1px solid rgba(255, 255, 255, 0.03);
        }

        #leaderScheduleTable tbody tr:hover {
            background: rgba(255, 255, 255, 0.03);
        }

        #leaderScheduleTable tbody tr.current-slot td {
            color: var(--text-primary);
            font-weight: 600;
        }

        #leaderScheduleTable .leader-cell {
            display: flex;
            align-items: center;
            gap: 6px;
        }

        #leaderScheduleTable .leader-icon {
            width: 18px;
            height: 18px;
            border-radius: 50%;
            background-color: #000;
            background-size: cover;
            background-position: center;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 10px;
            font-weight: 600;
            color: #fff;
        }

        #leaderScheduleTable .leader-name {
            max-width: 200px;
            overflow: hidden;
            text-overflow: ellipsis;
            white-space: nowrap;
        }

        .leaflet-container {
            background: #111934 !important;
            border-radius: 0;
        }

        .leaflet-control-attribution {
            display: none !important;
        }

        /* Leaflet popup styling to match dark theme */
        .leaflet-popup-content-wrapper {
            background: rgba(9, 9, 11, 0.9);
            border: 1px solid var(--border);
            border-radius: var(--radius-lg);
            color: var(--text-primary);
            box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
        }

        .leaflet-popup-content {
            margin: 12px 14px;
            font-family: var(--font-sans);
        }

        .leaflet-popup-tip {
            background: rgba(9, 9, 11, 0.9);
            border: 1px solid var(--border);
            box-shadow: none;
        }

        .leaflet-popup-close-button {
            color: var(--text-secondary) !important;
            font-size: 18px !important;
            padding: 6px 8px 0 0 !important;
        }

        .leaflet-popup-close-button:hover {
            color: var(--text-primary) !important;
        }

        /* Leader popup - must be above zoom controls */
        .leader-popup {
            z-index: 100000 !important;
        }

        .leaflet-pane.leaflet-popup-pane {
            z-index: 100000 !important;
        }

        .leader-popup .leaflet-popup-content-wrapper {
            border: 1px solid var(--border);
            background: rgba(9, 9, 11, 0.95);
            width: auto;
        }

        .leader-popup .leaflet-popup-content {
            white-space: nowrap;
            width: auto !important;
            max-width: none !important;
            margin: 8px 12px;
        }

        .leader-popup .leaflet-popup-tip {
            background: rgba(9, 9, 11, 0.95);
        }

        .validator-marker {
            background: rgba(1, 104, 229, 0.25);
            border: 1px solid #0168E5;
            border-radius: 50%;
            width: 12px;
            height: 12px;
        }

        /* Cluster count label - centers text on marker */
        .cluster-count-label {
            display: flex;
            align-items: center;
            justify-content: center;
            background: transparent !important;
            border: none !important;
        }

        /* Leaflet.markercluster custom styling - blue theme */
        .marker-cluster {
            background: rgba(1, 104, 229, 0.6) !important;
            border: 2px solid #0185FF !important;
        }
        .marker-cluster div {
            background: rgba(1, 104, 229, 0.9) !important;
            color: white !important;
            font-weight: 700 !important;
            font-family: var(--font-sans) !important;
        }
        .marker-cluster-small {
            background: rgba(1, 104, 229, 0.6) !important;
        }
        .marker-cluster-small div {
            background: rgba(1, 104, 229, 0.9) !important;
        }
        .marker-cluster-medium {
            background: rgba(1, 104, 229, 0.6) !important;
        }
        .marker-cluster-medium div {
            background: rgba(1, 104, 229, 0.9) !important;
        }
        .marker-cluster-large {
            background: rgba(1, 104, 229, 0.6) !important;
        }
        .marker-cluster-large div {
            background: rgba(1, 104, 229, 0.9) !important;
        }

        .leader-marker {
            background: var(--color-warning);
            border: 2px solid #FFE55C;
            animation: pulse-leader 2s ease-in-out infinite;
        }

        @keyframes pulse-leader {
            0%, 100% { transform: scale(1); opacity: 1; }
            50% { transform: scale(1.3); opacity: 0.8; }
        }

        #validatorTable {
            width: 100%;
            border-collapse: collapse;
            border-spacing: 0;
        }


        #validatorTable th {
            background: var(--bg-item);
            color: var(--text-secondary);
            padding: 12px;
            text-align: left;
            font-size: 12px;
            font-weight: 400;
            border-bottom: 1px solid var(--border);
            cursor: pointer;
            user-select: none;
        }

        #validatorTable th:hover {
            background: var(--bg-card);
            color: var(--accent);
        }

        /* Category header row - no hover effect */
        #validatorTable .category-header th {
            background: var(--bg-app);
            color: var(--accent);
            font-size: 11px;
            font-weight: 700;
            text-transform: uppercase;
            letter-spacing: 1px;
            padding: 10px 14px;
            border-bottom: none; /* Override base th border */
            text-align: center;
            cursor: default;
            user-select: none;
        }

        #validatorTable .category-header th:hover {
            background: var(--bg-app); /* No hover effect - keep same as base */
        }

        #validatorTable .category-header th:not(:first-child) {
            border-left: 1px solid var(--border-light);
        }

        /* Column header row (second row) - blue line on bottom using inset shadow (not border - borders break with sticky + border-collapse) */
        #validatorTable thead tr:not(.category-header) th {
            box-shadow: inset 0 -2px 0 var(--accent);
        }

        .cat-arrow {
            font-size: 10px;
            margin-left: 4px;
            display: inline-block;
            transition: transform var(--transition-fast);
        }

        .cat-toggle.expanded .cat-arrow {
            transform: rotate(180deg);
        }

        /* Hidden columns */
        .hidden {
            display: none !important;
        }

        #validatorTable td {
            padding: 10px 12px;
            border-bottom: 1px solid var(--border-subtle);
            font-size: 13px;
            font-weight: 400;
        }

        #validatorTable tr:hover {
            background: var(--bg-item);
        }

        .val-name {
            font-weight: 500;
            color: var(--text-primary);
            overflow: hidden;
            text-overflow: ellipsis;
            white-space: nowrap;
        }

        .val-pubkey {
            font-family: 'Courier New', monospace;
            font-size: 12px;
            color: var(--text-helper);
        }

        .val-stake {
            color: var(--text-primary);
            font-weight: 400;
        }

        .val-performance {
            font-weight: 400;
        }

        .val-performance.good {
            color: #10b981;
        }

        .val-performance.warning {
            color: var(--color-warning);
        }

        .val-performance.poor {
            color: var(--color-error);
        }

        .val-icon {
            width: 32px;
            height: 32px;
            border-radius: 50%;
            margin-right: 8px;
            vertical-align: middle;
            object-fit: cover;
            background: var(--bg-item);
        }

        .val-icon-placeholder {
            width: 32px;
            height: 32px;
            border-radius: 50%;
            margin-right: 8px;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            background: var(--accent);
            color: white;
            font-size: 11px;
            font-weight: 700;
            vertical-align: middle;
        }

        .val-identity {
            display: flex;
            align-items: center;
            gap: 8px;
        }

        .val-identity-main {
            flex: 1;
            min-width: 0;
        }

        .val-actions {
            display: flex;
            gap: 6px;
            opacity: 0.6;
            transition: opacity var(--transition-fast);
        }

        #validatorTable tr:hover .val-actions {
            opacity: 1;
        }

        .val-action-btn {
            cursor: pointer;
            padding: 4px;
            border-radius: var(--radius-sm);
            transition: all var(--transition-fast);
            font-size: 12px;
        }

        .val-action-btn:hover {
            background: var(--bg-item);
            color: var(--accent);
        }

        .val-status {
            display: inline-flex;
            align-items: center;
            gap: 6px;
        }

        .val-status-dot {
            width: 8px;
            height: 8px;
            border-radius: 50%;
        }

        .val-status-dot.online {
            background: var(--color-success);
            box-shadow: 0 0 6px var(--color-success);
        }

        .val-status-dot.delinquent {
            background: var(--color-error);
            box-shadow: 0 0 6px var(--color-error);
            animation: pulse-status 1.5s infinite;
        }

        @keyframes pulse-status {
            0%, 100% { opacity: 1; }
            50% { opacity: 0.4; }
        }

        .country-flag {
            font-size: 26px;
            line-height: 1;
            display: block;
            text-align: center;
        }

        /* Use flag images instead of emoji for better display */
        .flag-img {
            width: 26px;
            height: 19px;
            border-radius: 2px;
            object-fit: cover;
        }

        /* Table layout */
        #validatorTable {
            width: 100%;
            table-layout: auto;
        }

        #validatorTable th, #validatorTable td {
            white-space: nowrap;
        }

        /* Clickable cells for dropdown */
        .cell-clickable {
            cursor: pointer;
            position: relative;
            padding-right: 28px !important;
        }

        .cell-clickable:hover {
            background: var(--bg-card);
        }

        .cell-clickable .expand-arrow {
            display: inline-block;
            width: 0;
            height: 0;
            border-top: 5px solid transparent;
            border-bottom: 5px solid transparent;
            border-right: 6px solid var(--text-helper);
            opacity: 0.6;
            transition: transform var(--transition-fast), border-color var(--transition-fast);
            position: absolute;
            right: 10px;
            top: 50%;
            transform: translateY(-50%);
        }

        .cell-clickable:hover .expand-arrow {
            opacity: 1;
            border-right-color: var(--accent);
        }

        .cell-clickable.open .expand-arrow {
            transform: translateY(-50%) rotate(-90deg);
            border-right-color: var(--accent);
            opacity: 1;
        }

        /* Flag cell - 80% of cell, centered */
        .flag-cell {
            padding: 4px !important;
            text-align: center;
            vertical-align: middle;
            height: 40px;
        }

        .flag-cell img {
            width: 32px;
            height: 32px;
            object-fit: contain;
            display: block;
            margin: 0 auto;
        }

        /* Table styling for 16 columns */
        #validatorTable th, #validatorTable td {
            padding: 8px 10px;
            font-size: 13px;
        }

        #validatorTable th {
            font-size: 12px;
        }

        /* Validator column - reduce width */
        #validatorTable th:first-child,
        #validatorTable td:first-child {
            min-width: 140px;
            max-width: 180px;
        }

        /* Expand row for category details */
        .expand-row {
            display: none;
            background: var(--bg-item) !important;
        }

        .expand-row.visible {
            display: table-row;
        }

        .expand-row td {
            padding: 12px 16px;
            border-bottom: 2px solid var(--accent);
            border-left: 3px solid var(--accent);
        }

        .expand-content {
            display: flex;
            flex-wrap: wrap;
            gap: 20px;
        }

        .expand-item {
            display: flex;
            flex-direction: column;
            gap: 4px;
            min-width: 160px;
        }

        .expand-label {
            font-size: 13px;
            color: var(--text-helper);
            text-transform: uppercase;
            letter-spacing: 0.5px;
        }

        .expand-value {
            font-size: 13px;
            color: var(--text-primary);
            font-weight: 500;
        }

        .expand-value a {
            color: var(--accent);
        }

        .expand-value.clickable {
            cursor: pointer;
        }

        .expand-value.clickable:hover {
            color: var(--accent);
        }

        .expand-cat-title {
            font-size: 14px;
            font-weight: 700;
            color: var(--accent);
            text-transform: uppercase;
            letter-spacing: 1px;
            margin-bottom: 8px;
        }

        /* Toast notification */
        .toast {
            position: fixed;
            bottom: 24px;
            left: 50%;
            transform: translateX(-50%) translateY(100px);
            background: var(--bg-item);
            color: var(--text-primary);
            padding: 12px 24px;
            border-radius: var(--radius-lg);
            border: 1px solid var(--border-light);
            font-size: 14px;
            z-index: 9999;
            opacity: 0;
            transition: all var(--transition-medium);
        }

        .toast.visible {
            transform: translateX(-50%) translateY(0);
            opacity: 1;
        }

        /* Row number column */
        .row-num {
            color: var(--text-helper);
            font-size: 12px;
        }

        /* Sort indicator */
        .sort-indicator {
            margin-left: 4px;
            font-size: 10px;
        }

        /* Table wrapper - no overflow to allow sticky to work with page scroll */
        .table-scroll-container {
            /* No height constraint - table scrolls with page */
        }

        /* Sticky header rows */
        #validatorTable thead {
            position: sticky;
            top: 0;
            z-index: 100;
            background: var(--bg-app);
        }

        #validatorTable thead tr.category-header th {
            background: var(--bg-app);
        }

        #validatorTable thead tr:not(.category-header) th {
            background: var(--bg-app);
            box-shadow: inset 0 -2px 0 var(--accent); /* Blue line on bottom - inset shadow works with sticky */
        }

        /* Category separator lines - vertical borders between categories */
        /* Network starts at column 3 (after Validator cols 1-2) */
        #validatorTable th:nth-child(3),
        #validatorTable td:nth-child(3) {
            border-left: 1px solid var(--border-light);
        }

        /* Stake starts at column 6 (after Network cols 3-5) */
        #validatorTable th:nth-child(6),
        #validatorTable td:nth-child(6) {
            border-left: 1px solid var(--border-light);
        }

        /* Performance starts at column 9 (after Stake cols 6-8) */
        #validatorTable th:nth-child(9),
        #validatorTable td:nth-child(9) {
            border-left: 1px solid var(--border-light);
        }

        /* Rewards columns removed in DEPLOY294 — no column 15+ border needed */

        /* Dropdown arrow positioning - at end of category */
        .cat-end-arrow {
            font-size: 8px;
            color: var(--text-helper);
            margin-left: 4px;
            opacity: 0.5;
            cursor: pointer;
        }

        .cat-end-arrow:hover {
            opacity: 1;
            color: var(--accent);
        }

        /* Responsive dropdown content - shrink with window */
        .expand-content {
            display: flex;
            flex-wrap: wrap;
            gap: 16px;
            width: 100%;
        }

        .expand-content > div {
            flex: 1 1 auto;
            min-width: 0;
        }

        /* Stake breakdown responsive grid - 4 columns */
        .stake-grid-responsive {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
            gap: 8px;
            width: 100%;
        }

        /* Fix stake breakdown box padding - minimal */
        .stake-breakdown-box {
            background: var(--bg-card);
            padding: 8px 10px;
            border-radius: 6px;
        }

        .stake-breakdown-box .account-list {
            margin-top: 4px;
        }

        .stake-breakdown-box .account-item {
            background: var(--bg-item);
            padding: 4px 6px;
            border-radius: 4px;
            margin-bottom: 3px;
            font-size: 12px;
            font-family: monospace;
        }

        .stake-breakdown-box .account-item:last-child {
            margin-bottom: 0;
        }

        .stake-breakdown-box .account-item a {
            font-size: 11px;
        }

        .stake-breakdown-box .account-item div {
            font-size: 12px;
        }

        /* Chart container in dropdown */
        .dropdown-chart-container {
            background: var(--bg-card);
            padding: 10px;
            border-radius: 8px;
            margin-top: 10px;
        }

        .dropdown-chart-container > div:first-child {
            font-size: 12px;
            color: var(--text-helper);
            margin-bottom: 6px;
        }

        .dropdown-chart-container canvas {
            width: 100% !important;
            height: 100% !important;
        }

        /* Mobile search - hidden on desktop */
        #mobileSearchBar {
            display: none;
        }

        /* Mobile search icon and popup - hidden on desktop */
        #mobileSearchIcon,
        #mobileSearchPopup {
            display: none;
        }

        /* Mobile Responsive - 768px breakpoint matches navbar/appbar */
        @media (max-width: 768px) {
            /* Remove padding/frame on mobile - edge to edge */
            .max-w-7xl {
                padding: 0 !important;
                max-width: 100% !important;
            }

            /* Remove desktop min-width constraints */
            body {
                min-width: 100%;
                overflow-x: hidden;
            }

            #networkView {
                min-width: 100%;
                margin: 0;
                padding: 0;
                width: 100%;
            }

            #networkView > section:first-child,
            #networkView > section:nth-child(2) {
                min-width: 100%;
                width: 100%;
            }

            /* Map - 40vh to leave room for table */
            #networkMapWrapper,
            #networkMap {
                height: calc(40vh - 40px);
                min-height: 250px;
                min-width: 100% !important;
                width: 100% !important;
            }

            /* Hide complex overlays - too cluttered on mobile */
            #leaderScheduleOverlay,
            #blockProductionOverlay,
            #mapOverlayTitle,
            /* Hide desktop search on mobile */
            #mapSearchOverlay {
                display: none;
            }

            /* Mobile search bar - between map and table */
            #mobileSearchBar {
                display: block !important;
                padding: 12px 16px;
                background: #09090B !important;
            }

            #mobileSearchBar input {
                width: 100% !important;
                background: rgba(9, 9, 11, 0.7) !important;
                border: 1px solid #2A2D32 !important;
                border-radius: 8px !important;
                color: #FFFFFF !important;
                padding: 12px 16px !important;
                font-size: 16px !important;
                -webkit-appearance: none;
                appearance: none;
            }

            #mobileSearchBar input::placeholder {
                color: #71717A !important;
            }

            #mobileSearchBar input:focus {
                border-color: #0168E5 !important;
                outline: none !important;
            }

            /* Current Leader - compact, bottom left */
            #currentLeaderOverlay {
                left: 10px;
                bottom: 10px;
                width: auto;
                max-width: 180px;
                padding: 8px 10px;
            }

            .current-leader-title {
                font-size: 9px;
                margin-bottom: 6px;
            }

            .current-leader-main {
                gap: 8px;
            }

            .current-leader-icon,
            .current-leader-icon-placeholder {
                width: 28px;
                height: 28px;
                font-size: 12px;
            }

            .current-leader-name {
                font-size: 11px;
            }

            .current-leader-slot {
                font-size: 9px;
            }

            .slot-bars {
                margin-bottom: 0;
                gap: 3px;
            }

            .slot-bar {
                height: 5px;
            }

            .upcoming-leaders {
                display: none;
            }

            /* Legend - width synced to metrics via JS */
            #mapOverlayLegend {
                top: 10px;
                right: 10px;
                left: auto !important;
                padding: 5px 8px;
                font-size: 9px;
                white-space: nowrap;
                justify-content: space-evenly;
                box-sizing: border-box;
            }

            .legend-item {
                gap: 4px;
            }

            .validator-marker {
                width: 6px;
                height: 6px;
            }

            /* Metrics - below legend */
            #mapMetrics {
                top: auto;
                bottom: 10px;
                right: 10px;
                padding: 5px 8px;
                font-size: 9px;
            }

            #mapMetrics .metrics-title {
                font-size: 8px;
                margin-bottom: 3px;
            }

            #mapMetrics .metric-row {
                gap: 8px;
                margin-bottom: 1px;
            }

            /* Table - scrollable container for virtual scrolling */
            .table-scroll-container {
                overflow-x: auto;
                overflow-y: auto;
                height: calc(100vh - 380px);
                -webkit-overflow-scrolling: touch;
                width: 100%;
            }

            #validatorTable th,
            #validatorTable td {
                padding: 6px 4px;
                font-size: 10px;
            }

            /* Hide tooltips on mobile — no hover on touch devices,
               and position:absolute tooltips inflate scrollWidth
               causing a black column gap after the last column */
            #validatorTable .info-tooltip {
                display: none !important;
            }

            /* Fixed row height for virtual scrolling calculations */
            #validatorTable tbody tr[data-index] {
                height: 44px;
                max-height: 44px;
                box-sizing: border-box;
            }

            /* Virtual scroll spacer rows */
            #validatorTable tbody tr.virtual-spacer td {
                padding: 0;
                border: none;
            }

            .category-header th {
                font-size: 8px;
                padding: 5px 4px;
            }

            /* Disable sticky header on mobile - conflicts with scroll container */
            #validatorTable thead {
                position: static;
            }

            /* Prevent iOS zoom on input focus */
            input, select, textarea {
                font-size: 16px;
            }

            /* Hide the old mobile search bar */
            #mobileSearchBar {
                display: none !important;
            }

            /* Mobile Search Icon - centered at bottom of map */
            #mobileSearchIcon {
                display: flex;
                position: absolute;
                bottom: 10px;
                left: 50%;
                transform: translateX(-50%);
                z-index: 1001;
                background: rgba(9, 9, 11, 0.85);
                border: 1px solid #2A2D32;
                border-radius: 50%;
                width: 40px;
                height: 40px;
                align-items: center;
                justify-content: center;
                cursor: pointer;
                color: #FFFFFF;
                backdrop-filter: blur(8px);
            }

            #mobileSearchIcon:active {
                background: rgba(1, 104, 229, 0.5);
            }

            /* Mobile Search Popup */
            #mobileSearchPopup {
                display: block;
                position: fixed;
                top: 0;
                left: 0;
                right: 0;
                bottom: 0;
                z-index: 9999;
            }

            #mobileSearchPopup.hidden {
                display: none !important;
            }

            #mobileSearchBackdrop {
                position: absolute;
                top: 0;
                left: 0;
                right: 0;
                bottom: 0;
                background: rgba(0, 0, 0, 0.6);
            }

            #mobileSearchContainer {
                position: absolute;
                top: 50%;
                left: 50%;
                transform: translate(-50%, -50%);
                width: 90%;
                max-width: 400px;
            }

            #mobileValidatorSearch {
                width: 100%;
                background: #000000;
                color: #FFFFFF;
                font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
                font-size: 16px;
                border: 1px solid #2A2D32;
                border-radius: 8px;
                padding: 12px 16px;
                outline: none;
            }

            #mobileValidatorSearch::placeholder {
                color: #6B7280;
            }

            #mobileValidatorSearch:focus {
                border-color: #0168E5;
            }
        }

        /* Landscape mobile (phone rotated) - NO max-width to cover all phone sizes */
        @media (max-height: 500px) and (orientation: landscape) {
            /* HIGHEST SPECIFICITY: Target main container by ID */
            #mainContainer {
                max-width: none !important;
                width: 100% !important;
                margin: 0 !important;
                padding: 0 !important;
            }

            /* Override ALL Tailwind utility classes that cause black bars */
            .max-w-7xl,
            .mx-auto,
            .px-4,
            .py-4,
            [class*="px-"],
            [class*="py-"] {
                padding: 0 !important;
                padding-left: 0 !important;
                padding-right: 0 !important;
                padding-top: 0 !important;
                padding-bottom: 0 !important;
                margin: 0 !important;
                margin-left: 0 !important;
                margin-right: 0 !important;
                max-width: none !important;
                width: 100% !important;
            }

            /* Force body full width - MUST use 0 to break the 1200px base rule */
            body {
                min-width: 0 !important;
                max-width: 100vw !important;
                width: 100vw !important;
                overflow-x: hidden !important;
                margin: 0 !important;
                padding: 0 !important;
            }

            /* Force html full width */
            html {
                min-width: 0 !important;
                max-width: 100vw !important;
                width: 100vw !important;
                overflow-x: hidden !important;
                margin: 0 !important;
                padding: 0 !important;
            }

            /* Network view container */
            #networkView {
                min-width: 100% !important;
                width: 100% !important;
                margin: 0 !important;
                padding: 0 !important;
            }

            #networkView > section {
                min-width: 100% !important;
                width: 100% !important;
                margin: 0 !important;
                padding: 0 !important;
            }

            /* Map container */
            #networkMapWrapper,
            #networkMap {
                min-width: 100% !important;
                width: 100% !important;
            }

            /* Table container - full width, horizontal scroll */
            .table-scroll-container {
                overflow-x: auto !important;
                width: 100% !important;
                margin: 0 !important;
                padding: 0 !important;
            }

            #validatorTable {
                width: 100%;
            }

            /* Current Leader - BOTTOM LEFT */
            #currentLeaderOverlay {
                left: 10px !important;
                bottom: 10px !important;
                max-width: 180px;
                padding: 8px 10px !important;
            }

            /* Map Metrics - BOTTOM RIGHT */
            #mapMetrics {
                top: auto !important;
                bottom: 10px !important;
                right: 10px !important;
                padding: 5px 8px !important;
                font-size: 9px !important;
            }

            /* Legend - width synced to metrics via JS */
            #mapOverlayLegend {
                top: 10px !important;
                right: 10px !important;
                left: auto !important;
                padding: 4px 6px !important;
                font-size: 8px !important;
                white-space: nowrap !important;
                justify-content: space-evenly !important;
                box-sizing: border-box !important;
            }

            #mapOverlayLegend .legend-item {
                gap: 4px !important;
            }

            #mapOverlayLegend .validator-marker {
                width: 8px !important;
                height: 8px !important;
            }

            /* Hide complex overlays - too cluttered on landscape mobile */
            #leaderScheduleOverlay,
            #blockProductionOverlay,
            #mapOverlayTitle,
            #mapSearchOverlay {
                display: none !important;
            }

            /* Show mobile search icon in landscape too */
            #mobileSearchIcon {
                display: flex !important;
                position: absolute;
                bottom: 10px;
                left: 50%;
                transform: translateX(-50%);
                z-index: 1001;
                background: rgba(9, 9, 11, 0.85);
                border: 1px solid #2A2D32;
                border-radius: 50%;
                width: 40px;
                height: 40px;
                align-items: center;
                justify-content: center;
                cursor: pointer;
                color: #FFFFFF;
            }

            /* Map takes more width in landscape */
            #networkMapWrapper,
            #networkMap {
                height: 60vh;
                min-height: 200px;
            }

            /* Compact current leader for landscape */
            #currentLeaderOverlay {
                max-width: 200px;
                padding: 8px 10px;
            }

            .current-leader-title {
                font-size: 9px;
            }

            .current-leader-icon,
            .current-leader-icon-placeholder {
                width: 28px;
                height: 28px;
            }

            .current-leader-name {
                font-size: 11px;
            }

            .upcoming-leaders {
                display: none;
            }

            /* Compact metrics for landscape */
            #mapMetrics {
                padding: 5px 8px;
                font-size: 9px;
            }

            /* Mobile Search Popup - landscape */
            #mobileSearchPopup {
                display: block;
                position: fixed;
                top: 0;
                left: 0;
                right: 0;
                bottom: 0;
                z-index: 9999;
            }

            #mobileSearchPopup.hidden {
                display: none !important;
            }

            #mobileSearchBackdrop {
                position: absolute;
                top: 0;
                left: 0;
                right: 0;
                bottom: 0;
                background: rgba(0, 0, 0, 0.6);
            }

            #mobileSearchContainer {
                position: absolute;
                top: 50%;
                left: 50%;
                transform: translate(-50%, -50%);
                width: 70%;
                max-width: 500px;
            }

            #mobileValidatorSearch {
                width: 100%;
                background: #000000;
                color: #FFFFFF;
                font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
                font-size: 16px;
                border: 1px solid #2A2D32;
                border-radius: 8px;
                padding: 12px 16px;
                outline: none;
            }

            #mobileValidatorSearch::placeholder {
                color: #6B7280;
            }

            #mobileValidatorSearch:focus {
                border-color: #0168E5;
            }
        }


        /* Landscape mode overrides (JS toggles these classes on mobile landscape) */
        html.landscape-mode,
        body.landscape-mode {
            min-width: 0 !important;
            max-width: 100vw !important;
            width: 100vw !important;
            overflow-x: hidden !important;
            margin: 0 !important;
            padding: 0 !important;
        }
        .landscape-container {
            max-width: none !important;
            width: 100% !important;
            margin: 0 !important;
            padding: 0 !important;
        }

