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

body {
    font-family: 'Courier New', monospace;
    background: linear-gradient(135deg, #2c1810, #4a3728);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.console-container {
    perspective: 1000px;
}

.console-body {
    background: linear-gradient(145deg, #8B4513, #A0522D, #8B4513);
    background-image: 
        repeating-linear-gradient(90deg, 
            rgba(139, 69, 19, 0.1) 0px, 
            rgba(139, 69, 19, 0.3) 2px, 
            rgba(139, 69, 19, 0.1) 4px),
        repeating-linear-gradient(0deg, 
            rgba(139, 69, 19, 0.05) 0px, 
            rgba(139, 69, 19, 0.2) 1px, 
            rgba(139, 69, 19, 0.05) 2px);
    border-radius: 15px;
    padding: 30px;
    box-shadow: 
        0 20px 40px rgba(0, 0, 0, 0.5),
        inset 0 2px 4px rgba(255, 255, 255, 0.1),
        inset 0 -2px 4px rgba(0, 0, 0, 0.3);
    max-width: 600px;
    margin: 0 auto;
}

.console-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.logo {
    font-size: 24px;
    font-weight: bold;
    color: #FFD700;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
    letter-spacing: 2px;
}

.power-section {
    display: flex;
    align-items: center;
    gap: 10px;
}

.power-switch {
    width: 50px;
    height: 25px;
    background: #333;
    border-radius: 15px;
    position: relative;
    cursor: pointer;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.5);
}

.power-switch.on {
    background: #555;
}

.switch-handle {
    width: 20px;
    height: 20px;
    background: #666;
    border-radius: 50%;
    position: absolute;
    top: 2.5px;
    left: 2.5px;
    transition: transform 0.3s;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.power-switch.on .switch-handle {
    transform: translateX(25px);
    background: #888;
}

.power-led {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #444;
    transition: all 0.3s;
}

.power-led.on {
    background: #FF0000;
    box-shadow: 0 0 10px #FF0000;
}

.screen-section {
    margin: 20px 0;
    display: flex;
    justify-content: center;
}

.screen-bezel {
    background: #111;
    padding: 15px;
    border-radius: 10px;
    box-shadow: 
        inset 0 4px 8px rgba(0, 0, 0, 0.8),
        0 2px 4px rgba(255, 255, 255, 0.1);
    position: relative;
}

#gameCanvas {
    border-radius: 8px;
    background: #000;
    display: block;
    image-rendering: pixelated;
    image-rendering: -moz-crisp-edges;
    image-rendering: crisp-edges;
}

.scan-lines {
    position: absolute;
    top: 15px;
    left: 15px;
    right: 15px;
    bottom: 15px;
    pointer-events: none;
    background: repeating-linear-gradient(
        transparent,
        transparent 2px,
        rgba(255, 255, 255, 0.03) 2px,
        rgba(255, 255, 255, 0.03) 4px
    );
    border-radius: 8px;
}

.controls-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    margin-top: 20px;
}

.player-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.control-label {
    font-size: 12px;
    color: #FFD700;
    font-weight: bold;
}

.paddle-control {
    width: 60px;
    height: 60px;
    background: #333;
    border-radius: 50%;
    position: relative;
    cursor: pointer;
    box-shadow: 
        inset 0 3px 6px rgba(0, 0, 0, 0.5),
        0 2px 4px rgba(255, 255, 255, 0.1);
}

.paddle-knob {
    width: 40px;
    height: 40px;
    background: #666;
    border-radius: 50%;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.center-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.game-switches {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
}

.game-switch {
    background: #444;
    color: #FFD700;
    border: none;
    padding: 8px 12px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 10px;
    font-weight: bold;
    transition: all 0.3s;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.game-switch:hover {
    background: #555;
}

.game-switch.active {
    background: #FFD700;
    color: #333;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.3);
}

.serve-button, .reset-button {
    background: #FF4444;
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
    transition: all 0.3s;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.serve-button:hover, .reset-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.4);
}

.serve-button:active, .reset-button:active {
    transform: translateY(0);
}

.reset-button {
    background: #666;
    margin-top: 5px;
}

.info-panel {
    background: rgba(139, 69, 19, 0.9);
    color: #FFD700;
    padding: 15px;
    border-radius: 10px;
    margin-top: 20px;
    max-height: 60px;
    overflow: hidden;
    transition: max-height 0.3s;
    position: relative;
}

.info-panel.expanded {
    max-height: 200px;
}

#infoToggle {
    position: absolute;
    top: 10px;
    right: 10px;
    background: none;
    border: none;
    color: #FFD700;
    cursor: pointer;
    font-size: 16px;
}

.info-panel h3 {
    margin-bottom: 10px;
}

.info-panel p {
    margin-bottom: 8px;
    font-size: 12px;
    line-height: 1.4;
}

/* Responsive design */
@media (max-width: 600px) {
    .console-body {
        padding: 20px;
    }
    
    .controls-section {
        flex-direction: column;
        gap: 15px;
    }
    
    .game-switches {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    #gameCanvas {
        width: 100%;
        max-width: 400px;
        height: auto;
    }
    
    .logo {
        font-size: 18px;
    }
}

@media (max-width: 480px) {
    .console-top {
        flex-direction: column;
        gap: 10px;
    }
    
    .player-controls {
        flex-direction: row;
        gap: 20px;
    }
}