/* Signal Keeper specific styles */

.signal-keeper-board {
    width: 100%;
    aspect-ratio: 1 / 1;
    max-height: 70vh;
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: #050507;
    border: 1px solid rgba(139, 108, 255, 0.15);
    box-shadow: inset 0 0 50px rgba(139, 108, 255, 0.05), 0 20px 50px rgba(0, 0, 0, 0.5);
    position: relative;
    cursor: crosshair;
}

.three-canvas-container {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.overlay-canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    pointer-events: none; /* Let clicks pass through to Three.js if needed, though we use window events */
}

/* Custom Overlays for Signal Keeper */
#game-start, #game-over, #error-overlay {
    z-index: 10;
}

/* Make sure the pulse button looks cool when ready */
#btn-pulse {
    transition: all 0.3s ease;
}

#btn-pulse:not(:disabled) {
    background: linear-gradient(180deg, #4cc9f0, #2b8cb8);
    box-shadow: 0 0 15px rgba(76, 201, 240, 0.4);
    border-color: #4cc9f0;
}

#btn-pulse:not(:disabled):hover {
    background: linear-gradient(180deg, #6ee0ff, #3aaae0);
    box-shadow: 0 0 25px rgba(76, 201, 240, 0.6);
}

.volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--accent);
    cursor: pointer;
    box-shadow: 0 0 10px var(--accent-glow);
}

.volume-slider::-moz-range-thumb {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--accent);
    cursor: pointer;
    box-shadow: 0 0 10px var(--accent-glow);
    border: none;
}


/* INSTÄLLNING - Global Mobile Fallback Fix */
html, body {
    overflow-x: hidden !important;
    max-width: 100vw;
}
@media (max-width: 800px) {
    canvas, .game-canvas, #game-container, #game-stage, #app {
        max-width: 100% !important;
        height: auto;
    }
    .panel, .sidebar, .menu, #ui, #overlay {
        max-width: 100% !important;
        box-sizing: border-box;
    }
}
