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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #0a0a0a 0%, #1a1a2e 100%);
    color: #ffffff;
    overflow-x: hidden;
}

.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 2px solid #00ff88;
    position: relative;
    z-index: 100;
}

.header h1 {
    font-size: 1.8rem;
    color: #00ff88;
    text-shadow: 0 0 10px rgba(0, 255, 136, 0.5);
    font-weight: 700;
}

.fps-counter {
    font-family: 'Courier New', monospace;
    font-size: 1.1rem;
    color: #00ffff;
    text-shadow: 0 0 5px rgba(0, 255, 255, 0.3);
}

.main-container {
    display: flex;
    height: calc(100vh - 200px);
    gap: 10px;
    padding: 10px;
}

.left-panel, .right-panel {
    width: 280px;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(10px);
    border: 1px solid #333;
    border-radius: 10px;
    padding: 15px;
    overflow-y: auto;
}

.scene-container {
    flex: 1;
    position: relative;
    border: 2px solid #00ff88;
    border-radius: 10px;
    overflow: hidden;
    background: #000;
}

.tooltip {
    position: absolute;
    background: rgba(0, 0, 0, 0.9);
    color: #00ff88;
    padding: 8px 12px;
    border-radius: 5px;
    font-size: 0.9rem;
    pointer-events: none;
    z-index: 1000;
    display: none;
    border: 1px solid #00ff88;
    max-width: 200px;
}

.info-card {
    background: rgba(0, 255, 136, 0.1);
    border: 1px solid #00ff88;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 15px;
}

.info-card h3 {
    color: #00ff88;
    margin-bottom: 10px;
    font-size: 1.1rem;
}

.spec-item {
    padding: 5px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    font-family: 'Courier New', monospace;
    color: #ccc;
}

.spec-item:last-child {
    border-bottom: none;
}

.achievement-panel {
    background: rgba(255, 170, 0, 0.1);
    border: 1px solid #ffaa00;
    border-radius: 8px;
    padding: 15px;
}

.achievement-panel h3 {
    color: #ffaa00;
    margin-bottom: 10px;
}

.achievement-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.achievement-item:last-child {
    border-bottom: none;
}

.achievement-icon {
    font-size: 1.2rem;
}

.achievement-name {
    font-weight: bold;
    color: #ffaa00;
    font-size: 0.9rem;
}

.achievement-desc {
    font-size: 0.8rem;
    color: #ccc;
}

.control-group, .metrics-group {
    margin-bottom: 20px;
}

.control-group h3, .metrics-group h3 {
    color: #00ffff;
    margin-bottom: 15px;
    font-size: 1.1rem;
    border-bottom: 1px solid #00ffff;
    padding-bottom: 5px;
}

.slider-group {
    margin-bottom: 15px;
}

.slider-group label {
    display: block;
    margin-bottom: 5px;
    color: #ccc;
    font-size: 0.9rem;
}

.slider-group input[type="range"] {
    width: 100%;
    height: 6px;
    background: #333;
    border-radius: 3px;
    outline: none;
    -webkit-appearance: none;
}

.slider-group input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    background: #00ff88;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(0, 255, 136, 0.5);
}

.slider-group input[type="range"]::-moz-range-thumb {
    width: 16px;
    height: 16px;
    background: #00ff88;
    border-radius: 50%;
    cursor: pointer;
    border: none;
    box-shadow: 0 0 10px rgba(0, 255, 136, 0.5);
}

.metric {
    margin-bottom: 15px;
}

.metric label {
    display: block;
    margin-bottom: 5px;
    color: #ccc;
    font-size: 0.9rem;
}

.metric-bar {
    position: relative;
    height: 20px;
    background: #333;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid #555;
}

.metric-fill {
    height: 100%;
    background: linear-gradient(90deg, #00ff88, #00ffff);
    border-radius: 10px;
    transition: width 0.3s ease;
    position: relative;
}

.metric-bar span {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.8rem;
    font-weight: bold;
    color: #fff;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.8);
    z-index: 2;
}

.bottom-panel {
    height: 120px;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(10px);
    border-top: 2px solid #00ff88;
    padding: 15px 20px;
    display: flex;
    gap: 20px;
    align-items: center;
}

.stress-test-section {
    display: flex;
    gap: 10px;
    align-items: center;
}

.stress-test-section h3 {
    color: #ff4444;
    margin-right: 15px;
    font-size: 1.1rem;
}

.stress-btn {
    padding: 10px 15px;
    background: rgba(68, 68, 68, 0.8);
    border: 1px solid #444;
    border-radius: 5px;
    color: #fff;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.stress-btn:hover {
    background: rgba(0, 255, 136, 0.2);
    border-color: #00ff88;
}

.stress-btn.active {
    background: rgba(0, 255, 136, 0.3);
    border-color: #00ff88;
    color: #00ff88;
}

.stress-btn.danger {
    border-color: #ff4444;
    color: #ff4444;
}

.stress-btn.danger:hover {
    background: rgba(255, 68, 68, 0.2);
}

.progress-section {
    flex: 1;
    max-width: 300px;
}

.progress-bar {
    height: 25px;
    background: #333;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    border: 1px solid #555;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #00ff88, #00ffff);
    border-radius: 12px;
    transition: width 0.3s ease;
    width: 0%;
}

.progress-bar span {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    font-size: 0.9rem;
    font-weight: bold;
    color: #fff;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.8);
    z-index: 2;
}

.mode-toggles {
    display: flex;
    gap: 10px;
}

.toggle-btn {
    padding: 10px 15px;
    background: rgba(68, 68, 68, 0.8);
    border: 1px solid #444;
    border-radius: 5px;
    color: #fff;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.toggle-btn:hover {
    background: rgba(0, 136, 255, 0.2);
    border-color: #0088ff;
}

.toggle-btn.active {
    background: rgba(0, 136, 255, 0.3);
    border-color: #0088ff;
    color: #0088ff;
}

.achievement-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: rgba(0, 0, 0, 0.9);
    border: 2px solid #ffaa00;
    border-radius: 10px;
    padding: 15px;
    color: #ffaa00;
    font-weight: bold;
    z-index: 1000;
    animation: slideInRight 0.5s ease-out, fadeOut 0.5s ease-in 3.5s forwards;
    max-width: 250px;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes fadeOut {
    to {
        opacity: 0;
        transform: translateX(100%);
    }
}

/* Responsive Design */
@media (max-width: 1200px) {
    .main-container {
        flex-direction: column;
        height: auto;
    }
    
    .left-panel, .right-panel {
        width: 100%;
        max-height: 200px;
    }
    
    .scene-container {
        height: 400px;
    }
}

@media (max-width: 768px) {
    .header h1 {
        font-size: 1.4rem;
    }
    
    .bottom-panel {
        flex-direction: column;
        height: auto;
        gap: 10px;
    }
    
    .stress-test-section {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .mode-toggles {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .left-panel, .right-panel {
        padding: 10px;
    }
}

/* Cyberpunk glow effects */
.header, .scene-container, .info-card, .achievement-panel {
    box-shadow: 0 0 20px rgba(0, 255, 136, 0.1);
}

.stress-btn.active, .toggle-btn.active {
    box-shadow: 0 0 15px rgba(0, 255, 136, 0.3);
}

/* Scan line effect for retro mode */
body.retro-mode::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(
        0deg,
        transparent,
        transparent 2px,
        rgba(0, 255, 0, 0.03) 2px,
        rgba(0, 255, 0, 0.03) 4px
    );
    pointer-events: none;
    z-index: 1000;
}