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

body {
    font-family: 'Space Mono', monospace;
    background: #000;
    overflow: hidden;
    user-select: none;
    touch-action: none;
}

#game-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    cursor: crosshair;
    z-index: 1;
}

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

#top-ui {
    position: absolute;
    top: 10px;
    left: 10px;
    right: 10px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 10px;
    pointer-events: auto;
    flex-wrap: wrap;
}

#object-selector {
    background: rgba(0, 0, 0, 0.6);
    padding: 10px;
    border-radius: 8px;
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    max-width: 300px;
}

#object-selector h3 {
    color: white;
    margin-bottom: 8px;
    font-size: 12px;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.object-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
    min-width: 180px;
}

.object-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: white;
    padding: 6px 3px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 11px;
    transition: all 0.2s ease;
    text-align: center;
}

.object-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-1px);
}

.object-btn.active {
    background: rgba(255, 100, 100, 0.4);
    border-color: rgba(255, 100, 100, 0.6);
    box-shadow: 0 0 10px rgba(255, 100, 100, 0.2);
}

#controls {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

#controls button {
    background: rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: white;
    padding: 6px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 11px;
    transition: all 0.2s ease;
    backdrop-filter: blur(8px);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

#controls button:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-1px);
}

#controls button.active {
    background: rgba(100, 255, 100, 0.2);
    border-color: rgba(100, 255, 100, 0.4);
}

#crosshair {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: rgba(255, 255, 255, 0.6);
    font-size: 20px;
    pointer-events: none;
}

#trajectory-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none;
    z-index: 5;
}

@media (max-width: 768px) {
    #top-ui {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }
    
    .object-grid {
        grid-template-columns: repeat(3, 1fr);
        min-width: auto;
    }
    
    .object-btn {
        font-size: 10px;
        padding: 5px 2px;
    }
    
    #controls {
        justify-content: space-between;
    }
    
    #controls button {
        flex: 1;
        min-width: 50px;
        font-size: 9px;
        padding: 6px 4px;
    }
}

@media (max-width: 480px) {
    #top-ui {
        top: 5px;
        left: 5px;
        right: 5px;
    }
    
    #object-selector {
        padding: 8px;
    }
    
    .object-grid {
        gap: 4px;
    }
    
    .object-btn {
        font-size: 9px;
        padding: 4px 2px;
    }
}

