/* Game Integration Styles */
/* Integrates visual elements from the actual p(Doom)1 game */

:root {
    /* Game-inspired color palette from UI */
    --game-money-color: #4caf50;      /* Money green */
    --game-doom-color: #ff4444;       /* Doom red */
    --game-ap-color: #ffff00;         /* Action Points yellow */
    --game-staff-color: #87ceeb;      /* Staff blue */
    --game-reputation-color: #daa520; /* Reputation gold */
    --game-compute-color: #64ff96;    /* Compute green */
    --game-research-color: #96c8ff;   /* Research blue */
    --game-papers-color: #ffc864;     /* Papers orange */
    
    /* Typography matching game */
    --game-font-family: 'Courier New', 'Consolas', monospace;
    --game-retro-glow: 0 0 8px rgba(0, 255, 65, 0.4);
    
    /* Game UI dimensions */
    --game-button-height: 42px;
    --game-spacing: 12px;
}

/* Game-style buttons */
.game-button {
    font-family: var(--game-font-family);
    background: linear-gradient(145deg, #404040, #2a2a2a);
    border: 2px solid var(--accent-primary);
    color: var(--text-primary);
    padding: 8px 16px;
    border-radius: var(--radius-md);
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all var(--duration-base) var(--easing);
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.game-button:hover {
    background: linear-gradient(145deg, #505050, #3a3a3a);
    box-shadow: var(--game-retro-glow);
    transform: translateY(-1px);
}

.game-button:active {
    transform: translateY(0);
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* Resource display like in-game */
.resource-display {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: var(--game-font-family);
    font-weight: bold;
    padding: 4px 8px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: var(--radius-sm);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.resource-icon {
    width: 16px;
    height: 16px;
    display: inline-block;
    position: relative;
}

/* 8-bit style icons using CSS */
.resource-icon.money::before {
    content: '$';
    color: var(--game-money-color);
    font-weight: bold;
}

.resource-icon.doom::before {
    content: '☠';
    color: var(--game-doom-color);
}

.resource-icon.ap::before {
    content: '⚡';
    color: var(--game-ap-color);
}

.resource-icon.staff::before {
    content: '👤';
    color: var(--game-staff-color);
}

/* Loading states with game-style animations */
.loading-skeleton {
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(0, 255, 65, 0.1) 50%, 
        transparent 100%
    );
    background-size: 200% 100%;
    animation: skeleton-pulse 1.5s ease-in-out infinite;
}

@keyframes skeleton-pulse {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Error boundaries with game styling */
.error-boundary {
    background: linear-gradient(145deg, #4a2020, #2a1010);
    border: 2px solid var(--game-doom-color);
    border-radius: var(--radius-lg);
    padding: 24px;
    margin: 16px 0;
    font-family: var(--game-font-family);
}

.error-boundary h3 {
    color: var(--game-doom-color);
    margin: 0 0 12px 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.error-boundary h3::before {
    content: '⚠';
    font-size: 1.2em;
}

.error-boundary p {
    margin: 8px 0;
    color: var(--text-secondary);
    line-height: 1.5;
}

.error-boundary .retry-button {
    margin-top: 16px;
    background: var(--game-doom-color);
    border: none;
    color: white;
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    font-family: var(--game-font-family);
    font-weight: bold;
    cursor: pointer;
    transition: all var(--duration-fast) ease;
}

.error-boundary .retry-button:hover {
    background: #ff6666;
    transform: translateY(-1px);
}

/* Game-style progress bars */
.progress-bar {
    width: 100%;
    height: 8px;
    background: rgba(70, 50, 50, 1);
    border-radius: 4px;
    overflow: hidden;
    position: relative;
}

.progress-bar .fill {
    height: 100%;
    background: linear-gradient(90deg, var(--game-doom-color), #ff6666);
    transition: width 0.3s ease;
    position: relative;
}

.progress-bar .fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(255, 255, 255, 0.3) 50%, 
        transparent 100%
    );
    animation: progress-shine 2s ease-in-out infinite;
}

@keyframes progress-shine {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

/* Icon placeholders with retro style */
.placeholder-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    background: linear-gradient(145deg, #333, #222);
    border: 1px solid var(--border-color);
    border-radius: 3px;
    font-size: 12px;
    font-weight: bold;
    color: var(--accent-primary);
    font-family: var(--game-font-family);
}

/* Responsive game elements */
@media (max-width: 768px) {
    .resource-display {
        gap: 4px;
        padding: 3px 6px;
        font-size: 0.9em;
    }
    
    .game-button {
        padding: 6px 12px;
        font-size: 0.9em;
    }
}