css实现弹出下拉菜单动态效果代码

代码语言:html

所属分类:菜单导航

代码描述:css实现弹出下拉菜单动态效果代码

代码标签: 下拉菜单 动态 效果

下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开


<!DOCTYPE html>
<html lang="en" >

<head>

  <meta charset="UTF-8">

  
  
<style>
html,body{
  min-height:100%
}
body {
  background: #26a56C url(//repo.bfw.wiki/bfwrepo/image/60963389b5aa3.png) center no-repeat;
  background-size:cover;
  color: #26D56C;
  font-family:sans-serif
}


.box{
   background-color: inherit ;
  border:3px solid #fff;
  width: 140px;
  max-height: 60px;
  position: absolute;
  top: 40vmin;
  left: 50%;
    margin-left: -80px;
   transition: all 0.6s ease;
}
.box.active{
   background-color: #fff;
   box-shadow: 0px 7px 10px rgba(0,0,0,0.2);
   max-height: 600px;
}
.icon {
  width: 40px;
  height: 40px;
  -webkit-border-radius: 100%;
  border-radius: 100%;
  position: absolute;
  top: 30px;
  left: 50%;
  cursor: pointer;
  margin: -20px;
  z-index:99
}
.icon i {
  width: 2px;
  height: 14px;
  display: block;
  
  left: 14px;
  position: absolute;
  top: 10px;
  opacity: 0;
  font-size:22px;
  font-weight:bold;
  transition: all 0.9s ease;
}
.icon:after {
  content: '';
  display: block;
  width: 10px;
  height: 10px;
  -webkit-border-radius: 100%;
  border-radius: 100%;
  position: absolute;
  left: 15px;
  top: 15px;
 
  box-shadow: 14px 0px 0px #fff, -14px 0px 0px #fff;
  
  transition: all 0.4s ease;
  z-index: -1;
}
.icon:before {
  content: '';
  display: block;
  width: 40px;
  height: 40px;
  border-radius: 100%;
  -webkit-transform: scale(0.25);
 
  transform: scale(0.25);
  background: #fff;
  position: absolute;
  -webkit-transition: all 0.6s ease;
 
  transition: all 0.6s ease;
}
.icon.active:before {
  -webkit-transform: scale(1);
 
  transform: scale(1);
}
.icon.active:after {
  -webkit-box-shadow: 0px 0px 0px #fff, 0px 0px 0px #fff;
  box-shadow: 0px 0px 0px #fff, 0px 0px 0px #fff;
  opacity: 0.4;
 
}
.icon.active i {
  opacity: 1;
  -ms-fil.........完整代码请登录后点击上方下载按钮下载查看

网友评论0