Website template
The Night Line
A red sleeper train crosses a viaduct, a moonlit lake and a sleeping town, then wakes at the sea: scroll the journey, click a lit window, book a cabin.
The Night Line is a premium one-page website for sleeper trains, rail holidays, tour operators, ferries and any business that sells a journey. The hero is a cinematic night scene drawn in code: a red train with warm lit windows crossing a stone viaduct under a full moon, with six layers of mountains, ridges and forest moving at different speeds for deep parallax.
Scroll, and the journey moves sideways through six scenes: the viaduct, Vale Pass station in the snow, a lake causeway with the moon's path and the train's reflection, a sleeping town with a blinking level crossing, a cutaway tunnel with passing lamps, and sunrise at the sea, where the train turns from night colours to dawn colours. A live bar shows the train time, the kilometre and the next stop. It is alive when nobody touches it: the land drifts, stars twinkle, the engine breathes smoke and the wheels turn.
A row of stops lights up as the train arrives, and each one can be clicked to travel there. Click a lit window to look inside a cabin (Classic, Deluxe or Suite), drawn in SVG, with the night going by the window and its price. After the journey: three cabins, a route and date picker with a ticket that adds itself up (distance, weekend night, second traveller, dinner), a dining car menu with the night hour by hour, questions and a footer. The reservation form is a Netlify form.
Proven with Claude. Also works with ChatGPT and Gemini.
Features
- One cinematic scene drawn in code: a five-car red train (locomotive, Suite, Deluxe, Classic and dining car) with lit windows, in a night and a dawn version
- Six cached parallax layers and six scenes: viaduct, snowy pass station, lake causeway with moon path and reflection, sleeping town, cutaway tunnel, sunrise at the sea
- Alive from the first second: the land drifts, stars twinkle, smoke rises, wheels turn, lamps blink, water ripples
- A live readout of train time, kilometre and next stop
- A row of stops that lights up and jumps the train there when clicked
- Click a lit window (or press Enter on a carriage) to look inside a Classic, Deluxe or Suite cabin, with its price and what it includes
- Route and date picker with a ticket that adds itself up and a Netlify Forms reservation form
- A dining car menu, a night timetable, questions and a footer
- Prices in euros, easy to change in one settings block
- Designed phone layout; text always readable on the night; nothing goes under the menu
- Fonts stored in the kit: nothing loads from other servers
- Complete still version for reduced motion; pauses off screen and when the tab is hidden
The prompt
You are building a premium one-page website template called "The Night Line" for a fictional sleeper train (The Night Line Railway Co., one train a night at 21:40 from Porto Lume to Sainte-Mer, 612 kilometres, all place names made up). It is cinematic and hushed: lamp light and a red train on a deep night, then dawn paper for the lower sections.
Full prompt, 14 steps, opens after you buy or claim Locked
How to use
- Open the prompt, or download the source code, from My library.
- Paste the prompt into your AI assistant, or upload the files to your web host.
- Change the settings block: your name, colours, texts and pictures.
- Preview it in your browser and check it on your phone.
- Publish it on your own domain.
What is inside
- Source files: index.html, assets/css/style.css, assets/js/world.js, assets/js/track.js, assets/js/train.js, assets/js/cabins.js, assets/js/main.js, assets/fonts/
- Prompt pack (Markdown and PDF): rebuild or adapt the design with your AI assistant, step by step
- Set-up notes (Markdown and PDF): normal web host, Netlify, and the reservation form (Netlify Forms, Formspree, email)
- README with every setting explained
- LICENSE.txt and CREDITS.md
Files
- night-line-v1.0.0-full.zip Source code, 828 KB Scanned, clean
- night-line-v1.0.0-prompt-pack.zip Prompt, 687 KB Scanned, clean
- PROMPT-PACK.pdf Prompt, 442 KB Scanned, clean
- SETUP.pdf Set-up notes, 65 KB Scanned, clean
Technical details
- Plain HTML5, CSS and JavaScript; Canvas 2D and SVG (no library)
- Fonts: Newsreader Italic and Geologica (SIL Open Font License), included as files
- Works in current Chrome, Edge, Safari and Firefox, desktop and phone
- Tested at 1440 and 390 px wide
Licence
- You may
- Use it for your own websites and for client websites, as many as you like, and change anything
- You may not
- Resell or share the template files or the prompt pack
- Updates
- Free, they appear in My library
- Refunds
- Only if a file is faulty and we cannot fix it




