Build a System Font Pairing Explorer With Real Layouts in One HTML File
A single offline HTML page that compares seven heading and body font pairings built from system font stacks, previewed in article, card and button layouts with a rationale for each.
You getone complete HTML file in a single code block, then 3 short ideas to extend it.
The prompt
Act as a senior product designer and front-end developer. Build "Pairbook", a font pairing explorer that compares seven heading and body pairings made only from offline system font stacks, with no web fonts. Each pairing has a name, a category label (for example Transitional serif / Neo-grotesque sans), a full CSS font stack for heading and body, and a two-sentence rationale. Show the selected pair in three realistic layouts with real copy: a magazine article about a neighborhood bakery with kicker, headline, deck, byline, subhead and pull quote; an event card with tag, title, details, price and button; and a button row with primary, secondary and ghost buttons plus a status message.
Rules:
1. A left sidebar lists the pairings, each name drawn in its own heading stack. Click, tap, Arrow Up/Down or J/K switches pairs. Under 860px the sidebar becomes a horizontal scroller.
2. Show both stacks as CSS custom properties next to large Aa specimens. Use canvas text measurement to detect which font in each stack actually renders on this device.
3. Include a light/dark preview toggle and a base-size slider from 14 to 20px.
4. Palette: warm paper, near-black ink and one terracotta accent. Use a clear type scale, generous spacing and AA contrast.
5. Use only a short fade on switch, disabled under prefers-reduced-motion. No external resources, storage or alerts.
Output format: one complete HTML file in a single code block, then 3 short ideas to extend it.Example output
Tips and common edits
Why this works
- Pairings use only system font stacks with several fallbacks, so every pair renders offline on Mac, Windows and Linux.
- Real article, card and button copy shows how a pair behaves at headline, body and UI sizes, not only as specimens.
- Canvas measurement reports which font in each stack renders, which turns a guess into a fact on each device.
Paste into ChatGPT, Claude or Gemini. Save the returned code as pairbook.html and open it in any browser, or run it in the chat's preview or canvas. Detected fonts vary by operating system, which is the point.
Common edits
- Swap the bakery copy for your own brand's headlines and product names so the preview matches your real content.
- Add or remove entries in the pairs list, or change the terracotta accent to your brand color in the CSS variables.
Prompt details
- By
- Prompts-GPT editors
- Published
Did this prompt work?
Keep exploring
More like this
Build a Modular Type Scale Specimen with Adjustable Ratio and Base Size
A single HTML file that turns a ratio and base size into a live editorial type specimen, a scale ladder with px and rem values, and copy-ready CSS custom properties.
Build a Typographic Hierarchy Playground Comparing Weight, Size, Spacing and Color
A single HTML file that shows the same text block twice, flat and styled, letting students switch on weight, size, spacing or color one at a time and see each change annotated.
Build an Interactive Brand Style Board With Logo, Colors, Type and Voice
A prompt that makes the AI build a one-page brand board for a fictional tea company, with click-to-copy colors, a type tester, do/don't logo tiles and tone-of-voice samples.
Build a Button and Form Field States Reference Sheet in a Single HTML File
Get a polished, single-file reference sheet that shows button and text field states side by side, with a live playground and contrast ratios computed from design tokens.
Build a Color Blindness Simulator That Previews a Palette on a Dashboard Card
A single HTML file that redraws a realistic dashboard card under protanopia, deuteranopia, tritanopia and grayscale and flags color pairs that become hard to tell apart.
Build a Drag-to-Arrange Brand Mood Board with Color, Texture and Type Tiles
A prompt that produces a single HTML mood board of color, texture and type tiles built from CSS and SVG, rearrangeable by mouse, touch and keyboard.
- Build a Draggable Color Harmony Wheel With Live UI Preview in One HTML File
- Build a Light/Dark Mode Toggle Demo Page with Smooth Theme Switching
- Build a Live Accessible Color Palette Builder with a WCAG Contrast Matrix
- Build a Logo Lockup and Clear-Space Guideline Sheet with an Original SVG Mark
- Build a Multi-Step Onboarding Wizard with Stepper and Inline Validation
- Build a Playful Animated 404 Error Page with SVG Art and Site Search