Z-INDEX 没效果
Z-INDEX 没效果
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>无标题文档</title>
<style>
*{
margin:0;
padding:0;
font-size:20px;
font-weight:bold;
font-family:Arial;
}
.box{
width:1000px;
height:400px;
margin: 10px auto;
box-shadow:0 1px 4px rgba(0,0,0,0.2),0 0 40px rgba(0,0,0,0.1) inset;
position:relative;
z-index:1;
}
.box:after, .box:before{
content:"";
background:#000;
top:50%;
bottom:0;
left:10px;
right:10px;
position:absolute;
z-index:-1;
-webkit-box-shadow:0 0 20px rgba(0,0,0,0.8);
-moz-box-shadow:0 0 20px rgba(0,0,0,0.8);
box-shadow:0 0 20px rgba(0,0,0,0.8);
-moz-border-radius:100px / 10px;
border-radius:100px / 10px;
}
.box h1{
text-align:center;
line-height:400px;
}
</style>
</head>
<body>
<div class="box">
<h1>Hello,Word!</h1>
</div>
</body>
</html>