<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Tutorial Button Dev.to</title>
<link rel="stylesheet" href="styles.css">
</head>
<body>
<div class="button-container">
<button class="premium-btn">
<span class="border-animation"></span>
Go To Follow Me
</button>
<span class="outer-glow"></span>
</div>
</body>
</html>
/* Background setup */
body {
display: flex;
align-items: center;
justify-content: center;
min-height: 100vh;
background-color: #1b1b2f;
margin: 0;
font-family: Arial, sans-serif;
overflow: hidden;
}
/* Button container with glow effect */
.button-container {
position: relative;
display: inline-block;
}
.outer-glow {
position: absolute;
top: -25px;
left: -25px;
right: -25px;
bottom: -25px;
border-radius: 50px;
background: linear-gradient(135deg, #1de9b6, #6a00f4, #ff4081, #1de9b6);
background-size: 400% 400%;
filter: blur(50px);
opacity: 0.8;
animation: pulseGlow 6s ease-in-out infinite;
pointer-events: none;
}
/* Premium button styling */
.premium-btn {
padding: 20px 50px;
font-size: 22px;
font-weight: bold;
color: #fff;
background: linear-gradient(45deg, #00c6ff, #0072ff);
border: none;
border-radius: 50px;
position: relative;
overflow: hidden;
cursor: pointer;
transition: all 0.4s ease;
text-transform: uppercase;
letter-spacing: 2px;
box-shadow: 0px 4px 20px rgba(0, 255, 255, 0.4);
z-index: 1;
}
/* Border animation effect */
.border-animation {
position: absolute;
top: -5px;
left: -5px;
right: -5px;
bottom: -5px;
border-radius: 50px;
background: linear-gradient(90deg, #1de9b6, #6a00f4, #ff4081, #1de9b6);
background-size: 300%;
z-index: -1;
animation: rotateBorder 4s ease-in-out infinite;
filter: blur(8px);
}
/* Premium button hover effects */
.premium-btn:hover {
background: linear-gradient(45deg, #ff4081, #1de9b6);
color: #ffffff;
box-shadow: 0px 6px 30px rgba(0, 255, 255, 0.6),
0px 6px 30px rgba(255, 64, 129, 0.6);
transform: scale(1.05);
}
/* Glow effect */
.premium-btn::before {
content: "";
position: absolute;
top: -50%;
left: -50%;
width: 200%;
height: 200%;
background: radial-gradient(
circle,
rgba(255, 255, 255, 0.2),
transparent 70%
);
transition: all 0.5s ease;
transform: rotate(0deg);
border-radius: 50%;
filter: blur(50px);
opacity: 0.9;
}
.premium-btn:hover::before {
transform: rotate(45deg);
}
/* Ripple effect */
.premium-btn::after {
content: "";
position: absolute;
top: 50%;
left: 50%;
width: 0;
height: 0;
background: rgba(255, 255, 255, 0.5);
border-radius: 50%;
transform: translate(-50%, -50%);
opacity: 0;
transition: width 0.4s ease, height 0.4s ease, opacity 0.5s ease;
}
.premium-btn:hover::after {
width: 350%;
height: 350%;
opacity: 0;
}
/* Border animation keyframes */
@keyframes rotateBorder {
0% {
background-position: 0% 50%;
}
50% {
background-position: 100% 50%;
}
100% {
background-position: 0% 50%;
}
}
/* Outer glow animation keyframes */
@keyframes pulseGlow {
0% {
background-position: 0% 0%;
}
50% {
background-position: 100% 100%;
opacity: 1;
}
100% {
background-position: 0% 0%;
opacity: 0.8;
}
}
document.getElementsByTagName("h1")[0].style.fontSize = "6vw";
This Pen doesn't use any external CSS resources.
This Pen doesn't use any external JavaScript resources.