/* ===== ENHANCED UX IMPROVEMENTS ===== */

/* Status Bar */
.terminal-status-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 32px;
  background: rgba(0, 0, 0, 0.8);
  border-top: 1px solid var(--primary-green);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  font-size: 12px;
  backdrop-filter: blur(8px);
  z-index: 1000;
  transform: translateY(100%);
  transition: transform 0.3s ease;
}

.terminal-status-bar.show {
  transform: translateY(0);
}

.status-section {
  display: flex;
  align-items: center;
  gap: 16px;
}

.status-item {
  display: flex;
  align-items: center;
  gap: 4px;
  color: var(--primary-green);
}

.status-progress {
  width: 80px;
  height: 4px;
  background: rgba(0, 255, 0, 0.2);
  border-radius: 2px;
  overflow: hidden;
}

.status-progress-fill {
  height: 100%;
  background: var(--primary-green);
  transition: width 0.3s ease;
  border-radius: 2px;
}

.status-tip {
  color: #888;
  font-style: italic;
}

/* Enhanced Help Categories */
.step {
  margin: 8px 0;
  padding-left: 16px;
  position: relative;
}

.step::before {
  content: '▶';
  position: absolute;
  left: 0;
  color: var(--primary-green);
}

.cmd {
  background: rgba(0, 255, 0, 0.2);
  padding: 2px 6px;
  border-radius: 4px;
  color: var(--primary-green);
  font-weight: bold;
  font-family: monospace;
}

.feature {
  display: block;
  color: var(--primary-green);
  font-weight: bold;
  margin: 12px 0 4px 0;
}

.feature-desc {
  display: block;
  color: #ccc;
  margin-left: 8px;
  font-size: 0.9em;
}

.popular-cmd {
  display: inline-block;
  width: 200px;
  color: var(--primary-green);
  font-weight: bold;
}

.popular-desc {
  color: #ccc;
}

.tip {
  display: block;
  margin: 6px 0;
  padding-left: 8px;
  border-left: 2px solid var(--primary-green);
  color: #ddd;
}

.history-item {
  display: block;
  margin: 4px 0;
  color: #ccc;
}

/* Enhanced Notifications */
.command-notification {
  position: fixed;
  top: 20px;
  right: 20px;
  background: rgba(0, 0, 0, 0.9);
  border: 1px solid var(--primary-green);
  border-radius: 8px;
  padding: 12px 16px;
  color: var(--primary-green);
  font-size: 13px;
  z-index: 1002;
  animation: slideInRight 0.3s ease;
  max-width: 280px;
}

.command-notification.success {
  border-color: #4CAF50;
  color: #4CAF50;
}

.command-notification.achievement {
  border-color: #FFD700;
  color: #FFD700;
  background: rgba(255, 215, 0, 0.1);
}

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

/* Enhanced Loading States */
.loading-container {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px;
  border: 1px solid var(--primary-green);
  border-radius: 6px;
  background: rgba(0, 255, 0, 0.05);
  margin: 8px 0;
}

.loading-spinner {
  display: inline-block;
  width: 16px;
  height: 16px;
  border: 2px solid rgba(0, 255, 0, 0.3);
  border-top: 2px solid var(--primary-green);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

.loading-text {
  color: var(--primary-green);
}

/* Command Discovery Indicators */
.discovery-badge {
  display: inline-block;
  background: linear-gradient(45deg, #FFD700, #FFA500);
  color: #000;
  padding: 2px 6px;
  border-radius: 10px;
  font-size: 10px;
  font-weight: bold;
  margin-left: 8px;
  animation: pulse 2s infinite;
}

.command-discovered {
  position: relative;
}

.command-discovered::after {
  content: '✨';
  position: absolute;
  right: -16px;
  top: 0;
  font-size: 12px;
  animation: sparkle 1s ease-out;
}

@keyframes sparkle {
  0% {
    transform: scale(0) rotate(0deg);
    opacity: 1;
  }
  100% {
    transform: scale(1.2) rotate(180deg);
    opacity: 0;
  }
}

/* Enhanced Auto-complete */
#suggestions {
  box-shadow: 0 -8px 32px rgba(0, 255, 0, 0.2) !important;
}

.suggestion-category {
  background: rgba(0, 255, 0, 0.1);
  padding: 4px 8px;
  font-size: 10px;
  font-weight: bold;
  color: var(--primary-green);
  border-bottom: 1px solid rgba(0, 255, 0, 0.2);
}

/* Demo Mode Styles */
.demo-highlight {
  background: rgba(255, 255, 0, 0.2);
  padding: 2px 4px;
  border-radius: 3px;
  animation: highlightPulse 1s infinite;
}

@keyframes highlightPulse {
  0%, 100% { background: rgba(255, 255, 0, 0.2); }
  50% { background: rgba(255, 255, 0, 0.4); }
}

/* Mobile Enhancements for Status Bar */
@media (max-width: 768px) {
  .terminal-status-bar {
    display: none; /* Hide on mobile since they use the BIOS interface */
  }
  
  .command-notification {
    top: 10px;
    right: 10px;
    left: 10px;
    max-width: none;
    text-align: center;
  }
}

/* Theme-specific enhancements */
[data-theme="matrix"] .status-item {
  color: #00ff41;
}

[data-theme="hacker"] .status-item {
  color: #ff0040;
}

[data-theme="light"] .status-item {
  color: #2c3e50;
}

/* Interactive Elements */
.clickable-hint {
  cursor: pointer;
  transition: all 0.2s ease;
}

.clickable-hint:hover {
  background: rgba(0, 255, 0, 0.1);
  transform: translateY(-1px);
}

/* Progress Animations */
@keyframes progressFill {
  from { width: 0%; }
  to { width: var(--progress-width); }
}

/* Context-aware suggestions */
.suggestion-item.recommended {
  background: rgba(255, 215, 0, 0.1) !important;
  border-left: 3px solid #FFD700;
}

.suggestion-item.new-user {
  background: rgba(0, 255, 255, 0.1) !important;
  border-left: 3px solid #00ffff;
}

/* Enhanced Terminal Header for Status */
.terminal-header-enhanced {
  position: relative;
}

.terminal-progress-indicator {
  position: absolute;
  bottom: -1px;
  left: 0;
  height: 2px;
  background: var(--primary-green);
  transition: width 0.5s ease;
}

/* Smooth transitions for all dynamic content */
.fade-in {
  animation: fadeIn 0.5s ease;
}

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

/* Terminal Footer */
.terminal-footer {
  border-top: 1px solid var(--color-border);
}

/* Links and Shortcuts */
.terminal-link,
.terminal-shortcut {
  color: var(--color-primary);
}

/* Copy Badge */
.copy-badge {
  background: var(--color-primary);
}

/* Section Titles */
.section-title {
  color: var(--color-primary);
}

/* Keyboard Input */
kbd {
  color: var(--color-primary);
}

/* Blockquotes */
blockquote {
  border-left: 2px solid var(--color-primary);
}

/* Cards */
.card {
  border: 1px solid var(--color-primary);
}

/* Badges */
.badge {
  border: 1px solid var(--color-primary);
}
