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

body {
    font-family: 'Courier New', monospace;
    background: #0a0a0f;
    color: #fff;
    overflow: hidden;
    height: 100vh;
    width: 100vw;
}

#game-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

#ui-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10;
    pointer-events: none;
}

.screen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background: rgba(10, 10, 15, 0.95);
    pointer-events: auto;
}

.screen.active {
    display: flex;
}

.logo {
    text-align: center;
    margin-bottom: 3rem;
}

.logo h1 {
    font-size: 4rem;
    background: linear-gradient(135deg, #00ff88, #00ccff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 30px rgba(0, 255, 136, 0.5);
    animation: glow 2s ease-in-out infinite;
}

@keyframes glow {
    0%, 100% { filter: brightness(1); }
    50% { filter: brightness(1.3); }
}

.tagline {
    color: #888;
    font-size: 1.2rem;
    margin-top: 0.5rem;
}

.menu-options {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    width: 300px;
}

.btn-primary, .btn-secondary {
    padding: 1rem 2rem;
    font-size: 1.2rem;
    font-family: 'Courier New', monospace;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.btn-primary {
    background: linear-gradient(135deg, #00ff88, #00ccff);
    color: #0a0a0f;
    font-weight: bold;
}

.btn-primary:hover {
    transform: scale(1.05);
    box-shadow: 0 0 20px rgba(0, 255, 136, 0.5);
}

.btn-secondary {
    background: transparent;
    color: #00ff88;
    border: 2px solid #00ff88;
}

.btn-secondary:hover {
    background: rgba(0, 255, 136, 0.1);
    box-shadow: 0 0 15px rgba(0, 255, 136, 0.3);
}

.character-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    margin: 2rem 0;
}

.character-card {
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid #333;
    border-radius: 10px;
    padding: 1.5rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
}

.character-card:hover {
    border-color: #00ff88;
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 255, 136, 0.2);
}

.character-card.selected {
    border-color: #00ff88;
    background: rgba(0, 255, 136, 0.1);
}

.character-card .preview {
    width: 80px;
    height: 80px;
    margin: 0 auto 1rem;
    border-radius: 10px;
}

.legacy-preview {
    background: linear-gradient(135deg, #c4a574, #8b7355);
}

.rgb-preview {
    background: linear-gradient(135deg, #ff0080, #ff8c00, #40ff00, #00ff88, #00ccff, #8000ff);
}

.ghost-preview {
    background: linear-gradient(135deg, rgba(0, 150, 255, 0.6), rgba(0, 200, 255, 0.3));
    animation: glitch 0.5s infinite;
}

.manager-preview {
    background: linear-gradient(135deg, #ff6b00, #ffaa00);
}

@keyframes glitch {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.character-card h3 {
    margin-bottom: 0.5rem;
    color: #fff;
}

.character-card p {
    color: #888;
    font-size: 0.9rem;
}

.cable-selection {
    margin: 2rem 0;
    text-align: center;
}

.cable-selection h3 {
    margin-bottom: 1rem;
    color: #00ff88;
}

.cable-options {
    display: flex;
    gap: 1rem;
}

.cable-btn {
    padding: 0.8rem 1.5rem;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid #333;
    color: #fff;
    cursor: pointer;
    transition: all 0.3s;
    font-family: 'Courier New', monospace;
}

.cable-btn:hover, .cable-btn.active {
    border-color: #00ff88;
    background: rgba(0, 255, 136, 0.1);
}

#hud {
    background: transparent;
    pointer-events: none;
}

#hud > * {
    pointer-events: auto;
}

.hud-top {
    position: absolute;
    top: 20px;
    left: 20px;
    right: 20px;
    display: flex;
    justify-content: space-between;
}

.timer, .height-indicator {
    background: rgba(0, 0, 0, 0.7);
    padding: 10px 20px;
    border-radius: 10px;
    font-size: 1.5rem;
    border: 1px solid #00ff88;
}

.hud-bottom {
    position: absolute;
    bottom: 20px;
    left: 20px;
    right: 20px;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
}

.ability-bar {
    display: flex;
    gap: 1rem;
}

.ability {
    background: rgba(0, 0, 0, 0.7);
    padding: 15px 25px;
    border-radius: 10px;
    border: 2px solid #333;
    position: relative;
    overflow: hidden;
}

.ability.active {
    border-color: #00ff88;
}

.ability .cooldown {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    background: rgba(255, 0, 0, 0.3);
    width: 0%;
    transition: width 0.1s linear;
}

.cable-status {
    background: rgba(0, 0, 0, 0.7);
    padding: 15px 25px;
    border-radius: 10px;
    border: 1px solid #ff6b00;
}

.cable-health {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.cable-health .bar {
    width: 200px;
    height: 10px;
    background: #333;
    border-radius: 5px;
    overflow: hidden;
}

#tension-fill {
    height: 100%;
    background: linear-gradient(90deg, #ff6b00, #ffaa00);
    width: 0%;
    transition: width 0.2s;
}

.controls-hint {
    position: absolute;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.7);
    padding: 10px 20px;
    border-radius: 10px;
    color: #888;
}

#game-over {
    text-align: center;
}

#result-title {
    font-size: 3rem;
    background: linear-gradient(135deg, #00ff88, #00ccff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 2rem;
}

.stats {
    display: flex;
    gap: 3rem;
    margin-bottom: 2rem;
}

.stat {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.stat .label {
    color: #888;
    font-size: 1rem;
}

.stat .value {
    font-size: 2.5rem;
    color: #00ff88;
}

#game-over button {
    margin: 0.5rem;
}
