The iconic Linear/Vercel bento feature grid where a crisp 1px radial border and subtle surface glow follow your cursor across adjacent cards with zero canvas overhead.
Linear VibeBento GridPure CSS2.8 KB
'use client'
import { useRef } from 'react'
const FEATURES = [
{ tag: 'EDGE RUNTIME', title: 'Sub-30ms Global Dispatch', desc: 'Cursor-tracking 1px radial border spotlight with zero layout shift.', metric: '24.2 ms' },
{ tag: 'ZERO DEPS', title: '2.8 KB Drop-In', desc: 'Uses native CSS custom properties updated via a single pointermove handler.', metric: '2.8 KB' },
]
export function SpotlightBentoGrid() {
const gridRef = useRef<HTMLDivElement>(null)
const handleMove = (e: React.PointerEvent<HTMLDivElement>) => {
const cards = gridRef.current?.querySelectorAll<HTMLElement>('[data-spot-card]')
cards?.forEach((card) => {
const rect = card.getBoundingClientRect()
card.style.setProperty('--mx', `${e.clientX - rect.left}px`)
card.style.setProperty('--my', `${e.clientY - rect.top}px`)
})
}
return (
<div ref={gridRef} onPointerMove={handleMove} className="group grid gap-4 md:grid-cols-2">
{FEATURES.map((item) => (
<article
key={item.title}
data-spot-card
className="relative overflow-hidden rounded-2xl bg-white/10 p-px"
style={{
backgroundImage: `radial-gradient(320px circle at var(--mx,-400px) var(--my,-400px), #8b5cf6, #38bdf8 45%, transparent 72%)`,
}}
>
<div className="relative h-full rounded-[15px] bg-[#10131c] p-6 text-slate-100">
<span className="text-[11px] font-mono tracking-widest text-slate-400">{item.tag}</span>
<h3 className="mt-2 text-lg font-semibold">{item.title}</h3>
<p className="mt-2 text-sm text-slate-400">{item.desc}</p>
<div className="mt-6 border-t border-white/10 pt-3 font-mono text-xs" style={{ color: '#38bdf8' }}>
{item.metric}
</div>
</div>
</article>
))}
</div>
)
}Loading single-file HTML…
Create a single-file responsive SaaS Spotlight Bento Grid using pure HTML, CSS, and vanilla JS (zero dependencies) inspired by Linear and Vercel on a dark obsidian surface (#090b10). - Border Spotlight Craft: Wrap each card inside a 1px padding container whose ::before pseudo-element renders a radial-gradient(320px circle at var(--mx) var(--my), #8b5cf6, #38bdf8 45%, transparent 72%) while the inner card surface (#10131c) adds a subtle 11% radial tint. - Interaction: Attach a single passive pointermove listener to the parent grid updating --mx and --my relative to each card's getBoundingClientRect() so adjacent card edges illuminate smoothly as the cursor approaches. - Responsive & A11y: Asymmetric 12-column desktop bento collapsing cleanly to single-column mobile, respecting prefers-reduced-motion, under 3 KB.
WHY THIS WORKS IN PRODUCTION
- Zero dependencies — pure CSS radial-gradient + 10 lines of pointer JS
- Illuminates neighboring card borders seamlessly before you even hover them
- Directly pasteable React + Tailwind TSX component included
- 60fps GPU-friendly & prefers-reduced-motion safe
DROP-IN SPECS // WEB & MOBILE FIT








