Back to Components

Elastic Menu

A hamburger menu icon with elastic, bouncy animations. Lines stretch and snap back with a playful spring effect.

Morphing Menu Interactive

Live Preview

HTML

<div class="elastic-menu"><span></span><span></span><span></span></div>

CSS

.elastic-menu {
    width: 40px;
    height: 30px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    cursor: pointer;
}

.elastic-menu span {
    width: 100%;
    height: 4px;
    background: #667eea;
    border-radius: 2px;
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.elastic-menu:hover span:nth-child(1) {
    transform: translateY(-3px);
}

.elastic-menu:hover span:nth-child(3) {
    transform: translateY(3px);
}

.elastic-menu:hover span:nth-child(2) {
    transform: scaleX(0.8);
}