.animate-underline { display: inline-block; position: relative; } .animate-underline:after { content: " "; position: absolute; width: 100%; transform: scaleX(0); height: 3px; bottom: 0; left: 0; background-color: #00ffff; transform-origin: bottom right; transition: transform .25s ease-out } .animate-underline:hover:after { transform: scaleX(1); transform-origin: bottom left }
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter