svg+css实现立体按钮鼠标悬停光效文字炫酷过渡动画效果代码
代码语言:html
所属分类:悬停
代码描述:svg+css实现立体按钮鼠标悬停光效文字炫酷过渡动画效果代码
代码标签: svg css 立体 按钮 鼠标 悬停 光效 文字 炫酷 过渡 动画
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html>
<html lang="en" >
<head>
<meta charset="UTF-8">
<style>
body{
height:100vh;
width:100vw;
justify-content:center;
align-content:center;
padding-left:30vw;
}
.button {
--white: #ffe7ff;
--purple-100: #f4b1fd;
--purple-200: #d190ff;
--purple-300: #c389f2;
--purple-400: #8e26e2;
--purple-500: #5e2b83;
--radius: 18px;
border-radius: var(--radius);
outline: none;
cursor: pointer;
font-size: 23px;
font-family: Arial;
background: transparent;
letter-spacing: -1px;
border: 0;
position: relative;
width: 220px;
height: 80px;
transform: rotate(353deg) skewX(4deg);
}
.bg {
position: absolute;
inset: 0;
border-radius: inherit;
filter: blur(1px);
}
.bg::before,
.bg::after {
content: "";
position: absolute;
inset: 0;
border-radius: calc(var(--radius) * 1.1);
background: var(--purple-500);
}
.bg::before {
filter: blur(5px);
transition: all 0.3s ease;
box-shadow:
-7px 6px 0 0 rgb(115 75 155 / 40%),
-14px 12px 0 0 rgb(115 75 155 / 30%),
-21px 18px 4px 0 rgb(115 75 155 / 25%),
-28px 24px 8px 0 rgb(115 75 155 / 15%),
-35px 30px 12px 0 rgb(115 75 155 / 12%),
-42px 36px 16px 0 rgb(115 75 155 / 8%),
-56px 42px 20px 0 rgb(115 75 155 / 5%);
}
.wrap {
border-radius: inherit;
overflow: hi.........完整代码请登录后点击上方下载按钮下载查看
















网友评论0