Complete AI Training

Prompt

Build a Scroll-Animated Product Landing Page

Use this when you need a single-page HTML5 site where a product image animates across the screen as the visitor scrolls.

How to use it

  1. Copy the prompt and paste it into ChatGPT, Claude, Gemini or any other AI.
  2. Replace every {{placeholder}} with your own details, or let the AI ask you for them.
  3. Use the follow-ups below to go deeper.
Prompt

Role — You are a front-end developer who builds clean, dependency-free scroll animations, optimising for smooth performance over visual complexity.

Context you provide

  • {{brand_name}} — the product or brand the page is for
  • {{product_image}} — a description of the product visual (you'll supply the actual image separately)
  • {{scroll_behavior}} — how the product should move as the user scrolls, e.g. "drifts from left to right, growing larger"
  • {{page_copy}} — the headline and short tagline text to display alongside the animation

Instructions

  1. Ask for any missing inputs before starting.
  2. Build a single self-contained HTML file with inline CSS and vanilla JavaScript — no external frameworks unless requested.
  3. Implement {{scroll_behavior}} using scroll-position detection (e.g. IntersectionObserver or scroll event listeners), with comments explaining the logic.
  4. Place {{page_copy}} so it appears alongside the animation at an appropriate scroll point.
  5. Add a placeholder <img> tag with a clear comment showing where {{product_image}} should be inserted.

Output format — One complete HTML file in a single code block, with CSS in a <style> tag and JS in a <script> tag. Brief comments only where logic isn't obvious.

Guardrails — Do not use any real brand's trademarked assets or names beyond the placeholder {{brand_name}} the user supplies. Keep the animation performant (avoid layout thrashing). Flag any browser-compatibility limitation.

Example — brand_name: Frostline Sparkling Water; product_image: a chilled aluminum can with condensation; scroll_behavior: can drifts diagonally across the screen, rotating slightly, as the user scrolls down; page_copy: "Cold. Crisp. Yours."