Sure, here's an example of a simple text-based game about time travel implemented as a single HTML file:
Please note that this implementation assumes a Node.js environment for running the game logic. It uses the readline module for handling user input. To run this code in a browser environment (without Node.js), you would need to modify the input/output handling logic.