【发布时间】:2014-01-07 21:38:47
【问题描述】:
这是我的 JSFiddle:http://jsfiddle.net/7FFRV/1/
我试图让蓝色边框在红色圆圈的盒子阴影后面,但在容器前面。我该怎么做?
HTML:
<div class="container">
<div class="image"></div>
</div>
CSS:
.container {
width: 250px;
height: 250px;
padding: 30px;
background: #fbfbfb;
border: 1px solid black;
}
.image {
width: 150px;
height: 150px;
background: red;
border-radius: 500px;
box-shadow: 0 0 10px rgba(0, 0, 0, 0.75);
}
.image:after {
content: "";
position: absolute;
left: -0;
width: 150px;
height: 150px;
border-radius: 500px;
border: 10px solid #0077ca;
}
【问题讨论】:
标签: css