body {
    font-family: 'Press Start 2P', monospace;
    background: #000;
    margin: 0;
    padding: 0;
    overflow: hidden;
}

.virtual-boy-container {
    display: flex;
    flex-direction: column;
    height: 100vh;
    background: linear-gradient(135deg, #1a0000, #000000);
}

.virtual-boy-frame {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    background: radial-gradient(ellipse at center, #330000 0%, #000000 70%);
    position: relative;
}

.virtual-boy-frame::before {
    content: '';
    position: absolute;
    top: 10px;
    left: 10px;
    right: 10px;
    bottom: 10px;
    border: 4px solid #660000;
    border-radius: 20px;
    pointer-events: none;
    box-shadow: 
        inset 0 0 50px rgba(255, 0, 0, 0.1),
        0 0 30px rgba(255, 0, 0, 0.2);
}

.virtual-boy-screen {
    width: 90%;
    max-width: 600px;
    height: 70vh;
    background: #000000;
    border: 6px solid #990000;
    border-radius: 15px;
    box-shadow: 
        inset 0 0 20px rgba(255, 0, 0, 0.3),
        0 0 40px rgba(255, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
}

.virtual-boy-screen::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: repeating-linear-gradient(
        transparent,
        transparent 2px,
        rgba(255, 0, 0, 0.03) 2px,
        rgba(255, 0, 0, 0.03) 4px
    );
    pointer-events: none;
    z-index: 10;
}

.virtual-boy-screen::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(
        ellipse at center,
        transparent 0%,
        rgba(0, 0, 0, 0.1) 70%,
        rgba(0, 0, 0, 0.3) 100%
    );
    pointer-events: none;
    z-index: 9;
}

.controls-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 40px;
    background: linear-gradient(to bottom, #2a0000, #000000);
    border-top: 2px solid #660000;
    min-height: 120px;
}

.dpad {
    position: relative;
    width: 80px;
    height: 80px;
}

.dpad > div {
    position: absolute;
    background: #990000;
    color: #FF3333;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    cursor: pointer;
    border: 2px solid #CC0000;
    transition: all 0.1s;
    user-select: none;
}

.dpad > div:hover {
    background: #CC0000;
    color: #FFFFFF;
    transform: scale(0.95);
}

.dpad-up, .dpad-down {
    width: 30px;
    height: 25px;
    left: 25px;
}

.dpad-up { top: 0; border-radius: 6px 6px 0 0; }
.dpad-down { bottom: 0; border-radius: 0 0 6px 6px; }

.dpad-left, .dpad-right {
    width: 25px;
    height: 30px;
    top: 25px;
}

.dpad-left { left: 0; border-radius: 6px 0 0 6px; }
.dpad-right { right: 0; border-radius: 0 6px 6px 0; }

.action-buttons {
    display: flex;
    gap: 15px;
    align-items: center;
}

.button-a, .button-b {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: #990000;
    color: #FF3333;
    border: 3px solid #CC0000;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.1s;
    user-select: none;
}

.button-a:hover, .button-b:hover {
    background: #CC0000;
    color: #FFFFFF;
    transform: scale(0.95);
}

.back-button {
    background: #660000;
    color: #FF3333;
    border: 2px solid #990000;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    font-family: inherit;
    font-size: 10px;
}

.back-button:hover {
    background: #990000;
    color: #FFFFFF;
}

.red-tint {
    filter: hue-rotate(0deg) sepia(100%) saturate(200%) brightness(0.8) contrast(1.2);
}

.footer {
    padding: 10px;
    background: #000000;
    border-top: 1px solid #330000;
}

/* Glow effects */
.text-red-500, .text-red-600, .text-red-700 {
    text-shadow: 0 0 10px currentColor;
}

/* Animations */
@keyframes flicker {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.8; }
}

.virtual-boy-screen {
    animation: flicker 4s infinite ease-in-out;
}

/* Canvas styling */
canvas {
    image-rendering: pixelated;
    image-rendering: -moz-crisp-edges;
    image-rendering: crisp-edges;
    background: #000000;
}

/* Button press animations */
.dpad > div:active, .button-a:active, .button-b:active {
    transform: scale(0.9);
    box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.5);
}

/* Responsive design */
@media (max-width: 768px) {
    .virtual-boy-screen {
        width: 95%;
        height: 60vh;
    }
    
    .controls-container {
        padding: 15px 20px;
        min-height: 100px;
    }
    
    .dpad {
        width: 60px;
        height: 60px;
    }
    
    .dpad > div {
        font-size: 12px;
    }
    
    .button-a, .button-b {
        width: 40px;
        height: 40px;
        font-size: 12px;
    }
}

/* Custom scrollbar for webkit browsers */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #000000;
}

::-webkit-scrollbar-thumb {
    background: #660000;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #990000;
}