10% off on all-access. Use code SUPER10.
    d :
    h :
    m :
    Logo

    Background Overlay Card

    Background Overlays

    This card is for some special elements, like displaying background gifs on hover only.

    The card displays a static background image by default. On hover, the background-image property transitions to an animated GIF. A pseudo-element preloads the GIF using a before rule positioned off-screen, preventing the flash that would otherwise occur on first hover.

    An after pseudo-element creates a semi-transparent black overlay on hover, fading in at 50% opacity. This improves text readability against the animated background. The transition duration is set to 500ms for smooth state changes.

    Text content sits above both the background and overlay using relative positioning and z-index. The card has a fixed height with content aligned to the bottom using flexbox.

    Good for creative portfolios, entertainment sites, gaming landing pages, and any design where you want surprise and delight on hover.

    Part of Cards ยท All blocks

    Build websites faster and 10x better than your competitors with

    Aceternity UI Pro

    Next.js 15, Tailwind CSS v4 and Motion for react powered templates

    100+ templates and blocks combined

    Ready to copy paste component blocks, save days of development time

    Aceternity UI Pro Demo - Light Mode
    Logo
    Aceternity UI

    Access an ever-growing collection of premium, meticulously crafted templates and Component Blocks.

    A product by Aceternity
    Building in public at @mannupaaji

    ยฉ 2026 Aceternity Labs LLC. All Rights Reserved.