Foil Stamp Shimmer
Gold, silver, rose and holographic foil lettering whose shine slides with the pointer or a tilt slider.
AI prompt
Luxury stationery photograph of a matte black card with the word MERIDIAN hot-foil stamped in champagne gold, the foil catching a bright narrow band of light across the middle letters while the ends fall into warm dark bronze, crisp pressed edges with tiny shadows, a hint of paper tooth visible around the letters, soft top light, macro lens, shallow depth of field. Variants: silver foil, rose gold, holographic foil. Negative: flat yellow fill, glitter, blurry edges, text errors, extra objects. Reduced motion: still image with the highlight in the middle.About this pattern
Definition
Hot foil stamping presses a thin metal film onto paper. Its look comes from a sharp, bright band that travels across the letters as the card is tilted. A wide gradient clipped to the text, with its position tied to tilt, reproduces that shine.
When to use it
- Use a gradient that is three to four times wider than the text with one narrow bright band and darker tones either side.
- Add a faint dark edge so the foil separates from the card.
- Name the foil and where it sits in prompts: "gold foil lettering on matte black card".
What the controls do
- Four foils, a Tilt slider and pointer movement over the card. The shine also drifts on its own until you interact.
Motion & timing
- A slow idle sweep (5s) draws attention to the foil; it stops as soon as you move the pointer or slider.
- Reduced motion: no idle sweep; the shine moves only when you move it.
Tips & variations
- Keep a plain solid colour fallback for printing and for forced-colours modes.
- Provide the Tilt slider because touch devices have no hover.
Code of this live preview
<div class="bx"><div class="cd" id="cd" tabindex="0" aria-label="Foil card"><span id="ft">MERIDIAN</span></div><div class="pre" id="pre" role="group" aria-label="Foil"><button data-p="0" aria-pressed="true">Gold</button><button data-p="1" aria-pressed="false">Silver</button><button data-p="2" aria-pressed="false">Rose</button><button data-p="3" aria-pressed="false">Holo</button></div><label class="rw">Tilt <b id="tv">50%</b><input id="tl" type="range" min="0" max="100" value="50"></label></div>:root{--bg:#F1F1EF;--surface:#fff;--surface-2:#F7F7F5;--line:#E0E0DC;--text:#171717;--muted:#6f6f6f;--accent:#171717;--accent-ink:#fff;--danger:#d92d20}
*{box-sizing:border-box;margin:0}
.pre{display:flex;gap:5px;flex-wrap:wrap}.pre button{height:28px;padding:0 11px;border-radius:99px;border:1px solid var(--line);background:var(--surface);font-size:11px;cursor:pointer}
.pre button[aria-pressed=true]{background:var(--accent);color:var(--accent-ink);border-color:var(--accent)}
.bx{width:min(330px,100%);display:grid;gap:9px}.rw{display:grid;gap:3px;font-size:11.5px;color:var(--muted)}.rw b{color:var(--text);font-weight:600}input[type=range]{width:100%;accent-color:#171717}
.out{font-size:12px;color:var(--muted);line-height:1.4}.out b{color:var(--text)}
button:focus-visible,input:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
.cd{height:132px;border-radius:10px;display:grid;place-items:center;background:#16161a;box-shadow:0 6px 16px rgba(0,0,0,.25)}
.cd span{font-size:34px;font-weight:800;letter-spacing:.06em;color:#caa94f;background-image:var(--g);background-size:300% 100%;background-position:var(--p,50%) 0;-webkit-background-clip:text;background-clip:text;-webkit-text-fill-color:transparent;filter:drop-shadow(0 1px 0 rgba(0,0,0,.6))}
.cd.idle span{animation:sweep 5s ease-in-out infinite alternate}
@keyframes sweep{from{background-position:20% 0}to{background-position:80% 0}}
@media (prefers-reduced-motion:reduce){*{transition:none!important;animation:none!important}}const G=['linear-gradient(100deg,#7a5a1c 0%,#c99a3a 28%,#fff1b3 45%,#c99a3a 60%,#6e4f16 100%)','linear-gradient(100deg,#6b7078 0%,#b9bec6 28%,#ffffff 45%,#b9bec6 60%,#5d626a 100%)','linear-gradient(100deg,#8a4f45 0%,#d99a8a 28%,#ffe3d9 45%,#d99a8a 60%,#7a4238 100%)','linear-gradient(100deg,#6a8cff 0%,#f08cd0 25%,#ffe58c 45%,#7fe0c0 65%,#6a8cff 100%)'],cd=document.getElementById('cd'),tl=document.getElementById('tl'),bs=[...document.querySelectorAll('#pre button')];let p=0;
const calm=matchMedia('(prefers-reduced-motion:reduce)').matches;if(!calm)cd.classList.add('idle');
function stop(){cd.classList.remove('idle');}
function up(){cd.style.setProperty('--g',G[p]);cd.style.setProperty('--p',tl.value+'%');document.getElementById('tv').textContent=tl.value+'%';bs.forEach(b=>b.setAttribute('aria-pressed',String(+b.dataset.p===p)));}
bs.forEach(b=>b.addEventListener('click',()=>{p=+b.dataset.p;up();}));tl.addEventListener('input',()=>{stop();up();});
cd.addEventListener('pointermove',e=>{stop();const r=cd.getBoundingClientRect();tl.value=Math.round((e.clientX-r.left)/r.width*100);up();});up();One complete HTML file. Save it and open it in a browser.
<!doctype html>
<html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width,initial-scale=1"><title>Foil Stamp Shimmer — demo</title>
<style>
:root{--bg:#F1F1EF;--surface:#fff;--surface-2:#F7F7F5;--line:#E0E0DC;--text:#171717;--muted:#6f6f6f;--accent:#171717;--accent-ink:#fff;--danger:#d92d20}
*{box-sizing:border-box;margin:0}
html,body{height:100%}body{background:var(--bg);color:var(--text);font:15px/1.5 -apple-system,BlinkMacSystemFont,'Segoe UI',Inter,Roboto,sans-serif;-webkit-font-smoothing:antialiased}.stage{min-height:100%;display:grid;place-items:center;padding:24px}button,input,select,textarea{font-family:inherit}@media (prefers-reduced-motion:reduce){html{scroll-behavior:auto}}
.pre{display:flex;gap:5px;flex-wrap:wrap}.pre button{height:28px;padding:0 11px;border-radius:99px;border:1px solid var(--line);background:var(--surface);font-size:11px;cursor:pointer}
.pre button[aria-pressed=true]{background:var(--accent);color:var(--accent-ink);border-color:var(--accent)}
.bx{width:min(330px,100%);display:grid;gap:9px}.rw{display:grid;gap:3px;font-size:11.5px;color:var(--muted)}.rw b{color:var(--text);font-weight:600}input[type=range]{width:100%;accent-color:#171717}
.out{font-size:12px;color:var(--muted);line-height:1.4}.out b{color:var(--text)}
button:focus-visible,input:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
.cd{height:132px;border-radius:10px;display:grid;place-items:center;background:#16161a;box-shadow:0 6px 16px rgba(0,0,0,.25)}
.cd span{font-size:34px;font-weight:800;letter-spacing:.06em;color:#caa94f;background-image:var(--g);background-size:300% 100%;background-position:var(--p,50%) 0;-webkit-background-clip:text;background-clip:text;-webkit-text-fill-color:transparent;filter:drop-shadow(0 1px 0 rgba(0,0,0,.6))}
.cd.idle span{animation:sweep 5s ease-in-out infinite alternate}
@keyframes sweep{from{background-position:20% 0}to{background-position:80% 0}}
@media (prefers-reduced-motion:reduce){*{transition:none!important;animation:none!important}}
</style></head>
<body><div class="stage">
<div class="bx"><div class="cd" id="cd" tabindex="0" aria-label="Foil card"><span id="ft">MERIDIAN</span></div><div class="pre" id="pre" role="group" aria-label="Foil"><button data-p="0" aria-pressed="true">Gold</button><button data-p="1" aria-pressed="false">Silver</button><button data-p="2" aria-pressed="false">Rose</button><button data-p="3" aria-pressed="false">Holo</button></div><label class="rw">Tilt <b id="tv">50%</b><input id="tl" type="range" min="0" max="100" value="50"></label></div>
</div>
<script>
const G=['linear-gradient(100deg,#7a5a1c 0%,#c99a3a 28%,#fff1b3 45%,#c99a3a 60%,#6e4f16 100%)','linear-gradient(100deg,#6b7078 0%,#b9bec6 28%,#ffffff 45%,#b9bec6 60%,#5d626a 100%)','linear-gradient(100deg,#8a4f45 0%,#d99a8a 28%,#ffe3d9 45%,#d99a8a 60%,#7a4238 100%)','linear-gradient(100deg,#6a8cff 0%,#f08cd0 25%,#ffe58c 45%,#7fe0c0 65%,#6a8cff 100%)'],cd=document.getElementById('cd'),tl=document.getElementById('tl'),bs=[...document.querySelectorAll('#pre button')];let p=0;
const calm=matchMedia('(prefers-reduced-motion:reduce)').matches;if(!calm)cd.classList.add('idle');
function stop(){cd.classList.remove('idle');}
function up(){cd.style.setProperty('--g',G[p]);cd.style.setProperty('--p',tl.value+'%');document.getElementById('tv').textContent=tl.value+'%';bs.forEach(b=>b.setAttribute('aria-pressed',String(+b.dataset.p===p)));}
bs.forEach(b=>b.addEventListener('click',()=>{p=+b.dataset.p;up();}));tl.addEventListener('input',()=>{stop();up();});
cd.addEventListener('pointermove',e=>{stop();const r=cd.getBoundingClientRect();tl.value=Math.round((e.clientX-r.left)/r.width*100);up();});up();
</script>
</body></html>