/* RESET BÁSICO */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* BODY GENERAL */
body {
  background-color: #050b18;
  color: #e6edf3;
  font-family: "Courier New", monospace;
  height: 100vh;
}

/* CONTENEDOR PRINCIPAL */
#game-container {
  display: flex;
  flex-direction: column;
  height: 100vh;
}

/* HEADER */
#game-header {
  padding: 10px 15px;
  border-bottom: 1px solid #1f2a3a;
}

#game-header h1 {
  font-size: 18px;
  color: #58a6ff;
}

#game-header p {
  font-size: 12px;
  color: #8b949e;
}

/* ESCENA */
#scene-container {
  width: 100%;
  height: 220px;
  background-color: #000;
  display: flex;
  justify-content: center;
  align-items: center;
  border-bottom: 1px solid #1f2a3a;
}

#scene-image {
  max-width: 100%;
  max-height: 100%;
  object-fit: cover;
  display: none;
}

/* TEXTO / OUTPUT */
#output-container {
  flex: 1;
  overflow-y: auto;
  padding: 15px;
}

#output p {
  margin-bottom: 10px;
  line-height: 1.4;
}

/* COMANDOS DEL JUGADOR */
.player-command {
  color: #58a6ff;
}

/* MENSAJES DEL SISTEMA */
.game-message {
  color: #e6edf3;
}

/* HUD */
#hud {
  display: flex;
  justify-content: space-between;
  padding: 10px 15px;
  border-top: 1px solid #1f2a3a;
  border-bottom: 1px solid #1f2a3a;
  background-color: #0d1117;
  font-size: 14px;
}

/* INPUT */
#input-container {
  padding: 10px;
}

#command-input {
  width: 100%;
  padding: 10px;
  background-color: #0d1117;
  border: 1px solid #30363d;
  color: #e6edf3;
  font-size: 14px;
  outline: none;
}

#command-input::placeholder {
  color: #6e7681;
}

#command-input:focus {
  border-color: #58a6ff;
}
function renderScene(scene) {
  if (!sceneImage) return;

  if (scene.image) {
    sceneImage.style.opacity = "0";

    setTimeout(() => {
      sceneImage.src = scene.image;
      sceneImage.style.display = "block";
      sceneImage.style.opacity = "1";
    }, 120);
  } else {
    sceneImage.style.opacity = "0";

    setTimeout(() => {
      sceneImage.removeAttribute("src");
      sceneImage.style.display = "none";
    }, 120);
  }
}