div+css布局实现层叠霓虹灯文字代码
代码语言:html
所属分类:布局界面
代码描述:div+css布局实现层叠霓虹灯文字代码
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html> <html lang="en" > <head> <meta charset="UTF-8"> <style> @import url("https://fonts.googleapis.com/css2?family=Orbitron:wght@400..900&display=swap"); body { background: linear-gradient(#222 51%, #111 53%); color: #fff; display: grid; place-items: center; height: 100vh; font-family: 'Orbitron'; } span { position: relative; font-size: 156px; -webkit-box-reflect: below -25px linear-gradient(transparent 35%, rgba(0,0,0,0.25)); } .t0 { position: relative; color: #111; -webkit-text-stroke: 2px #0f0; z-index: 3; } .t1 { position: absolute; color: transparent; -webkit-text-stroke: 2px #00f; z-index: 2; animation: move 5s ease infinite alternate; } .t2 { content: 'CODEPEN'; position: absolute; color: transparent; -webkit-text-stroke: 2px #f00; z-index: 1; animation: move-reverse 5s ease infinite alternate; } @-moz-keyframes move { 0%, 100% { transform: translate(0, 0); } 25% { transform: translate(-5px, -5px); } 50% { transform: translate(5px, -5px); } 75% { transform: translate(-5px, 5px); } } @-webkit-keyframes move { 0%, 100% { transform: translate(0, 0); } 25% { transform: translate(-5px, -5px); } 50% { transform: translate(5px, -5px); } 75% { transform: translate(-5px, 5px); } } @-o-keyframes move { 0%, 100% { transform: translate(0, 0); } 25% { transform: translate(-5px, -5px);.........完整代码请登录后点击上方下载按钮下载查看
网友评论0