galaxy/Buttons/Mohammad-Rahme-576_spicy-grasshopper-17.html

288 lines
No EOL
5 KiB
HTML

<button class="button">Join Today ➞</button>
<style>
/* From Uiverse.io by Mohammad-Rahme-576 - Tags: button */
.button {
position: relative;
padding: 15px 30px; /* Button padding */
font-size: 18px; /* Button font size */
font-weight: bold;
color: #ffffff; /* Text color */
background: #8a2be2; /* Purple background */
border: 2px solid #8a2be2;
border-radius: 12px;
cursor: pointer;
overflow: hidden;
transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
box-shadow:
0 0 10px #8a2be2,
0 0 20px #4b0082,
0 0 30px #da70d6;
text-transform: uppercase;
letter-spacing: 2px;
font-family: "Arial", sans-serif;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
background-size: 200% 200%;
animation:
gradientShift 5s ease infinite,
pulse 2s infinite;
isolation: isolate;
}
.button::before,
.button::after {
content: "";
position: absolute;
top: -50%;
left: -50%;
width: 200%;
height: 200%;
background: radial-gradient(circle, #e6e6fa 20%, transparent 70%);
opacity: 0;
transition:
opacity 0.3s,
transform 0.3s;
pointer-events: none;
}
.button::before {
background: linear-gradient(
45deg,
transparent,
rgba(255, 255, 255, 0.1),
transparent
);
transform: translateX(-100%);
transition: transform 0.6s;
z-index: -1;
}
.button::after {
background: linear-gradient(
45deg,
transparent 0%,
rgba(218, 112, 214, 0.8) 25%,
rgba(138, 43, 226, 0.8) 50%,
rgba(218, 112, 214, 0.8) 75%,
transparent 100%
);
filter: blur(5px);
transform: translateX(-100%) rotate(45deg);
}
.button:hover {
background: linear-gradient(
135deg,
#8a2be2,
#4b0082
); /* Gradient background on hover */
transform: scale(1.05) translateY(-3px) rotateY(10deg);
box-shadow:
0 0 20px #8a2be2,
0 0 40px #4b0082,
0 0 60px #da70d6;
perspective: 1000px;
border-color: rgba(218, 112, 214, 0.5);
filter: brightness(1.1) contrast(1.1);
animation:
gradientShift 5s ease infinite,
pulse 2s infinite,
gradientBorder 2s linear infinite;
}
.button:hover::before {
opacity: 0.3;
transform: translateX(100%);
animation: pulseGlow 2s infinite;
}
.button:hover::after {
opacity: 0.5;
animation: shineEffect 1.5s infinite;
}
.button:active {
transform: scale(0.98) translateY(2px);
box-shadow:
0 0 10px rgba(138, 43, 226, 0.6),
0 0 20px rgba(138, 43, 226, 0.4) inset;
}
.button span {
position: relative;
z-index: 1;
-webkit-text-stroke: 1px rgba(255, 255, 255, 0.3);
}
.button:hover span {
animation:
textGlow 1.5s infinite alternate,
textFloat 0.3s ease-out;
}
@keyframes pulseGlow {
0%,
100% {
transform: scale(1);
opacity: 0.3;
}
50% {
transform: scale(1.2);
opacity: 0.5;
}
}
@keyframes shineEffect {
0% {
transform: translateX(-100%) rotate(45deg);
}
100% {
transform: translateX(100%) rotate(45deg);
}
}
@keyframes ripple {
0% {
transform: scale(0.8);
}
50% {
transform: scale(1.2);
opacity: 0.3;
}
100% {
transform: scale(0.8);
}
}
@keyframes textGlow {
0% {
text-shadow: 0 0 5px #e6e6fa;
}
100% {
text-shadow:
0 0 20px #e6e6fa,
0 0 35px #da70d6;
}
}
@keyframes gradientShift {
0% {
background-position: 0% 50%;
}
50% {
background-position: 100% 50%;
}
100% {
background-position: 0% 50%;
}
}
@keyframes focusPulse {
0%,
100% {
box-shadow:
0 0 0 4px rgba(138, 43, 226, 0.4),
0 0 30px rgba(218, 112, 214, 0.6);
}
50% {
box-shadow:
0 0 0 8px rgba(138, 43, 226, 0.2),
0 0 40px rgba(218, 112, 214, 0.4);
}
}
@keyframes textFloat {
0%,
100% {
transform: translateY(0);
}
50% {
transform: translateY(-5px);
}
}
@keyframes particleBurst {
0% {
transform: translate(-50%, -50%) scale(0);
opacity: 1;
}
100% {
transform: translate(-50%, -50%) scale(2);
opacity: 0;
}
}
@keyframes gradientBorder {
0% {
border-color: rgba(218, 112, 214, 0.5);
}
50% {
border-color: rgba(138, 43, 226, 0.5);
}
100% {
border-color: rgba(218, 112, 214, 0.5);
}
}
@keyframes pulse {
0%,
100% {
transform: scale(1);
}
50% {
transform: scale(1.05);
}
}
.button:focus {
outline: none;
box-shadow:
0 0 0 4px rgba(138, 43, 226, 0.4),
0 0 30px rgba(218, 112, 214, 0.6);
animation: focusPulse 1.5s infinite;
}
.button:focus-visible {
outline: 2px solid #da70d6;
outline-offset: 2px;
}
.button:active::before {
opacity: 1;
transform: translateX(0) rotate(45deg);
transition: transform 0.2s;
}
.button:active::before {
animation: particleBurst 0.5s ease-out;
}
.button {
border: 2px solid transparent;
background-clip: padding-box;
}
@media (max-width: 768px) {
.button {
padding: 12px 24px;
font-size: 16px;
}
}
@media (max-width: 480px) {
.button {
padding: 10px 20px;
font-size: 14px;
}
}
@media (min-width: 1200px) {
.button {
padding: 18px 36px;
font-size: 20px;
}
}
</style>