css 实现边框内圆角

需要用到的知识就是box-shadow , 和 outline  实现多重边框

实现这样的效果

<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title></title>
		<style type="text/css">
			.dd {
				position: absolute;
				left: 400px;
				top: 200px;
				width: calc(100% - 800px);
				height: calc(100% - 400px);
				background: lawngreen;
				
				border-radius: 50px;
				box-shadow: 0 0 0 30px #665555;
				outline: 50px solid #665555;
				
				
			}
		</style>
	</head>
	<body>
		
		<div class="dd">
			
		</div>
		
		
	</body>
</html>

  

猜你喜欢

转载自www.cnblogs.com/lilei-site/p/11785466.html