/* Custom retro styles */
@import url('https://fonts.googleapis.com/css2?family=Press+Start+2P&display=swap');

.font-pixel {
    font-family: 'Press Start 2P', 'Courier New', monospace;
}

.retro-glow {
    text-shadow: 0 0 10px currentColor, 0 0 20px currentColor, 0 0 30px currentColor;
    animation: glow 2s ease-in-out infinite alternate;
}

@keyframes glow {
    from { text-shadow: 0 0 5px currentColor, 0 0 10px currentColor, 0 0 15px currentColor; }
    to { text-shadow: 0 0 10px currentColor, 0 0 20px currentColor, 0 0 30px currentColor; }
}

.retro-panel {
    background: linear-gradient(145deg, rgba(0, 139, 139, 0.3), rgba(30, 58, 138, 0.3));
    border: 2px solid #fbbf24;
    border-radius: 12px;
    box-shadow: 
        inset 2px 2px 5px rgba(255, 255, 255, 0.2),
        inset -2px -2px 5px rgba(0, 0, 0, 0.2),
        0 5px 15px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
}

.retro-button {
    border: 2px solid #333;
    box-shadow: 
        inset 2px 2px 3px rgba(255, 255, 255, 0.3),
        inset -2px -2px 3px rgba(0, 0, 0, 0.3),
        2px 2px 5px rgba(0, 0, 0, 0.5);
    transition: all 0.1s ease;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

.retro-button:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 
        inset 2px 2px 3px rgba(255, 255, 255, 0.3),
        inset -2px -2px 3px rgba(0, 0, 0, 0.3),
        3px 3px 8px rgba(0, 0, 0, 0.5);
}

.retro-button:active:not(:disabled) {
    transform: translateY(1px);
    box-shadow: 
        inset 3px 3px 5px rgba(0, 0, 0, 0.3),
        inset -1px -1px 2px rgba(255, 255, 255, 0.2);
}

.room-tile {
    background: linear-gradient(145deg, rgba(16, 185, 129, 0.2), rgba(251, 191, 36, 0.2));
    border: 2px solid #10b981;
    border-radius: 8px;
    padding: 16px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.room-tile:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.4);
    border-color: #fbbf24;
    background: linear-gradient(145deg, rgba(251, 191, 36, 0.3), rgba(16, 185, 129, 0.3));
}

.room-tile.selected {
    border-color: #f97316;
    background: linear-gradient(145deg, rgba(249, 115, 22, 0.3), rgba(251, 191, 36, 0.3));
    transform: scale(1.05);
}

.room-tile:active {
    animation: clickPulse 0.2s ease;
}

@keyframes clickPulse {
    0% { transform: scale(1.05); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1.05); }
}

.furniture-card {
    background: linear-gradient(145deg, rgba(30, 58, 138, 0.4), rgba(0, 139, 139, 0.4));
    border: 1px solid rgba(251, 191, 36, 0.5);
    transition: all 0.3s ease;
}

.furniture-card:hover {
    border-color: #fbbf24;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    transform: translateY(-1px);
}

.floating-number {
    position: absolute;
    color: #10b981;
    font-weight: bold;
    font-size: 14px;
    pointer-events: none;
    animation: float 1s ease-out forwards;
    z-index: 100;
}

@keyframes float {
    0% {
        opacity: 1;
        transform: translateY(0);
    }
    100% {
        opacity: 0;
        transform: translateY(-50px);
    }
}

/* Need bars custom styling */
.need-bar {
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { background-position: -100px; }
    100% { background-position: 100px; }
}

/* Responsive design */
@media (max-width: 768px) {
    .retro-panel {
        margin-bottom: 1rem;
    }
    
    .room-tile {
        padding: 12px;
    }
    
    .room-tile .text-4xl {
        font-size: 2rem;
    }
    
    .font-pixel {
        font-size: 1.5rem;
    }
}

/* Background animation */
body {
    background-attachment: fixed;
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 50%, rgba(16, 185, 129, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(251, 191, 36, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 80%, rgba(249, 115, 22, 0.1) 0%, transparent 50%);
    animation: backgroundShift 10s ease-in-out infinite alternate;
    pointer-events: none;
    z-index: -1;
}

@keyframes backgroundShift {
    0% { transform: translateX(-10px) translateY(-5px); }
    100% { transform: translateX(10px) translateY(5px); }
}

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

::-webkit-scrollbar-track {
    background: rgba(0, 139, 139, 0.3);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(45deg, #fbbf24, #f97316);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(45deg, #f97316, #fbbf24);
}