Thermochromic Ink Card
A matte black surface like a temperature-sensitive mug that appears completely blank at rest. Hover warms the area beneath the cursor, revealing hidden colors and text that fade back to black on cooling. A vigorous click heats the entire card, making all content blaze into visibility for a brief moment before cooling.
by FreeCsStyles Dev's
Embed this component
Paste this snippet into any site — the design renders in a sandboxed iframe served from /embed/thermochromic-ink-card.
<iframe src="/embed/thermochromic-ink-card" sandbox="allow-scripts" loading="lazy" title="Thermochromic Ink Card" style="border:0;width:100%;height:480px;overflow:hidden"></iframe>Implementation code
Copy the HTML and CSS for Thermochromic Ink Card, or grab a framework-specific implementation. The HTML and CSS variants are self-contained; framework variants assume that framework's project setup.
HTML
<div class="thermochromic-card">
<div class="thermo-heatspot"></div>
<div class="thermo-content">
<div class="thermo-pattern">
<div class="thermo-ring"></div>
<div class="thermo-ring" style="width: 45%; height: 45%;"></div>
<div class="thermo-ring" style="width: 30%; height: 30%;"></div>
<p class="thermo-temp">?</p>
</div>
<p class="thermo-hidden-text">THE TRUTH IS IN THE HEAT</p>
<div class="thermo-footer">
<div><div class="t-title">Thermal Trace</div><div class="t-sub">Dr. Hestia</div></div>
<div class="t-status">○ COLD</div>
</div>
</div>
</div>CSS
.thermochromic-card { position: relative; width: 220px; min-height: 300px; border-radius: 16px; overflow: hidden; background: linear-gradient(160deg, #0a0a0a, #050505); border: 1.5px solid rgba(255,255,255,0.03); box-shadow: 0 10px 30px rgba(0,0,0,0.3); cursor: pointer; transition: border-color 0.5s ease; }
.thermochromic-card:hover { box-shadow: 0 0 25px rgba(255,150,50,0.04), 0 15px 40px rgba(0,0,0,0.4); border-color: rgba(255,150,50,0.06); }
.thermo-heatspot { position: absolute; inset: 0; pointer-events: none; z-index: 2; opacity: 0; transition: opacity 0.5s ease; background: radial-gradient(circle at 50% 50%, rgba(255,200,100,0.08), rgba(255,100,30,0.04), transparent 30%); }
.thermochromic-card:hover .thermo-heatspot { opacity: 1; }
.thermo-content { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.thermo-pattern { position: relative; width: 80%; height: 45%; display: flex; align-items: center; justify-content: center; margin-bottom: 8px; opacity: 0; transition: opacity 0.5s ease; }
.thermochromic-card:hover .thermo-pattern { opacity: 1; }
.thermo-ring { position: absolute; width: 60%; height: 60%; border-radius: 50%; border: 1px solid rgba(255,150,50,0.08); }
.thermo-temp { font-size: 10px; font-weight: 700; color: rgba(255,200,100,0.4); }
.thermo-hidden-text { position: absolute; font-size: 7px; font-weight: 700; letter-spacing: 2px; color: rgba(255,200,100,0.3); top: 50%; left: 50%; transform: translate(-50%, -50%); width: 80%; text-align: center; opacity: 0; transition: opacity 0.8s ease 0.2s; }
.thermochromic-card:hover .thermo-hidden-text { opacity: 1; }
.thermo-footer { position: absolute; inset-x: 0; bottom: 0; z-index: 10; padding: 20px; background: linear-gradient(0deg, rgba(0,0,0,0.7), transparent); }
.t-title { font-size: 14px; font-weight: 700; color: rgba(255,255,255,0.5); transition: color 0.5s ease; }
.thermochromic-card:hover .t-title { color: rgba(255,255,255,0.9); }
.t-sub { font-size: 9px; color: rgba(255,255,255,0.1); transition: color 0.5s ease; }
.thermochromic-card:hover .t-sub { color: rgba(255,255,255,0.3); }
.t-status { padding: 2px 8px; border-radius: 2px; font-size: 7px; font-weight: 700; letter-spacing: 0.1em; background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.05); color: rgba(255,255,255,0.15); }
.thermochromic-card:hover .t-status { background: rgba(255,150,50,0.08); border-color: rgba(255,150,50,0.12); color: rgba(255,200,100,0.6); }Tailwind CSS
<div class="group relative w-[220px] min-h-[300px] rounded-2xl overflow-hidden border border-white/5 shadow-lg group-hover:shadow-[0_0_25px_rgba(255,150,50,0.04),0_15px_40px_rgba(0,0,0,0.4)] group-hover:border-orange-400/10 bg-gradient-to-b from-[#0a0a0a] to-[#050505] cursor-pointer">
<div class="absolute inset-0 z-[2] pointer-events-none opacity-0 group-hover:opacity-100 transition-opacity duration-500 bg-gradient-radial from-amber-200/10 via-orange-400/5 to-transparent"></div>
<div class="absolute left-[10%] right-[10%] top-[16%] h-[38%] rounded-xl border border-orange-400/5 flex items-center justify-center opacity-0 group-hover:opacity-100 transition-opacity duration-500">
<div class="absolute w-[60%] h-[60%] rounded-full border border-orange-400/10"></div>
<div class="absolute w-[45%] h-[45%] rounded-full border border-orange-400/8"></div>
<div class="absolute w-[30%] h-[30%] rounded-full border border-orange-400/6"></div>
<p class="text-[10px] font-bold text-amber-200/40">?</p>
</div>
<div class="absolute inset-x-0 bottom-0 z-10 p-5 bg-gradient-to-t from-black/70 to-transparent">
<div class="flex items-center justify-between"><div><p class="text-sm font-bold text-white/50 group-hover:text-white/90 transition-colors duration-500">Thermal Trace</p><p class="text-[9px] text-white/10 group-hover:text-white/30 transition-colors duration-500">Dr. Hestia</p></div><div class="px-2 py-0.5 rounded-sm text-[7px] font-bold tracking-widest bg-white/5 border border-white/10 text-white/20 group-hover:bg-orange-400/10 group-hover:border-orange-400/20 group-hover:text-amber-200/60 transition-all duration-500">○ COLD</div></div>
</div>
</div>React
import React, { useState, useRef, useCallback } from 'react';
import { motion, useMotionValue, useSpring } from 'framer-motion';
export function ThermochromicInkCard({ experiment = 'Thermal Trace', width = 220 }) {
const ref = useRef(null);
const [isHovered, setIsHovered] = useState(false);
const [isHeated, setIsHeated] = useState(false);
const [cursorPos, setCursorPos] = useState({ x: 50, y: 50 });
const [clickCount, setClickCount] = useState(0);
const x = useMotionValue(0);
const y = useMotionValue(0);
const rotateX = useSpring(y, { damping: 25, stiffness: 200 });
const rotateY = useSpring(x, { damping: 25, stiffness: 200 });
const handleMouseMove = (e) => {
if (!ref.current) return;
const rect = ref.current.getBoundingClientRect();
x.set(-((e.clientX - rect.left - rect.width / 2) / (rect.width / 2)) * 6);
y.set(((e.clientY - rect.top - rect.height / 2) / (rect.height / 2)) * 6);
setCursorPos({ x: ((e.clientX - rect.left) / rect.width) * 100, y: ((e.clientY - rect.top) / rect.height) * 100 });
};
const handleClick = () => { setIsHeated(true); setClickCount(c => c + 1); setTimeout(() => setIsHeated(false), 2000); };
const heatIntensity = isHeated ? 1 : isHovered ? 0.7 : 0;
return (
<div onMouseEnter={() => setIsHovered(true)} onMouseLeave={() => { setIsHovered(false); x.set(0); y.set(0); }}>
<motion.div ref={ref} onMouseMove={handleMouseMove} onClick={handleClick} style={{ rotateX, rotateY, transformStyle: 'preserve-3d' }} className="relative cursor-pointer">
<motion.div className="relative overflow-hidden rounded-2xl" style={{ width, minHeight: 300, background: 'linear-gradient(160deg, #0a0a0a, #050505)', border: '1.5px solid rgba(255,255,255,0.03)' }}
animate={{ boxShadow: isHovered ? '0 0 25px rgba(255,150,50,0.04), 0 15px 40px rgba(0,0,0,0.4)' : '0 10px 30px rgba(0,0,0,0.3)', borderColor: isHeated ? 'rgba(255,150,50,0.15)' : isHovered ? 'rgba(255,150,50,0.06)' : 'rgba(255,255,255,0.03)' }} transition={{ type: 'spring', stiffness: 260, damping: 20 }}>
<motion.div className="absolute inset-0 z-[2] pointer-events-none" animate={{
background: isHeated ? 'radial-gradient(circle at 50% 50%, rgba(255,200,100,0.12), rgba(255,100,30,0.08), transparent 70%)' : 'radial-gradient(circle at ' + cursorPos.x + '% ' + cursorPos.y + '%, rgba(255,200,100,0.1), rgba(255,100,30,0.06), transparent ' + (isHovered ? '30%' : '0%') + ')'
}} transition={{ duration: 0.5 }} />
<motion.div className="absolute z-4" style={{ left: '10%', right: '10%', top: '12%', height: '45%' }} animate={{ opacity: heatIntensity }} transition={{ duration: 0.5 }}>
<div className="w-full h-full rounded-xl overflow-hidden relative flex items-center justify-center" style={{ border: '1px solid rgba(255,150,50,' + (heatIntensity * 0.1) + ')', background: 'rgba(255,150,50,' + (heatIntensity * 0.03) + ')' }}>
{[0, 1, 2].map(i => <motion.div key={i} className="absolute rounded-full" style={{ width: 60 - i * 15 + '%', height: 60 - i * 15 + '%', border: '1px solid rgba(255,' + (150 - i * 40) + ',' + (50 - i * 20) + ',' + (heatIntensity * 0.08) + ')' }} />)}
<motion.p className="text-[10px] font-bold" style={{ color: 'rgba(255,' + Math.floor(200 - heatIntensity * 100) + ',' + Math.floor(100 - heatIntensity * 80) + ',0.8)' }}>{isHeated ? (clickCount * 4 + 36) + '°C' : isHovered ? '≈ 24°C' : '?'}</motion.p>
</div>
</motion.div>
<motion.div className="absolute z-5 pointer-events-none" style={{ left: '50%', top: '50%', transform: 'translate(-50%, -50%)', width: '80%' }} animate={{ opacity: heatIntensity * 0.8 }} transition={{ duration: 0.8, delay: 0.2 }}>
<p className="text-[7px] font-bold tracking-[2px] text-center" style={{ color: 'rgba(255,200,100,0.5)' }}>THE TRUTH IS IN THE HEAT</p>
</motion.div>
<div className="absolute inset-x-0 bottom-0 z-10 p-5 bg-gradient-to-t from-black/70 to-transparent">
<div className="flex items-center justify-between mb-2">
<div><p className="text-sm font-bold" style={{ color: isHeated ? 'rgba(255,200,100,0.9)' : isHovered ? 'rgba(255,255,255,0.9)' : 'rgba(255,255,255,0.5)' }}>{experiment}</p><p className="text-[9px]" style={{ color: isHeated ? 'rgba(255,150,50,0.6)' : isHovered ? 'rgba(255,255,255,0.3)' : 'rgba(255,255,255,0.1)' }}>Dr. Hestia</p></div>
<motion.div className="px-2 py-0.5 rounded-sm text-[7px] font-bold tracking-widest" style={{ background: isHeated ? 'rgba(255,150,50,0.12)' : 'rgba(255,255,255,0.03)', border: '1px solid ' + (isHeated ? 'rgba(255,150,50,0.2)' : 'rgba(255,255,255,0.05)'), color: isHeated ? 'rgba(255,200,100,0.6)' : 'rgba(255,255,255,0.15)' }}>{isHeated ? '🔥 HOT' : isHovered ? '⟡ WARM' : '○ COLD'}</motion.div>
</div>
<div className="text-center"><span className="text-[7px] font-mono" style={{ color: isHeated ? 'rgba(255,150,50,0.3)' : 'rgba(255,255,255,0.12)' }}>{isHeated ? '[▼ cooling...]' : '[▼ click to heat]'}</span></div>
</div>
</motion.div>
</motion.div>
</div>
);
}Where Thermochromic Ink Card fits
- Reveal mechanics
- Progressive discovery
- Secret content display
- Interactive puzzles
- Temperature-themed UIs
Interaction states & animations
- Heat reveal
- Temperature gradient
- Thermal pulse
- Cool-down fade
Topics
- #thermochromic
- #heat
- #temperature
- #reveal
- #hidden
- #matte
- #black
- #warm
- #thermal
- #claymorphism
Accessibility notes
Content hidden until hover or click is not accessible to keyboard-only or screen reader users. Ensure hidden content is available via alternative methods. The heating effect may be distracting. Consider prefers-reduced-motion to keep content permanently visible with lower opacity.
Browser support
- Chrome 90+
- Firefox 105+
- Safari 15+
- Edge 90+