Blurred Text Hover Effect using HTML, CSS with free source code and GitHub link

Blurred Text Hover Effect using HTML, CSS with free source code by codingayush

Social Links

HTML
<!DOCTYPE html>
<html lang="en">

<head>
    <title>Focus Blurred Text On Hover</title>
    <!--Google Font-->
    <link href="https://fonts.googleapis.com/css2?family=Rubik:wght@700&display=swap" rel="stylesheet">
    <!--Stylesheet-->
    <link rel="stylesheet" href="style.css">
</head>

<body>
    <h1>@coding.ayush</h1>
</body>

</html>
CSS
*,
*:before,
*:after{
    padding: 0;
    margin: 0;
    box-sizing: border-box;
}
body{
    height: 100%;
    background: url("background.jpg") center center fixed;
    background-size: cover;
}
h1{
    position: absolute;
    transform: translate(-50%,-50%);
    left: 50%;
    top: 50%;
    font-family: "Rubik",sans-serif;
    color: #ffffff;
    font-size: 80px;
    letter-spacing: 20px;
    cursor: pointer;
    filter: blur(5px);
    transition: 0.3s all;
}
h1:hover{
    filter: blur(0);
}

Post a Comment

Previous Post Next Post