/* ==================== SIDE PANEL GAMES ==================== */
/* Desktop-only retro mini-games */

@import url('https://fonts.googleapis.com/css2?family=Press+Start+2P&display=swap');

#side-games-container {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    z-index: 100;
    display: flex;
    justify-content: space-between;
    padding: 100px 20px 20px 20px;
}

.side-panel {
    pointer-events: auto;
    width: 280px;
    background: linear-gradient(180deg,
            rgba(10, 10, 20, 0.95) 0%,
            rgba(20, 20, 35, 0.95) 100%);
    border: 2px solid #333;
    border-radius: 8px;
    padding: 12px;
    box-shadow:
        0 0 20px rgba(0, 255, 136, 0.1),
        inset 0 0 30px rgba(0, 0, 0, 0.5);
    position: relative;
    overflow: hidden;
}

/* CRT scanline effect */
.side-panel::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: repeating-linear-gradient(0deg,
            transparent,
            transparent 2px,
            rgba(0, 0, 0, 0.1) 2px,
            rgba(0, 0, 0, 0.1) 4px);
    pointer-events: none;
    z-index: 10;
}

/* Retro corner decorations */
.side-panel::after {
    content: '';
    position: absolute;
    top: 4px;
    left: 4px;
    right: 4px;
    bottom: 4px;
    border: 1px solid rgba(0, 255, 136, 0.2);
    border-radius: 4px;
    pointer-events: none;
}

.left-panel {
    border-color: #00ff88;
    box-shadow:
        0 0 20px rgba(0, 255, 136, 0.2),
        0 0 40px rgba(0, 255, 136, 0.1),
        inset 0 0 30px rgba(0, 0, 0, 0.5);
}

.right-panel {
    border-color: #ff4444;
    box-shadow:
        0 0 20px rgba(255, 68, 68, 0.2),
        0 0 40px rgba(255, 68, 68, 0.1),
        inset 0 0 30px rgba(0, 0, 0, 0.5);
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.game-title {
    font-family: 'Press Start 2P', monospace;
    font-size: 10px;
    color: #fff;
    text-shadow: 0 0 10px currentColor;
}

.left-panel .game-title {
    color: #00ff88;
}

.right-panel .game-title {
    color: #ff4444;
}

.game-score {
    font-family: 'Press Start 2P', monospace;
    font-size: 12px;
    color: #ffff00;
    text-shadow: 0 0 10px #ffff00;
}

#snake-canvas,
#invaders-canvas {
    display: block;
    margin: 0 auto;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    image-rendering: pixelated;
    image-rendering: crisp-edges;
}

#snake-canvas {
    box-shadow: 0 0 10px rgba(0, 255, 136, 0.3);
}

#invaders-canvas {
    box-shadow: 0 0 10px rgba(255, 68, 68, 0.3);
}

.game-controls {
    margin-top: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
}

.control-hint {
    font-family: 'Press Start 2P', monospace;
    font-size: 8px;
    color: #888;
    text-transform: uppercase;
}

.game-btn {
    font-family: 'Press Start 2P', monospace;
    font-size: 9px;
    padding: 8px 16px;
    background: linear-gradient(180deg, #333 0%, #222 100%);
    border: 1px solid #555;
    border-radius: 4px;
    color: #fff;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: uppercase;
}

.game-btn:hover {
    background: linear-gradient(180deg, #444 0%, #333 100%);
    border-color: #666;
    transform: scale(1.05);
}

.left-panel .game-btn:hover {
    box-shadow: 0 0 10px rgba(0, 255, 136, 0.5);
    border-color: #00ff88;
}

.right-panel .game-btn:hover {
    box-shadow: 0 0 10px rgba(255, 68, 68, 0.5);
    border-color: #ff4444;
}

/* Responsive - hide on smaller screens */
@media (max-width: 1400px) {
    #side-games-container {
        display: none !important;
    }
}

/* Animation for panel appearance */
@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.left-panel {
    animation: slideInLeft 0.5s ease-out;
}

.right-panel {
    animation: slideInRight 0.5s ease-out;
}

/* Glow pulse animation */
@keyframes glowPulse {

    0%,
    100% {
        box-shadow:
            0 0 20px rgba(0, 255, 136, 0.2),
            0 0 40px rgba(0, 255, 136, 0.1),
            inset 0 0 30px rgba(0, 0, 0, 0.5);
    }

    50% {
        box-shadow:
            0 0 30px rgba(0, 255, 136, 0.3),
            0 0 60px rgba(0, 255, 136, 0.15),
            inset 0 0 30px rgba(0, 0, 0, 0.5);
    }
}

.left-panel:hover {
    animation: glowPulse 2s ease-in-out infinite;
}

@keyframes glowPulseRed {

    0%,
    100% {
        box-shadow:
            0 0 20px rgba(255, 68, 68, 0.2),
            0 0 40px rgba(255, 68, 68, 0.1),
            inset 0 0 30px rgba(0, 0, 0, 0.5);
    }

    50% {
        box-shadow:
            0 0 30px rgba(255, 68, 68, 0.3),
            0 0 60px rgba(255, 68, 68, 0.15),
            inset 0 0 30px rgba(0, 0, 0, 0.5);
    }
}

.right-panel:hover {
    animation: glowPulseRed 2s ease-in-out infinite;
}