
        /* ============================================================
           HUD THEME – full copy with updated row layout
           ============================================================ */
        :root {
            --hud-green: #58ffcf;
            --hud-highlight: #74ffd6;
            --hud-dark: #050505;
            --hud-bg-card: rgba(0, 0, 0, 0.75);
            --gold: #ffd700;
            --silver: #c0c0c0;
            --bronze: #cd7f32;
        }

        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }

        a {
            color: var(--hud-green);
            text-decoration: none !important;
            transition: 0.3s ease;
        }
        a:hover {
            color: var(--hud-highlight);
            text-shadow: 0 0 10px rgba(88, 255, 207, 0.6), 0 0 20px rgba(88, 255, 207, 0.3);
        }

        body {
            background: #000;
            overflow-x: hidden;
            font-family: 'Orbitron', sans-serif;
            min-height: 100vh;
        }

        .menu-screen {
            position: relative;
            width: 100vw;
            min-height: 100vh;
            overflow: hidden;
            padding: 12px;
        }

        .background-image {
            position: fixed;
            top: 12px;
            left: 12px;
            right: 12px;
            bottom: 12px;
            background: url("../imgs/background2.png");
            background-size: cover;
            background-position: center;
            background-repeat: no-repeat;
            z-index: 0;
        }
        .background-overlay {
            position: fixed;
            top: 12px;
            left: 12px;
            right: 12px;
            bottom: 12px;
            background: rgba(0, 0, 0, 0.55);
            z-index: 1;
        }
        .viewport-frame {
            position: fixed;
            inset: 12px;
            border: 1px solid rgba(88, 255, 207, 0.15);
            pointer-events: none;
            z-index: 2;
        }
        .viewport-frame::before {
            content: "";
            position: absolute;
            top: 0;
            left: 0;
            width: 120px;
            height: 40px;
            border-top: 2px solid rgba(88, 255, 207, 0.4);
            border-left: 2px solid rgba(88, 255, 207, 0.4);
        }
        .viewport-frame::after {
            content: "";
            position: absolute;
            bottom: 0;
            right: 0;
            width: 120px;
            height: 40px;
            border-bottom: 2px solid rgba(88, 255, 207, 0.4);
            border-right: 2px solid rgba(88, 255, 207, 0.4);
        }
        .scanlines {
            position: fixed;
            top: 12px;
            left: 12px;
            right: 12px;
            bottom: 12px;
            background: repeating-linear-gradient(180deg,
                    transparent,
                    transparent 2px,
                    rgba(88, 255, 207, 0.015) 3px);
            pointer-events: none;
            z-index: 10;
        }

        .status-panel {
            position: fixed;
            top: 80px;
            right: 20px;
            text-align: right;
            color: var(--hud-green);
            font-size: 11px;
            letter-spacing: 1px;
            opacity: 0.75;
            z-index: 100;
            line-height: 1.6;
        }

        .main-content {
            position: relative;
            z-index: 5;
            padding: 20px 30px 30px 30px;
            max-width: 1400px;
            margin: 0 auto;
            min-height: 100vh;
            margin-top: 20px;
        }

        .leaderboard-header {
            display: flex;
            justify-content: space-between;
            align-items: flex-start;
            flex-wrap: wrap;
            margin-bottom: 25px;
            padding-bottom: 15px;
            border-bottom: 1px solid rgba(88, 255, 207, 0.15);
        }
        .leaderboard-header h1 {
            font-size: 22px;
            font-weight: 700;
            color: var(--hud-highlight);
            letter-spacing: 3px;
            text-transform: uppercase;
            margin: 0;
            text-shadow: 0 0 30px rgba(88, 255, 207, 0.15);
        }
        .leaderboard-header h1 small {
            font-size: 14px;
            font-weight: 400;
            opacity: 0.6;
            letter-spacing: 1px;
            margin-left: 12px;
            text-transform: none;
        }
        .leaderboard-header .back-link {
            font-size: 12px;
            letter-spacing: 1px;
            padding: 8px 18px;
            border: 1px solid rgba(88, 255, 207, 0.3);
            transition: 0.3s ease;
            background: rgba(0, 0, 0, 0.5);
        }
        .leaderboard-header .back-link:hover {
            background: rgba(88, 255, 207, 0.1);
            border-color: var(--hud-highlight);
            transform: translateX(-4px);
        }
        .subtitle-display {
            color: rgba(88, 255, 207, 0.5);
            font-size: 13px;
            letter-spacing: 1px;
            margin-top: 6px;
            font-weight: 400;
        }
        .subtitle-display strong {
            color: var(--hud-green);
            font-weight: 500;
        }


        /* ============================================================
           FORCE UCP ELEMENTS TO BE FIXED ON ALL SCREENS
           ============================================================ */

        /* 1. Player HUD – fixed top-left */
        .player-hud {
            position: fixed !important;
            top: 20px !important;
            left: 20px !important;
            z-index: 9999 !important;
            background: rgba(0, 0, 0, 0.85);
            border-color: var(--hud-green);
            box-shadow: 0 0 20px rgba(0, 0, 0, 0.8);
        }

        /* 2. Logout button – fixed top-right */
        .logout-container {
            position: fixed !important;
            top: 20px !important;
            right: 20px !important;
            z-index: 9999 !important;
        }

        /* 3. Submit Score button – fixed below the HUD */
        .submit-score-btn {
            position: fixed !important;
            top: 74px !important;   /* adjust if your HUD height is different */
            left: 100px !important; /* aligns with your existing layout */
            z-index: 9998 !important;
            margin-left: 0 !important;
        }

        /* If live badge is present, shift it accordingly */
        .submit-score-btn.live-active {
            margin-left: 190px !important; /* keep the original shift */
        }

        /* 4. Add top padding to main content so it doesn't hide under fixed elements */
        .main-content {
            padding-top: 120px !important; /* adjust to match the total height of HUD + button */
        }

        /* 5. Optional: adjust on very small screens */
        @media (max-width: 768px) {
            .player-hud {
                top: 8px !important;
                left: 8px !important;
                height: 40px;
            }
            .logout-container {
                top: 8px !important;
                right: 8px !important;
            }
            .submit-score-btn {
                top: 50px !important;
                left: 8px !important;
                width: 240px;
            }
            .submit-score-btn.live-active {
                margin-left: 30px !important; /* or as needed */
            }
            .main-content {
                padding-top: 90px !important;
            }
        }


        /* ============================================================
           FILTERS – THREE SEPARATE BOXES (unchanged)
           ============================================================ */
        .filters-panel {
            display: flex;
            flex-direction: column;
            gap: 14px;
            margin-bottom: 25px;
        }

        .filter-row-top {
            display: flex;
            flex-wrap: wrap;
            gap: 14px;
            align-items: stretch;
        }

        .dropdown-box {
            flex: 1 1 auto;
            display: flex;
            flex-wrap: wrap;
            gap: 12px 18px;
            background: rgba(0, 0, 0, 0.7);
            border: 1px solid rgba(88, 255, 207, 0.15);
            padding: 14px 16px;
            align-items: stretch;
        }
        .dropdown-box .filter-group {
            flex: 1 1 140px;
            display: flex;
            flex-direction: column;
            gap: 4px;
            min-width: 120px;
        }
        .dropdown-box .filter-group label {
            font-size: 9px;
            text-transform: uppercase;
            letter-spacing: 2px;
            color: rgba(88, 255, 207, 0.4);
            font-weight: 500;
        }
        .dropdown-box select {
            background: rgba(0, 0, 0, 0.8);
            border: 1px solid rgba(88, 255, 207, 0.2);
            color: var(--hud-green);
            font-family: 'Orbitron', sans-serif;
            font-size: 10px;
            padding: 8px 12px;
            letter-spacing: 0.5px;
            transition: 0.25s ease;
            cursor: pointer;
            outline: none;
            appearance: none;
            -webkit-appearance: none;
            border-radius: 0;
            width: 100%;
        }
        .dropdown-box select:hover,
        .dropdown-box select:focus {
            border-color: var(--hud-highlight);
            box-shadow: 0 0 20px rgba(88, 255, 207, 0.06);
        }
        .dropdown-box select option {
            background: #111;
            color: #ccc;
            font-family: 'Segoe UI', sans-serif;
            font-size: 11px;
        }

        .difficulty-box {
            flex: 0 0 auto;
            display: flex;
            flex-direction: column;
            gap: 6px;
            background: rgba(0, 0, 0, 0.7);
            border: 1px solid rgba(88, 255, 207, 0.15);
            padding: 16px 20px;
            min-width: 400px;
            justify-content: center;
        }
        .difficulty-box .filter-label {
            font-size: 9px;
            text-transform: uppercase;
            letter-spacing: 2px;
            color: rgba(88, 255, 207, 0.4);
            font-weight: 500;
            text-align: center;
            margin-bottom: 4px;
        }
        .difficulty-box .filter-btn {
            background: rgba(0,0,0,0.6);
            border: 1px solid rgba(88,255,207,0.15);
            color: var(--hud-green);
            font-family: 'Orbitron', sans-serif;
            font-size: 9px;
            padding: 4px 8px;
            letter-spacing: 0.5px;
            transition: 0.25s ease;
            cursor: pointer;
            text-transform: uppercase;
            border-radius: 0;
            width: 100%;
            text-align: center;
        }
        .difficulty-box .filter-btn:hover {
            background: rgba(88,255,207,0.08);
            border-color: var(--hud-highlight);
        }
        .difficulty-box .filter-btn.active {
            background: var(--hud-green);
            border-color: var(--hud-green);
            color: #00140e;
            font-weight: 700;
            box-shadow: 0 0 20px rgba(88,255,207,0.15);
        }
        .difficulty-box .box-divider {
            width: 100%;
            height: 1px;
            background: rgba(88,255,207,0.1);
            margin: 6px 0;
        }
        .difficulty-box .single-life-row {
            display: flex;
            align-items: center;
            gap: 8px;
            justify-content: center;
            margin-top: 2px;
        }
        .difficulty-box .single-life-row .filter-label {
            font-size: 8px;
            text-transform: uppercase;
            letter-spacing: 1px;
            color: rgba(88,255,207,0.4);
            margin: 0;
        }
        .difficulty-box .single-life-row .filter-btn {
            width: auto;
            flex: 1 1 auto;
            font-size: 8px;
            padding: 3px 10px;
        }
        .difficulty-box .single-life-row .filter-btn.single-life-on {
            background: rgba(0,180,216,0.2);
            border-color: #00b4d8;
            color: #00b4d8;
        }
        .difficulty-box .single-life-row .filter-btn.single-life-off {
            background: rgba(0,0,0,0.6);
            border-color: rgba(88,255,207,0.15);
            color: var(--hud-green);
        }

        /* ------------------------------
           Current patch highlight (always visible)
        --------------------------------- */
        .filter-btn.current {
            /* optional: a subtle border or glow to indicate it's the recommended version */
            border: 2px solid #ffd700;        /* gold border */
            box-shadow: 0 0 8px rgba(255, 215, 0, 0.3);
            position: relative;
        }

        /* add a small "★" or "Current" badge if you like */
        .filter-btn.current::after {
            content: " ★";
            font-size: 0.7em;
            color: #ffd700;
        }

        /* ------------------------------
           Patch box: active current button = same as Combined
        --------------------------------- */
        .patch-box .filter-btn.current.active {
            background: var(--hud-green);          /* same as Combined active */
            color: #00140e;                        /* same as Combined active */
            border: 2px solid #ffd700;             /* keep gold border for "current" */
            box-shadow: 0 0 12px rgba(255, 215, 0, 0.6);
        }

        /* Optionally, if you want the badge to change color when active */
        .filter-btn.current.active::after {
            color: #fff;  /* or keep gold */
        }

        .filter-row-bottom {
            display: flex;
            flex-wrap: wrap;
            gap: 14px;
            width: 100%;
        }
        .patch-box {
            display: flex;
            align-items: center;
            gap: 6px;
            background: rgba(0, 0, 0, 0.7);
            border: 1px solid rgba(88, 255, 207, 0.15);
            padding: 8px 14px;
            flex: 1 1 100%;
            flex-wrap: wrap;
            width: 100%;
        }
        .patch-box .filter-label {
            font-size: 8px;
            text-transform: uppercase;
            letter-spacing: 2px;
            color: rgba(88,255,207,0.4);
            font-weight: 500;
            margin-right: 4px;
        }
        .patch-box .patch-left {
            display: flex;
            gap: 4px;
        }
        .patch-box .patch-right {
            display: flex;
            margin-left: auto;
        }
        .patch-box .filter-btn {
            background: rgba(0,0,0,0.6);
            border: 1px solid rgba(88,255,207,0.15);
            color: var(--hud-green);
            font-family: 'Orbitron', sans-serif;
            font-size: 8px;
            padding: 3px 8px;
            letter-spacing: 0.5px;
            transition: 0.25s ease;
            cursor: pointer;
            text-transform: uppercase;
            border-radius: 0;
        }
        .patch-box .filter-btn:hover {
            background: rgba(88,255,207,0.08);
            border-color: var(--hud-highlight);
        }
        .patch-box .filter-btn.active {
            background: var(--hud-green);
            border-color: var(--hud-green);
            color: #00140e;
            font-weight: 700;
            box-shadow: 0 0 20px rgba(88,255,207,0.15);
        }
        .patch-box .filter-btn.current {
            border-color: var(--hud-highlight);
            box-shadow: 0 0 20px rgba(88,255,207,0.2);
            background: rgba(88,255,207,0.05);
        }

        /* ============================================================
           LEADERBOARD ROWS – TWO-COLUMN LAYOUT
           ============================================================ */
        .leaderboard-container {
            animation: fadeSlideIn 0.5s ease forwards;
        }
        @keyframes fadeSlideIn {
            0% { opacity: 0; transform: translateY(18px); }
            100% { opacity: 1; transform: translateY(0); }
        }

        .leaderboard-empty {
            text-align: center;
            padding: 80px 20px;
            color: rgba(88, 255, 207, 0.2);
            font-size: 13px;
            letter-spacing: 2px;
            text-transform: uppercase;
            border: 1px dashed rgba(88, 255, 207, 0.08);
        }

        .record-row {
            display: flex;
            align-items: center;
            gap: 24px;
            padding: 20px 28px;
            margin-bottom: 14px;
            background: rgba(0, 0, 0, 0.7);
            border: 1px solid rgba(88, 255, 207, 0.15);
            transition: all 0.25s ease;
            cursor: pointer;
            position: relative;
            flex-wrap: wrap;
            border-radius: 0;
            overflow: visible;
            transform: scale(1);
        }

        .record-row:hover {
            transform: scale(1.01);
            background: rgba(0, 0, 0, 0.85);
            box-shadow: 0 0 40px rgba(88, 255, 207, 0.08), inset 0 0 20px rgba(88, 255, 207, 0.02);
            border-color: rgba(88, 255, 207, 0.3);
        }

        .record-row.one-place:hover {
            background: rgba(20, 15, 0, 0.9);
            box-shadow: 0 0 60px rgba(255, 215, 0, 0.15);
            border-color: rgba(255, 215, 0, 0.6);
        }
        .record-row.two-place:hover {
            background: rgba(20, 20, 20, 0.9);
            box-shadow: 0 0 50px rgba(192, 192, 192, 0.1);
            border-color: rgba(192, 192, 192, 0.5);
        }
        .record-row.three-place:hover {
            background: rgba(20, 15, 10, 0.9);
            box-shadow: 0 0 50px rgba(205, 127, 50, 0.1);
            border-color: rgba(205, 127, 50, 0.5);
        }

        .record-row::before,
        .record-row::after {
            content: "";
            position: absolute;
            width: 40px;
            height: 40px;
            opacity: 0.9;
            transition: 0.3s ease;
            z-index: 1;
            border-style: solid;
            border-color: var(--hud-green);
            border-width: 0;
        }
        .record-row::before {
            top: -1px;
            left: -1px;
            border-top-width: 2px;
            border-left-width: 2px;
        }
        .record-row::after {
            bottom: -1px;
            right: -1px;
            border-bottom-width: 2px;
            border-right-width: 2px;
        }

        .record-row:hover::before,
        .record-row:hover::after {
            border-color: var(--hud-highlight);
            opacity: 1;
        }

        .record-row.one-place::before,
        .record-row.one-place::after {
            border-color: var(--gold);
        }
        .record-row.one-place:hover::before,
        .record-row.one-place:hover::after {
            border-color: var(--gold);
            opacity: 1;
        }
        .record-row.two-place::before,
        .record-row.two-place::after {
            border-color: var(--silver);
        }
        .record-row.two-place:hover::before,
        .record-row.two-place:hover::after {
            border-color: var(--silver);
            opacity: 1;
        }
        .record-row.three-place::before,
        .record-row.three-place::after {
            border-color: var(--bronze);
        }
        .record-row.three-place:hover::before,
        .record-row.three-place:hover::after {
            border-color: var(--bronze);
            opacity: 1;
        }

        .record-row.one-place {
            background: rgba(0, 0, 0, 0.85);
            border-color: rgba(255, 215, 0, 0.4);
            box-shadow: 0 0 60px rgba(255, 215, 0, 0.08);
        }
        .record-row.two-place {
            background: rgba(0, 0, 0, 0.85);
            border-color: rgba(192, 192, 192, 0.35);
            box-shadow: 0 0 40px rgba(192, 192, 192, 0.06);
        }
        .record-row.three-place {
            background: rgba(0, 0, 0, 0.85);
            border-color: rgba(205, 127, 50, 0.35);
            box-shadow: 0 0 40px rgba(205, 127, 50, 0.06);
        }

        .record-row .row-stars {
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            pointer-events: none;
            overflow: hidden;
            z-index: 0;
        }
        .star-particle {
            position: absolute;
            width: 8px;
            height: 8px;
            background: var(--hud-green);
            clip-path: polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%);
            animation: twinkle 3s infinite alternate;
            opacity: 0;
            filter: blur(1px);
        }
        .one-place .star-particle {
            background: var(--gold);
            box-shadow: 0 0 12px var(--gold), 0 0 24px var(--gold);
        }
        .two-place .star-particle {
            background: var(--silver);
            box-shadow: 0 0 8px var(--silver), 0 0 16px var(--silver);
        }
        .three-place .star-particle {
            background: var(--bronze);
            box-shadow: 0 0 6px var(--bronze), 0 0 12px var(--bronze);
        }

        .one-place .star-particle:nth-child(1) { top: 12%; left: 8%; animation-delay: 0s; }
        .one-place .star-particle:nth-child(2) { top: 8%; right: 15%; animation-delay: 0.4s; }
        .one-place .star-particle:nth-child(3) { bottom: 18%; left: 22%; animation-delay: 0.8s; }
        .one-place .star-particle:nth-child(4) { bottom: 10%; right: 12%; animation-delay: 1.2s; }
        .one-place .star-particle:nth-child(5) { top: 45%; left: 5%; animation-delay: 0.6s; }
        .one-place .star-particle:nth-child(6) { top: 5%; left: 50%; animation-delay: 0.2s; }
        .one-place .star-particle:nth-child(7) { bottom: 5%; right: 50%; animation-delay: 1.0s; }

        .two-place .star-particle:nth-child(1) { top: 15%; left: 12%; animation-delay: 0s; }
        .two-place .star-particle:nth-child(2) { top: 10%; right: 20%; animation-delay: 0.6s; }
        .two-place .star-particle:nth-child(3) { bottom: 15%; left: 25%; animation-delay: 1.2s; }
        .two-place .star-particle:nth-child(4) { bottom: 10%; right: 15%; animation-delay: 0.3s; }
        .two-place .star-particle:nth-child(n+5) { display: none; }

        .three-place .star-particle:nth-child(1) { top: 18%; left: 15%; animation-delay: 0s; }
        .three-place .star-particle:nth-child(2) { bottom: 18%; right: 20%; animation-delay: 0.8s; }
        .three-place .star-particle:nth-child(3) { top: 40%; left: 10%; animation-delay: 0.4s; }
        .three-place .star-particle:nth-child(n+4) { display: none; }

        .record-row:not(.one-place):not(.two-place):not(.three-place) .row-stars {
            display: none;
        }

        @keyframes twinkle {
            0% { opacity: 0; transform: scale(0.3) rotate(0deg); }
            50% { opacity: 1; transform: scale(1.4) rotate(180deg); }
            100% { opacity: 0.4; transform: scale(0.8) rotate(360deg); }
        }

        .rank-medal {
            flex: 0 0 80px;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            text-align: center;
            font-family: 'Orbitron', sans-serif;
            position: relative;
            z-index: 2;
        }

        .rank-badge {
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            width: 70px;
            height: 70px;
            border: 2px solid rgba(88, 255, 207, 0.3);
            background: rgba(0, 0, 0, 0.6);
            clip-path: polygon(0 0, 100% 0, 90% 50%, 100% 100%, 0 100%, 10% 50%);
            position: relative;
            padding: 4px;
            transition: 0.3s ease;
        }
        .rank-badge .star-icon {
            font-size: 24px;
            line-height: 1;
            color: var(--hud-green);
            text-shadow: 0 0 10px rgba(88, 255, 207, 0.5);
        }
        .rank-badge .rank-number {
            font-size: 18px;
            font-weight: 700;
            color: var(--hud-highlight);
            letter-spacing: 1px;
            margin-top: 2px;
        }

        .one-place .rank-badge {
            border-color: var(--gold);
            background: rgba(255, 215, 0, 0.1);
            box-shadow: 0 0 30px rgba(255, 215, 0, 0.3), inset 0 0 20px rgba(255, 215, 0, 0.1);
        }
        .one-place .rank-badge .star-icon {
            color: var(--gold);
            text-shadow: 0 0 20px rgba(255, 215, 0, 0.8), 0 0 40px rgba(255, 215, 0, 0.4);
        }
        .one-place .rank-badge .rank-number {
            color: var(--gold);
        }

        .two-place .rank-badge {
            border-color: var(--silver);
            background: rgba(192, 192, 192, 0.08);
            box-shadow: 0 0 20px rgba(192, 192, 192, 0.2);
        }
        .two-place .rank-badge .star-icon {
            color: var(--silver);
            text-shadow: 0 0 15px rgba(192, 192, 192, 0.6);
        }
        .two-place .rank-badge .rank-number {
            color: var(--silver);
        }

        .three-place .rank-badge {
            border-color: var(--bronze);
            background: rgba(205, 127, 50, 0.08);
            box-shadow: 0 0 20px rgba(205, 127, 50, 0.2);
        }
        .three-place .rank-badge .star-icon {
            color: var(--bronze);
            text-shadow: 0 0 15px rgba(205, 127, 50, 0.6);
        }
        .three-place .rank-badge .rank-number {
            color: var(--bronze);
        }

        .record-row .pfp-placeholder {
            flex: 0 0 84px;
            width: 84px;
            height: 84px;
            overflow: hidden;
            border: 3px solid rgba(88, 255, 207, 0.25);
            background: #0a0a0a;
            border-radius: 0;
            position: relative;
            z-index: 2;
            padding: 2px;
        }
        .record-row .pfp-placeholder img {
            width: 100%;
            height: 100%;
            object-fit: cover;
            border-radius: 0;
            display: block;
        }
        .record-row .pfp-placeholder::before {
            content: "";
            position: absolute;
            top: -1px;
            left: -1px;
            width: 18px;
            height: 18px;
            border-top: 2px solid var(--hud-green);
            border-left: 2px solid var(--hud-green);
            opacity: 0.5;
            transition: 0.2s ease;
            z-index: 3;
        }
        .record-row .pfp-placeholder::after {
            content: "";
            position: absolute;
            bottom: -1px;
            right: -1px;
            width: 18px;
            height: 18px;
            border-bottom: 2px solid var(--hud-green);
            border-right: 2px solid var(--hud-green);
            opacity: 0.5;
            transition: 0.2s ease;
            z-index: 3;
        }
        .record-row:hover .pfp-placeholder::before,
        .record-row:hover .pfp-placeholder::after {
            opacity: 0.9;
            border-color: var(--hud-highlight);
        }
        .record-row.one-place .pfp-placeholder {
            border-color: var(--gold);
        }
        .record-row.one-place .pfp-placeholder::before,
        .record-row.one-place .pfp-placeholder::after {
            border-color: var(--gold);
        }
        .record-row.two-place .pfp-placeholder {
            border-color: var(--silver);
        }
        .record-row.two-place .pfp-placeholder::before,
        .record-row.two-place .pfp-placeholder::after {
            border-color: var(--silver);
        }
        .record-row.three-place .pfp-placeholder {
            border-color: var(--bronze);
        }
        .record-row.three-place .pfp-placeholder::before,
        .record-row.three-place .pfp-placeholder::after {
            border-color: var(--bronze);
        }

        /* ============================================================
           TWO-COLUMN LAYOUT INSIDE .user-info
           ============================================================ */
        .record-row .user-info {
            flex: 1 1 auto;
            min-width: 300px;
            position: relative;
            z-index: 2;
            display: flex;
            flex-wrap: wrap;
            justify-content: space-between;
            align-items: flex-start;
            gap: 20px;
        }

        /* LEFT COLUMN – score, player, route */
        .user-info-left {
            flex: 1 1 60%;
            display: flex;
            flex-direction: column;
            gap: 2px;
        }
        .user-info-left .score-display {
            font-size: 28px;
            font-weight: 700;
            color: var(--hud-highlight);
            font-family: 'Orbitron', sans-serif;
            letter-spacing: 1px;
            line-height: 1.2;
        }
        .user-info-left .username-link {
            font-size: 18px;
            color: var(--hud-green);
            font-family: 'Segoe UI', system-ui, sans-serif;
            font-weight: 500;
            transition: 0.2s ease;
        }
        .user-info-left .username-link:hover {
            color: #fff;
            text-shadow: 0 0 20px rgba(88, 255, 207, 0.3);
        }
        .user-info-left .route-section {
            display: flex;
            flex-direction: column;
            align-items: flex-start;
            gap: 2px;
            margin-top: 4px;
        }
        .user-info-left .route-icons {
            display: flex;
            gap: 4px;
            flex-wrap: wrap;
        }
        .user-info-left .route-icons img {
            width: 28px;
            height: 28px;
            object-fit: contain;
            opacity: 0.8;
            transition: 0.2s ease;
            border-radius: 0;
        }
        .user-info-left .route-icons img:hover {
            opacity: 1;
            transform: scale(1.15);
        }
        .user-info-left .route-badge {
            font-size: 12px;
            letter-spacing: 0.5px;
            color: rgba(88, 255, 207, 0.7);
            font-family: 'Segoe UI', system-ui, sans-serif;
        }
        .user-info-left .route-badge .badge {
            background: rgba(88, 255, 207, 0.08);
            color: var(--hud-green);
            padding: 4px 12px;
            border-radius: 0;
            font-size: 11px;
            font-weight: 400;
            letter-spacing: 0.5px;
            border: 1px solid rgba(88, 255, 207, 0.12);
        }

        /* RIGHT COLUMN – patch first, then difficulty, single-life, date */
        .user-info-right {
            flex: 0 1 auto;
            display: flex;
            flex-direction: column;
            align-items: flex-end;
            gap: 6px;
            text-align: right;
            padding-top: 2px;
        }
        .user-info-right .badge-difficulty,
        .user-info-right .badge-version,
        .user-info-right .badge-singlelife {
            font-family: 'Segoe UI', system-ui, sans-serif;
            font-weight: 700;
            font-size: 10px;
            letter-spacing: 1px;
            padding: 4px 12px;
            border-radius: 0;
            text-transform: uppercase;
            display: inline-block;
            border: 1px solid transparent;
            background: rgba(0,0,0,0.6);
            transition: 0.25s ease;
            white-space: nowrap;
        }
        .user-info-right .badge-difficulty.easy {
            color: #4caf50;
            border-color: #4caf50;
            text-shadow: 0 0 12px rgba(76,175,80,0.3);
        }
        .user-info-right .badge-difficulty.normal {
            color: #ffc107;
            border-color: #ffc107;
            text-shadow: 0 0 12px rgba(255,193,7,0.3);
        }
        .user-info-right .badge-difficulty.expert {
            color: #ff6b00;
            border-color: #ff6b00;
            text-shadow: 0 0 12px rgba(255,107,0,0.4);
        }
        .user-info-right .badge-version {
            border-color: rgba(88,255,207,0.3);
            color: var(--hud-green);
        }
        .user-info-right .badge-singlelife {
            border-color: #00b4d8;
            color: #00b4d8;
            text-shadow: 0 0 12px rgba(0,180,216,0.4);
            box-shadow: 0 0 20px rgba(0,180,216,0.08);
        }
        .user-info-right .badge-singlelife:hover {
            background: rgba(0,180,216,0.15);
            box-shadow: 0 0 30px rgba(0,180,216,0.2);
        }
        .user-info-right .date-tag {
            font-size: 12px;
            color: var(--hud-highlight);
            opacity: 0.7;
            font-family: 'Segoe UI', system-ui, sans-serif;
            white-space: nowrap;
        }

        /* Pagination */
        .pagination-hud {
            display: flex;
            justify-content: center;
            align-items: center;
            gap: 8px;
            flex-wrap: wrap;
            margin: 20px 0 10px 0;
            padding: 14px 0;
            border-top: 1px solid rgba(88, 255, 207, 0.06);
        }
        .pagination-hud .page-btn {
            background: rgba(0, 0, 0, 0.6);
            border: 1px solid rgba(88, 255, 207, 0.15);
            color: var(--hud-green);
            font-family: 'Orbitron', sans-serif;
            font-size: 10px;
            padding: 6px 16px;
            transition: 0.2s ease;
            letter-spacing: 0.5px;
            min-width: 36px;
            text-align: center;
            border-radius: 0;
        }
        .pagination-hud .page-btn:hover {
            background: rgba(88, 255, 207, 0.08);
            border-color: var(--hud-highlight);
            color: #fff;
            box-shadow: 0 0 18px rgba(88, 255, 207, 0.08);
        }
        .pagination-hud .page-btn.active {
            background: var(--hud-green);
            border-color: var(--hud-green);
            color: #00140e;
            font-weight: 700;
        }
        .pagination-hud .page-btn:disabled {
            opacity: 0.2;
            pointer-events: none;
        }

        /* ============================================================
           RESPONSIVE – adapted for two-column layout
           ============================================================ */


        @media (max-width: 1024px) {
            
            .filter-row-top {
                flex-direction: column; /* already set at 768px, but keep for safety */
            }
            .dropdown-box,
            .difficulty-box {
                width: 100%;
                flex: 0 0 100%;        /* force each to take a full row */
                min-width: 0;          /* override any min-width that might linger */
                box-sizing: border-box;
            }
            /* Optionally make the buttons larger and easier to tap */
            .difficulty-box .filter-btn {
                font-size: 10px;
                padding: 6px 12px;
            }
            
            .filter-row-top {
                flex-direction: column;
                gap: 12px;
            }

            /* Force both boxes to take full width */
            .dropdown-box,
            .difficulty-box {
                width: 100%;
                flex: 0 0 100%;
                min-width: 0;          /* remove any min‑width limitation */
                box-sizing: border-box;
            }

            /* Move difficulty box above the dropdowns */
            .difficulty-box {
                order: -1;             /* or order: 1; and .dropdown-box { order: 2; } */
            }

            /* Optionally make the dropdown groups stack vertically for easier tapping */
            .dropdown-box {
                flex-direction: column;
                gap: 12px;
            }
            .dropdown-box .filter-group {
                flex: 1 1 auto;
                width: 100%;
                min-width: 0;
            }

        }


        @media (max-width: 992px) {
            .main-content {
                padding: 15px 16px 30px;
                margin-top: 30px;
            }
            .filter-row-top {
                flex-direction: column;
                gap: 12px;
            }
            .dropdown-box {
                flex: 1 1 auto;
            }
            .difficulty-box {
                flex: 1 1 auto;
                flex-direction: row;
                flex-wrap: wrap;
                justify-content: center;
                gap: 6px;
                padding: 12px 16px;
                min-width: 0;
            }
            .difficulty-box .filter-btn {
                width: auto;
                flex: 0 1 auto;
            }
            .difficulty-box .single-life-row {
                flex: 0 1 100%;
                justify-content: center;
            }
            .patch-box {
                flex: 1 1 100%;
                justify-content: center;
            }
            .patch-box .patch-right {
                margin-left: 0;
            }
            .record-row {
                padding: 18px 22px;
                gap: 18px;
            }
            .user-info-left .score-display {
                font-size: 24px;
            }
            .rank-medal {
                flex: 0 0 70px;
            }
            .rank-badge {
                width: 60px;
                height: 60px;
            }
            .rank-badge .star-icon {
                font-size: 20px;
            }
            .rank-badge .rank-number {
                font-size: 16px;
            }
            .record-row .pfp-placeholder {
                flex: 0 0 72px;
                width: 72px;
                height: 72px;
            }
            .status-panel {
                display: none !important;
            }
        }

        @media (max-width: 768px) {
            .main-content {
                padding: 8px 8px 16px;
                margin-top: 90px;
            }
            .leaderboard-header {
                margin-bottom: 12px;
                padding-bottom: 8px;
            }
            .leaderboard-header h1 {
                font-size: 14px;
                letter-spacing: 0.5px;
            }
            .leaderboard-header h1 small {
                font-size: 10px;
                margin-left: 4px;
                display: block;
            }
            .leaderboard-header .back-link {
                font-size: 9px;
                padding: 4px 10px;
            }
            .subtitle-display {
                font-size: 10px;
                margin-top: 3px;
            }
            .filter-row-top {
                flex-direction: column;
                gap: 10px;
            }
            .dropdown-box {
                flex-direction: column;
                gap: 8px;
            }
            .dropdown-box .filter-group {
                flex: 1 1 auto;
                width: 100%;
            }
            .difficulty-box {
                flex-direction: row;
                flex-wrap: wrap;
                justify-content: center;
                padding: 8px 12px;
            }
            .difficulty-box .filter-btn {
                font-size: 7px;
                padding: 2px 8px;
            }
            .patch-box {
                flex: 1 1 100%;
                width: 100%;
                justify-content: center;
                flex-wrap: wrap;
            }
            .patch-box .patch-right {
                margin-left: 0;
            }
            .record-row {
                flex-direction: row;
                flex-wrap: nowrap;
                align-items: center;
                gap: 6px;
                padding: 6px 8px;
                margin-bottom: 6px;
                border-width: 1px;
                border-radius: 0;
            }
            .record-row::before,
            .record-row::after {
                display: none !important;
            }
            .rank-medal {
                flex: 0 0 32px;
            }
            .rank-badge {
                width: 32px;
                height: 32px;
                border-width: 1px;
                padding: 2px;
                clip-path: polygon(0 0, 100% 0, 90% 50%, 100% 100%, 0 100%, 10% 50%);
            }
            .rank-badge .star-icon {
                font-size: 10px;
                line-height: 1;
            }
            .rank-badge .rank-number {
                font-size: 9px;
                margin-top: 0;
                line-height: 1;
            }
            .record-row .pfp-placeholder {
                flex: 0 0 32px;
                width: 32px;
                height: 32px;
                border-width: 2px;
                padding: 1px;
            }
            .record-row .pfp-placeholder::before,
            .record-row .pfp-placeholder::after {
                display: none !important;
            }
            .record-row .user-info {
                min-width: 0;
                gap: 4px;
                flex-direction: column;
                align-items: stretch;
            }
            .user-info-left {
                flex: 1 1 auto;
                width: 100%;
            }
            .user-info-left .score-display {
                font-size: 14px;
            }
            .user-info-left .username-link {
                font-size: 12px;
            }
            .user-info-left .route-icons img {
                width: 14px;
                height: 14px;
            }
            .user-info-left .route-badge {
                font-size: 8px;
            }
            .user-info-left .route-badge .badge {
                font-size: 7px;
                padding: 1px 6px;
            }
            .user-info-right {
                flex-direction: row;
                flex-wrap: wrap;
                align-items: center;
                justify-content: flex-start;
                gap: 4px 8px;
                width: 100%;
                padding-top: 0;
            }
            .user-info-right .badge-difficulty,
            .user-info-right .badge-version,
            .user-info-right .badge-singlelife {
                font-size: 7px;
                padding: 1px 6px;
            }
            .user-info-right .date-tag {
                font-size: 8px;
            }
            .one-place .star-particle:nth-child(n+3) { display: none; }
            .two-place .star-particle:nth-child(n+2) { display: none; }
            .three-place .star-particle:nth-child(n+2) { display: none; }
            .pagination-hud .page-btn {
                font-size: 8px;
                padding: 3px 8px;
                min-width: 24px;
            }
            .pagination-hud {
                gap: 4px;
                padding: 8px 0;
                margin-top: 10px;
            }
        }

        @media (max-width: 480px) {
            .main-content {
                margin-top: 100px;
                padding: 6px 6px 12px;
            }
            .record-row {
                padding: 4px 6px;
                gap: 4px;
                margin-bottom: 4px;
            }
            .rank-medal {
                flex: 0 0 26px;
            }
            .rank-badge {
                width: 26px;
                height: 26px;
            }
            .rank-badge .star-icon {
                font-size: 8px;
            }
            .rank-badge .rank-number {
                font-size: 7px;
            }
            .record-row .pfp-placeholder {
                flex: 0 0 26px;
                width: 26px;
                height: 26px;
                border-width: 1px;
            }
            .user-info-left .score-display {
                font-size: 12px;
            }
            .user-info-left .username-link {
                font-size: 10px;
            }
            .user-info-left .route-icons img {
                width: 12px;
                height: 12px;
            }
            .user-info-right .badge-difficulty,
            .user-info-right .badge-version,
            .user-info-right .badge-singlelife {
                font-size: 6px;
                padding: 0 4px;
            }
            .user-info-right .date-tag {
                font-size: 7px;
            }
        }

        @media (max-width: 400px) {
            .main-content {
                margin-top: 110px;
            }
            .record-row {
                padding: 3px 4px;
                gap: 3px;
                margin-bottom: 3px;
            }
            .rank-medal {
                flex: 0 0 22px;
            }
            .rank-badge {
                width: 22px;
                height: 22px;
            }
            .rank-badge .star-icon {
                font-size: 6px;
            }
            .rank-badge .rank-number {
                font-size: 6px;
            }
            .record-row .pfp-placeholder {
                flex: 0 0 22px;
                width: 22px;
                height: 22px;
                border-width: 1px;
            }
            .user-info-left .score-display {
                font-size: 10px;
            }
            .user-info-left .username-link {
                font-size: 9px;
            }
        }

        /* ============================================================
           FORCE UCP TO STAY FIXED ON MOBILE (override ucp.cfm)
           ============================================================ */
        @media (max-width: 768px) {
            /* 1. Player HUD – fixed top-left */
            .player-hud {
                position: fixed !important;
                top: 8px !important;
                left: 8px !important;
                z-index: 9999 !important;   /* above everything */
                background: rgba(0, 0, 0, 0.85);
                border-color: var(--hud-green);
                box-shadow: 0 0 20px rgba(0,0,0,0.8);
            }

            /* 2. Logout button – fixed top-right */
            .logout-container {
                position: fixed !important;
                top: 8px !important;
                right: 8px !important;
                z-index: 9999 !important;
            }

            /* 3. Submit Score button – fixed below HUD */
            .submit-score-btn {
                position: fixed !important;
                top: 50px !important;    /* adjust to sit below the HUD */
                left: 8px !important;
                z-index: 9998 !important;
                margin-left: 0 !important;  /* reset any live‑active shift */
            }
            /* If the live badge is present, shift it slightly */
            .submit-score-btn.live-active {
                margin-left: 0 !important;   /* or set a small value like 20px if needed */
            }

            /* 4. Add extra top padding to main content so it doesn't hide behind the fixed HUD */
            .main-content {
                padding-top: 70px !important;   /* adjust to match HUD height + submit button */
            }
        }


