纯css实现简单的手机菜单效果
代码语言:html
所属分类:菜单导航
代码描述:纯css实现简单的手机菜单效果
下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<style>
html,
body {
width: 100%;
height: 100%;
}
body {
background: #FF8A8A;
color: #444;
font-family: 'Roboto';
font-weight: 300;
padding: 80px 0;
box-sizing: border-box;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
.body {
z-index: 1;
position: relative;
background: #FFF;
width: 300px;
height: 500px;
border-radius: 6px;
box-shadow: 0 0 20px rgba(0, 0, 0, 0.2);
margin: 0 auto;
overflow: hidden;
}
.app {
display: -webkit-box;
display: flex;
-webkit-box-orient: vertical;
-webkit-box-direction: normal;
flex-direction: column;
height: 100%;
}
.app-menu {
position: relative;
display: -webkit-box;
display: flex;
-webkit-box-align: center;
align-items: center;
-webkit-box-orient: horizontal;
-webkit-box-direction: normal;
flex-direction: row;
flex-wrap: nowrap;
-webkit-box-pack: justify;
justify-content: space-between;
padding: 30px 30px 20px;
}
.app-menu__title {
font-size: 16px;
font-weight: 500;
letter-spacing: 1.2px;
text-transform: uppercase;
}
.app-nav {
display: inline-block;
}
.app-nav__icon {
position: relative;
display: block;
width: 14px;
height: 10px;
cursor: pointer;
}
.app-nav__icon:before, .app-nav__icon:after {
content: "";
position: absolute;
top: 0;
left: 0;
display: block;
background: #222;
width: 10.........完整代码请登录后点击上方下载按钮下载查看
网友评论0