/* Terminal Container and UI Styles */
.wasm-terminal-container {
  display: flex;
  flex-direction: column;
  position: relative;
  background-color: #1e1e1e;
  color: #d4d4d4;
  font-family: 'Consolas', 'Menlo', 'Monaco', 'Courier New', monospace;
  border: 1px solid #333;
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
  width: 100%;
  min-height: 480px;
  box-sizing: border-box;
}

/* Maximize inside viewport */
.wasm-terminal-container.viewport-maximized {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  width: 100vw !important;
  height: 100vh !important;
  max-width: 100vw !important;
  max-height: 100vh !important;
  z-index: 999999 !important;
  border-radius: 0 !important;
}

/* Toolbar */
.wasm-terminal-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: #252526;
  padding: 6px 12px;
  border-bottom: 1px solid #333;
  user-select: none;
}

.wasm-terminal-title {
  font-size: 13px;
  font-weight: bold;
  color: #cccccc;
  display: flex;
  align-items: center;
  gap: 8px;
}

.wasm-terminal-status-indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: #4caf50;
  display: inline-block;
}

.wasm-terminal-controls {
  display: flex;
  gap: 8px;
}

.wasm-terminal-btn {
  background: #333333;
  color: #ffffff;
  border: 1px solid #444444;
  border-radius: 4px;
  padding: 3px 8px;
  font-size: 12px;
  cursor: pointer;
  transition: background 0.15s ease;
}

.wasm-terminal-btn:hover {
  background: #444444;
}

/* Loading & Bootstrapping Overlay */
.wasm-terminal-loading-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #1e1e1e;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 24px;
  z-index: 100;
}

.wasm-terminal-loading-title {
  font-size: 18px;
  font-weight: bold;
  color: #61afef;
  margin-bottom: 12px;
}

.wasm-terminal-progress-container {
  width: 80%;
  max-width: 450px;
  background-color: #2d3139;
  border-radius: 6px;
  overflow: hidden;
  height: 16px;
  margin-bottom: 12px;
  border: 1px solid #3e4451;
}

.wasm-terminal-progress-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #61afef, #98c379);
  transition: width 0.2s ease;
}

.wasm-terminal-progress-text {
  font-size: 12px;
  color: #abb2bf;
  margin-bottom: 6px;
}

.wasm-terminal-speed-text {
  font-size: 11px;
  color: #5c6370;
}

/* Splash Banner */
.wasm-terminal-splash-banner {
  background-color: #2c313a;
  border-left: 4px solid #e5c07b;
  padding: 10px 14px;
  margin: 8px 12px;
  border-radius: 3px;
  font-size: 12px;
  line-height: 1.5;
  color: #abb2bf;
}

.wasm-terminal-splash-banner strong {
  color: #e5c07b;
}

/* Terminal Screen */
.wasm-terminal-screen {
  flex: 1;
  padding: 4px 8px;
  overflow: hidden;
  position: relative;
  min-height: 350px;
}

/* Drag-and-drop Highlight */
.wasm-terminal-container.drag-active {
  border: 2px dashed #61afef;
  background-color: rgba(97, 175, 239, 0.05);
}
