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

body {
    background: linear-gradient(135deg, #0a0a1a 0%, #1a1a2e 50%, #2a1a3e 100%);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-family: 'Space Grotesk', sans-serif;
    overflow: hidden;
}

#game-container {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px;
}

#canvas {
    border: 4px solid #DAA520;
    border-radius: 8px;
    box-shadow: 
        0 0 30px rgba(218, 165, 32, 0.4),
        0 0 60px rgba(139, 0, 0, 0.2),
        inset 0 0 20px rgba(0, 0, 0, 0.5);
    cursor: pointer;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    max-width: 100vw;
    max-height: calc(100vh - 60px);
}

#canvas:active {
    box-shadow: 
        0 0 40px rgba(255, 215, 0, 0.6),
        0 0 80px rgba(220, 20, 60, 0.3),
        inset 0 0 20px rgba(0, 0, 0, 0.5);
}

#ui-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

footer {
    margin-top: 15px;
    text-align: center;
}

footer a {
    color: #DAA520;
    text-decoration: none;
    font-size: 14px;
    font-family: 'Space Grotesk', sans-serif;
    opacity: 0.7;
    transition: opacity 0.3s, color 0.3s;
}

footer a:hover {
    opacity: 1;
    color: #FFD700;
    text-decoration: underline;
}

@media (max-width: 820px) {
    #game-container {
        padding: 5px;
    }
    
    footer {
        margin-top: 10px;
    }
    
    footer a {
        font-size: 12px;
    }
}

/* Prevent text selection during gameplay */
#game-container {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

/* Loading animation for slow connections */
#canvas {
    background: #1a1a2e;
}

/* Subtle scanline effect overlay */
#game-container::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    background: repeating-linear-gradient(
        0deg,
        rgba(0, 0, 0, 0.03) 0px,
        rgba(0, 0, 0, 0.03) 1px,
        transparent 1px,
        transparent 2px
    );
    border-radius: 8px;
}