/* Controls Notification */
.controls-notification {
    position: fixed;
    bottom: 40px;
    right: 40px;
    z-index: 200;
    max-width: 400px;
    animation: slideInUp 0.3s ease-out;
}

.controls-notification.hidden {
    display: none;
}

@keyframes slideInUp {
    from {
        transform: translateY(20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.notification-content {
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(15px);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.8), 
                0 0 20px var(--theme-glow),
                inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.notification-title {
    font-size: 16px;
    font-weight: bold;
    letter-spacing: 2px;
    color: var(--theme-color);
    text-shadow: 0 0 15px var(--theme-glow);
    margin-bottom: 16px;
    text-align: center;
}

.notification-body {
    margin-bottom: 16px;
}

.control-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.control-row:last-child {
    border-bottom: none;
}

.control-key {
    font-family: 'Courier New', monospace;
    font-size: 12px;
    font-weight: bold;
    color: var(--theme-color);
    background: rgba(255, 255, 255, 0.05);
    padding: 4px 10px;
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    min-width: 100px;
    text-align: center;
}

.control-desc {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.8);
    text-align: right;
}

.dismiss-btn {
    width: 100%;
    background: linear-gradient(145deg, #1a1a1a, #0a0a0a);
    border: 2px solid var(--theme-color);
    border-radius: 8px;
    padding: 12px;
    color: var(--theme-color);
    font-family: 'Courier New', monospace;
    font-size: 13px;
    font-weight: bold;
    letter-spacing: 2px;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 0 rgba(0, 0, 0, 0.5), 
                0 0 10px var(--theme-glow),
                inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.dismiss-btn:hover {
    background: linear-gradient(145deg, #2a2a2a, #1a1a1a);
    box-shadow: 0 6px 0 rgba(0, 0, 0, 0.5), 
                0 0 15px var(--theme-glow),
                inset 0 1px 0 rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
}

.dismiss-btn:active {
    transform: translateY(2px);
    box-shadow: 0 2px 0 rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

/* Mobile Controls */
.mobile-controls {
    position: fixed;
    bottom: 20px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    padding: 0 20px;
    z-index: 150;
    pointer-events: none;
    opacity: 0.3; /* Translucent by default */
    transition: opacity 0.3s ease;
}

.mobile-controls.active {
    opacity: 1; /* Solid when active */
}

.mobile-controls.hidden {
    display: none;
}

.mobile-controls > * {
    pointer-events: auto;
}

/* Virtual Joystick */
.virtual-joystick {
    width: 120px;
    height: 120px;
    position: relative;
}

.joystick-base {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.5);
    border: 3px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.8), inset 0 0 15px rgba(0, 0, 0, 0.5);
}

.joystick-stick {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--theme-color);
    border: 3px solid rgba(255, 255, 255, 0.5);
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    box-shadow: 0 0 20px var(--theme-glow), 0 4px 10px rgba(0, 0, 0, 0.5);
    transition: all 0.1s ease;
}

/* Virtual Buttons */
.virtual-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.virtual-btn {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.7);
    border: 3px solid rgba(255, 255, 255, 0.3);
    color: var(--theme-color);
    font-size: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.8), 0 0 10px var(--theme-glow);
    transition: all 0.15s ease;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.virtual-btn:active {
    background: rgba(0, 50, 0, 0.9);
    border-color: var(--theme-color);
    box-shadow: 0 0 25px var(--theme-glow), inset 0 0 15px var(--theme-glow);
    transform: scale(0.95);
}

.boost-btn {
    background: linear-gradient(145deg, rgba(0, 100, 0, 0.7), rgba(0, 50, 0, 0.7));
}

/* Hide mobile-only controls on desktop */
@media (min-width: 769px) {
    .mobile-only {
        display: none !important;
    }
    
    .mobile-controls {
        display: none !important;
    }
}

/* Show mobile controls on mobile */
@media (max-width: 768px) {
    .controls-notification {
        bottom: 20px;
        right: 20px;
        left: 20px;
        max-width: none;
    }
}

