您的位置:首页 > Web前端 > CSS

鼠标滑过边框加阴影css3

2017-07-24 15:58 344 查看
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>无标题文档</title>
<style>
div { border:#CCC solid 1px; width:200px; height:200px;}
div:hover {
box-shadow: 0px 0px 5px #888888;/* 边框阴影 */
-moz-box-shadow: 0px 0px 5px #888888; /* 老的 Firefox */  }
</style>
</head>

<body>
<div></div>
</body>
</html>
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>无标题文档</title>
<style>
.xiangmu .mid ul li:hover {
-moz-box-shadow: 5px 5px 10px #ddd;
-webkit-box-shadow: 5px 5px 10px #ddd;
box-shadow: 5px 5px 10px #ddd;
transform: translate3d(0,-2px,0);
}
.xiangmu .mid ul li {
padding: 15px 30px;
height: 170px;
border-top: 1px solid #ddd;
transition: all 0.5s;
}

</style>
</head>

<body>
<div class="xiangmu">
<div class="mid">
<ul>
<li>111111</li>
<li>2222222222</li>
<li>3333333333</li>
<li>4444444444</li>
</ul>
</div>
</div>
<div class="tou_lan"><h4><a href="#">aaaaaaa</a></h4></div>
<div class="tou_right"><h4><a href="#">bbbbb</a></h4></div>
</body>
</html>
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: