  :root {
            --neon-blue: #00d4ff;
            --dark-blue: #050c19; 
            --glow-color: rgba(0, 212, 255, 0.75);
            --orange-glow: rgba(255, 165, 0, 0.7);
            --neon-green: #39ff14;
            --green-glow: rgba(57, 255, 20, 0.75);
            --font-family: 'Press Start 2P', cursive;
        }

        body, html {
            margin: 0;
            padding: 0;
            width: 100%;
            min-height: 100%;
            font-family: var(--font-family);
            color: white;
            display: flex;
            align-items: center;
            justify-content: center;
            overflow-x: hidden;
        }

        .background-image-container {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            z-index: -1;
        }

        .background-image-container img {
            width: 100%;
            height: 100%;
            object-fit: cover;
            filter: brightness(0.7);
        }
        
        .crt-overlay {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            pointer-events: none;
            z-index: 10;
        }
        .crt-overlay::before {
            content: "";
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.25) 50%), linear-gradient(90deg, rgba(255, 0, 0, 0.06), rgba(0, 255, 0, 0.02), rgba(0, 0, 255, 0.06));
            background-size: 100% 4px, 3px 100%;
            z-index: 2;
            animation: flicker 0.15s infinite;
        }
        @keyframes flicker {
            0% { opacity: 0.2; }
            50% { opacity: 0.5; }
            100% { opacity: 0.2; }
        }

        .firefly-container {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            overflow: hidden;
            z-index: 0; 
        }

        .firefly {
            position: absolute;
            width: 4px;
            height: 4px;
            background-color: #fff;
            border-radius: 50%;
            box-shadow: 0 0 6px 2px #fff, 0 0 10px 4px var(--neon-green);
            animation: move 10s infinite;
            opacity: 0;
        }

        @keyframes move {
            0% { transform: translate(0, 0); opacity: 0; }
            10% { opacity: 1; }
            90% { opacity: 1; }
            100% { transform: translate(var(--x-end), var(--y-end)); opacity: 0; }
        }

        .main-content-wrapper {
            display: flex;
            flex-direction: column;
            align-items: center;
            z-index: 1;
            padding: 1rem 0 2rem 0;
        }
        
        .page-layout {
            display: flex;
            flex-direction: column;
            align-items: center;
            gap: 2rem;
        }

        .logo-container {
            margin-bottom: -1rem;
        }

        .logo-emblem {
            width: 520px;
            height: 250px;
            position: relative;
            background-image: url('/imgs/risk_logo.png');
            background-size: contain;
            background-repeat: no-repeat;
            background-position: center;
            mix-blend-mode: lighten;
            margin-bottom: 2rem;
        }
        
        .menu-wrapper, .avatar-wrapper {
            position: relative;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
        }

        .menu-container {
            background-color: rgba(1, 22, 61, 0.85);
            padding: 2rem 3rem;
            text-align: center;
            position: relative;
            width: 90%;
            max-width: 500px;
            box-shadow: 
                0 0 5px var(--glow-color),
                0 0 15px var(--glow-color),
                0 0 30px var(--glow-color),
                inset 0 0 5px var(--glow-color),
                inset 0 0 15px var(--glow-color);
            border-radius: 8px;
            background-clip: padding-box;
            border: 3px solid transparent;
            box-sizing: border-box;
            display: flex;
            flex-direction: column;
        }

        .menu-container::before {
            content: '';
            position: absolute;
            top: 10px;
            left: 10px;
            right: 10px;
            bottom: 10px;
            border: 2px solid var(--neon-blue);
            border-radius: 4px;
            pointer-events: none;
        }

        .menu-content {
            display: flex;
            flex-direction: column;
            align-items: center;
            gap: 1rem;
            width: 100%;
            position: relative;
            z-index: 2;
            flex-grow: 1;
        }

        h1 {
            font-size: 1.5rem;
            margin-bottom: 1rem;
            background: linear-gradient(180deg, #ffd966, #ff9900);
            -webkit-background-clip: text;
            background-clip: text;
            color: transparent;
            text-shadow: 0 0 10px var(--orange-glow);
        }

        .input-wrapper {
            position: relative;
            width: 100%;
            display: block;
            align-items: center;
        }

        .form-input {
            width: 100%;
            padding: 0.8rem;
            background-color: var(--dark-blue);
            border: 2px solid var(--neon-blue);
            border-radius: 4px;
            color: white;
            font-family: var(--font-family);
            font-size: 0.8rem;
            text-align: left;
            box-sizing: border-box;
            transition: all 0.3s ease;
        }

        .form-input::placeholder {
            color: rgba(255, 255, 255, 0.5);
        }

        .form-input:focus {
            outline: none;
            box-shadow: 0 0 10px var(--glow-color);
        }
        
        .tooltip {
            position: absolute;
            right: 10px;
            top: 22px;
            transform: translateY(-50%);
            width: 22px;
            height: 22px;
            background-color: var(--dark-blue);
            border: 2px solid var(--neon-blue);
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 0.8rem;
            font-weight: bold;
            cursor: help;
            z-index: 5;
        }

        .tooltip .tooltip-text {
            visibility: hidden;
            width: 240px;
            background-color: var(--dark-blue);
            color: #fff;
            text-align: center;
            border-radius: 6px;
            padding: 10px;
            position: absolute;
            z-index: 1;
            bottom: 135%;
            left: 50%;
            margin-left: -120px;
            opacity: 0;
            transition: opacity 0.3s;
            font-size: 0.7rem;
            line-height: 1.4;
            border: 1px solid var(--neon-blue);
            box-shadow: 0 0 10px var(--glow-color);
        }

        .tooltip:hover .tooltip-text {
            visibility: visible;
            opacity: 1;
        }

        .btn {
            width: 100%;
            padding: 0.8rem 1rem;
            background-color: #ffb800;
            border: none;
            border-radius: 8px;
            color: var(--dark-blue);
            font-family: var(--font-family);
            font-size: 1rem;
            cursor: pointer;
            transition: all 0.3s ease;
            box-shadow: 0 0 10px var(--orange-glow), 0 0 20px var(--orange-glow);
        }

        .btn:hover {
            transform: scale(1.05);
            box-shadow: 0 0 15px var(--orange-glow), 0 0 30px var(--orange-glow);
        }
        
        .login-prompt {
            font-size: 0.7rem;
            color: #cdd6f4;
            margin-top: 1.5rem;
            border-top: 2px solid var(--neon-blue);
            padding-top: 1.5rem;
            width: 100%;
        }

        .login-prompt a {
            color: var(--neon-blue);
            text-decoration: underline;
            cursor: pointer;
        }
        
        .bottom-icon {
            width: 80px;
            height: 80px;
            padding: 18px;
            background-color: var(--dark-blue);
            border: 3px solid var(--neon-blue);
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            margin-top: 1.5rem;
            z-index: 2;
            box-shadow: 0 0 10px var(--glow-color), 0 0 20px var(--glow-color);
            overflow: hidden;
        }

        .bottom-icon img {
            width: 100%;
            height: auto;
            object-fit: contain;
        }
        
        .avatar-panel {
            background-size: cover;
            background-position: center;
            transition: background-image 0.4s ease-in-out;
            justify-content: space-between;
            height: 100%;
        }
        
        .avatar-panel::after {
            content: '';
            position: absolute;
            top: 0; left: 0; right: 0; bottom: 0;
          
            z-index: 1;
            border-radius: inherit;

        }
        
        .avatar-navigation {
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 0.5rem;
        }

        .nav-arrow {
            background: none;
            border: 4px solid var(--neon-blue);
            color: var(--neon-blue);
            width: 43px;
            height: 43px;
            border-radius: 50%;
            line-height: 0.1rem;
            font-family: monospace;
            font-size: 2.5rem;
            cursor: pointer;
            transition: all 0.2s ease;
        }
        .nav-arrow:hover {
            background: var(--neon-blue);
            color: var(--dark-blue);
            box-shadow: 0 0 8px var(--glow-color);
        }

        .thumbnails-wrapper {
            overflow: hidden;
            width: 242px; /* (60px width + 2*3px border + 2*2px padding) * 3 + 2 * 1rem gap */
        }

        .avatar-thumbnails {
            display: flex;
            gap: 1rem;
            transition: transform 0.4s ease-in-out;
        }

        .thumbnail-item {
            width: 60px;
            height: 60px;
            cursor: pointer;
            border: 3px solid var(--neon-blue);
            border-radius: 8px;
            transition: all 0.3s ease;
            overflow: hidden;
            padding: 2px;
            flex-shrink: 0;
        }
        
        .thumbnail-item img {
            display: block;
            width: 100%;
            height: 100%;
            object-fit: cover;
            border-radius: 4px;
        }

        .thumbnail-item:hover {
            transform: scale(1.05);
            box-shadow: 0 0 10px var(--glow-color);
        }
        
        .thumbnail-item.selected {
            border-color: var(--neon-green);
            transform: scale(1.1);
            box-shadow: 0 0 15px var(--green-glow), 0 0 30px var(--green-glow);
        }
        .text-danger {
            font-size: 12px;
            color: red !important;
        }

        @media (min-width: 1024px) {
            .page-layout {
                flex-direction: row;
                align-items: stretch;
                justify-content: center;
                gap: 0;
            }
            .menu-wrapper {
                width: 480px;
            }
            .avatar-wrapper {
                width: 340px;
            }
            .menu-container {
                width: 100%;
            }
            .menu-container.linked-left {
                border-top-right-radius: 0;
                border-bottom-right-radius: 0;
            }
            .menu-container.linked-right {
                border-top-left-radius: 0;
                border-bottom-left-radius: 0;
            }
            .menu-container.linked-left::before {
                border-top-right-radius: 0;
                border-bottom-right-radius: 0;
            }
            .menu-container.linked-right::before {
                border-top-left-radius: 0;
                border-bottom-left-radius: 0;
            }
        }

        @media (max-width: 600px) {
            .logo-emblem {
                width: 90vw;
                height: 150px;
            }
            .menu-container {
                padding: 1.5rem;
            }
            h1 {
                font-size: 1.2rem;
            }
            .btn {
                font-size: 0.8rem;
                padding: 0.8rem;
            }
        }
        .invalid-feedback{
            color: #ff0000;
            font-size: 10px; 
            padding: 4px;
            display: none;
        }
        .is-invalid {
            border-color: red;
        }

        .form-validated input:invalid + .invalid-feedback {
            display: block;
        }

        .email-already-used{
            color: #ff0000;
            font-size: 10px; 
            padding: 4px;
        }

        .interactive-link {
            font-size: 0.7rem;
            color: var(--neon-blue);
            text-decoration: underline;
            cursor: pointer;
            transition: all 0.3s ease;
        }
        
        .interactive-link:hover {
            text-shadow: 0 0 5px var(--glow-color);
        }