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

body {
    font-family: 'Courier New', monospace;
    background: linear-gradient(135deg, #0a0a0a 0%, #1a1a2e 50%, #16213e 100%);
    color: #ffffff;
    min-height: 100vh;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

header {
    text-align: center;
    margin-bottom: 30px;
}

header h1 {
    font-size: 2.5rem;
    background: linear-gradient(45deg, #ff0080, #00ff80, #0080ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 10px;
    text-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
}

header p {
    color: #aaaaaa;
    font-size: 1.1rem;
}

.main-area {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
    flex-wrap: wrap;
    justify-content: center;
}

#canvas {
    border: 2px solid #333;
    border-radius: 10px;
    background: #000;
    box-shadow: 0 0 30px rgba(0, 255, 255, 0.3);
    cursor: crosshair;
}

.controls-panel {
    background: rgba(0, 0, 0, 0.7);
    border: 1px solid #333;
    border-radius: 10px;
    padding: 20px;
    min-width: 200px;
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.control-group {
    margin-bottom: 15px;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.control-group label {
    color: #00ff80;
    font-weight: bold;
    font-size: 0.9rem;
}

.control-group input[type="range"] {
    width: 100%;
    height: 6px;
    background: #333;
    border-radius: 3px;
    outline: none;
    cursor: pointer;
}

.control-group input[type="range"]::-webkit-slider-thumb {
    appearance: none;
    width: 16px;
    height: 16px;
    background: #00ff80;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(0, 255, 128, 0.5);
}

.control-group select {
    background: #222;
    color: #fff;
    border: 1px solid #555;
    border-radius: 5px;
    padding: 5px;
    font-family: inherit;
}

.control-group button {
    background: linear-gradient(45deg, #333, #555);
    color: #fff;
    border: 1px solid #666;
    border-radius: 5px;
    padding: 8px 12px;
    cursor: pointer;
    font-family: inherit;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.control-group button:hover {
    background: linear-gradient(45deg, #555, #777);
    box-shadow: 0 0 10px rgba(0, 255, 255, 0.3);
}

.control-group button:active {
    transform: translateY(1px);
}

.control-group div {
    display: flex;
    align-items: center;
    gap: 10px;
}

#octaveDisplay, #beamCountDisplay, #volumeDisplay {
    color: #00ff80;
    font-weight: bold;
    min-width: 30px;
    text-align: center;
}

.oscilloscope-container {
    background: rgba(0, 0, 0, 0.8);
    border: 1px solid #333;
    border-radius: 10px;
    padding: 20px;
    text-align: center;
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.oscilloscope-container h3 {
    color: #00ff00;
    margin-bottom: 15px;
    font-size: 1.2rem;
}

#oscilloscope {
    border: 2px solid #006600;
    border-radius: 5px;
    background: #001100;
    margin-bottom: 10px;
    box-shadow: 0 0 20px rgba(0, 255, 0, 0.2);
}

.osc-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.osc-controls input[type="range"] {
    width: 150px;
}

.osc-controls label {
    color: #00ff00;
    font-size: 0.9rem;
}

footer {
    text-align: center;
    margin-top: 40px;
    padding: 20px;
    border-top: 1px solid #333;
    color: #888;
}

footer a {
    color: #00ff80;
    text-decoration: none;
    transition: color 0.3s ease;
}

footer a:hover {
    color: #fff;
    text-shadow: 0 0 10px rgba(0, 255, 128, 0.5);
}

/* Responsive design */
@media (max-width: 768px) {
    .main-area {
        flex-direction: column;
        align-items: center;
    }
    
    .controls-panel {
        width: 100%;
        max-width: 400px;
    }
    
    header h1 {
        font-size: 2rem;
    }
    
    #canvas {
        width: 100%;
        max-width: 400px;
        height: 300px;
    }
    
    #oscilloscope {
        width: 100%;
        max-width: 350px;
        height: 150px;
    }
}

/* Glow animations */
@keyframes glow {
    0%, 100% { box-shadow: 0 0 20px rgba(0, 255, 255, 0.3); }
    50% { box-shadow: 0 0 40px rgba(0, 255, 255, 0.6); }
}

#canvas:hover {
    animation: glow 2s ease-in-out infinite;
}

/* Button active states */
.control-group button.active {
    background: linear-gradient(45deg, #00ff80, #00cc66);
    color: #000;
    box-shadow: 0 0 15px rgba(0, 255, 128, 0.5);
}