效果如下:
实现:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Document</title>
<style type="text/css">
div{
width: 0;
height: 0;
border-left: 100px solid transparent;
border-bottom: 70px solid red;
border-right: 100px solid transparent;
transform: rotate(36deg);
position: relative;
margin: 200px;
}
div::after{
content: '';
display: block;
width: 0;
height: 0;
border-left: 100px solid transparent;
border-bottom: 70px solid yellow;
border-right: 100px solid transparent;
position: relative;
transform: rotate(74deg);
left:-98px;
top: -67px;
}
div::before{
content: '';
display: block;
width: 0;
height: 0;
border-left: 100px solid transparent;
border-bottom: 70px solid blue;
border-right: 100px solid transparent;
position: relative;
transform: rotate(290deg);
left: -103px;
top: 2px;
}
</style>
</head>
<body>
<div></div>
</body>
</html>