/* ============================================================
   RETRO RACER — Estilo base New Retro Net
   Paleta: magenta #ff00ff, cian #00ffff, fondo oscuro #0a0a1a
   ============================================================ */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: #0a0a1a;
    color: #00ffff;
    font-family: 'Courier New', Courier, monospace;
    overflow: hidden;
    width: 100vw;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

#game-container {
    position: relative;
    width: 100vw;
    height: 100vh;
    background: linear-gradient(to bottom,
            #0a0a1a 0%,
            /* cielo oscuro arriba */
            #1a0a2e 40%,
            /* transición púrpura */
            #2d1b4e 60%,
            /* horizonte */
            #0a0a1a 100%
            /* abajo */
        );
}

#game-canvas {
    display: block;
    width: 100%;
    height: 100%;
}

/* HUD minimalista — estilo digital/neón */
#hud {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    padding: 20px 30px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

#speedometer {
    font-size: 2.5rem;
    font-weight: bold;
    color: #ff00ff;
    text-shadow: 0 0 10px #ff00ff, 0 0 20px #ff00ff;
    letter-spacing: 2px;
}

#speedometer span {
    font-size: 1rem;
    color: #00ffff;
    text-shadow: 0 0 5px #00ffff;
    margin-left: 8px;
}

#debug-info {
    font-size: 0.9rem;
    color: #00ffff;
    text-shadow: 0 0 5px #00ffff;
    opacity: 0.7;
}


/* ============================================================
   DEBUG PANEL — Sliders de ajuste de física en tiempo real
   ============================================================ */

#debug-panel {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 320px;
    max-height: 85vh;
    overflow-y: auto;
    background: rgba(10, 10, 26, 0.92);
    border: 1px solid #ff00ff;
    border-radius: 8px;
    padding: 16px;
    box-shadow: 0 0 20px rgba(255, 0, 255, 0.3), inset 0 0 30px rgba(0, 255, 255, 0.05);
    backdrop-filter: blur(4px);
    z-index: 1000;
    font-family: 'Courier New', Courier, monospace;
}

#debug-panel h3 {
    margin: 0 0 4px 0;
    color: #ff00ff;
    font-size: 1rem;
    text-shadow: 0 0 8px #ff00ff;
    text-align: center;
    letter-spacing: 1px;
}

.debug-hint {
    margin: 0 0 12px 0;
    color: #00ffff;
    font-size: 0.7rem;
    text-align: center;
    opacity: 0.6;
}

.debug-row {
    margin-bottom: 10px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255, 0, 255, 0.15);
}

.debug-row:last-of-type {
    border-bottom: none;
}

.debug-row label {
    display: block;
    color: #00ffff;
    font-size: 0.75rem;
    margin-bottom: 4px;
    letter-spacing: 0.5px;
}

.debug-value {
    float: right;
    color: #ff00ff;
    font-size: 0.75rem;
    font-weight: bold;
    text-shadow: 0 0 5px #ff00ff;
}

.debug-row input[type="range"] {
    width: 100%;
    height: 6px;
    background: #1a1a2e;
    border-radius: 3px;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    cursor: pointer;
}

.debug-row input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 14px;
    height: 14px;
    background: #ff00ff;
    border-radius: 50%;
    box-shadow: 0 0 8px #ff00ff;
    cursor: pointer;
    border: 2px solid #00ffff;
}

.debug-row input[type="range"]::-moz-range-thumb {
    width: 14px;
    height: 14px;
    background: #ff00ff;
    border-radius: 50%;
    box-shadow: 0 0 8px #ff00ff;
    cursor: pointer;
    border: 2px solid #00ffff;
}

.debug-reset {
    width: 100%;
    margin-top: 8px;
    padding: 8px;
    background: transparent;
    color: #00ffff;
    border: 1px solid #00ffff;
    border-radius: 4px;
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.2s;
}

.debug-reset:hover {
    background: rgba(0, 255, 255, 0.15);
    box-shadow: 0 0 10px rgba(0, 255, 255, 0.3);
}

/* Scrollbar del panel */
#debug-panel::-webkit-scrollbar {
    width: 6px;
}

#debug-panel::-webkit-scrollbar-track {
    background: rgba(10, 10, 26, 0.5);
}

#debug-panel::-webkit-scrollbar-thumb {
    background: #ff00ff;
    border-radius: 3px;
}

/* ============================================================
   DEBUG PANEL — Selector de vehículo (NUEVO — Prompt 5)
   ============================================================ */

.debug-select {
    width: 100%;
    background: #1a1a2e;
    color: #00ffff;
    border: 1px solid #ff00ff;
    padding: 4px 8px;
    font-family: 'Courier New', monospace;
    font-size: 0.8rem;
    border-radius: 4px;
    cursor: pointer;
    outline: none;
}

.debug-select option {
    background: #0a0a1a;
    color: #00ffff;
}

.debug-select:focus {
    box-shadow: 0 0 8px rgba(255, 0, 255, 0.4);
}