1、三角形
width:0;
height:0;
border-width:0 40px 40px;
border-color:transparent transparent color
2、八边形
.box {
width: 80px;
height: 16px;
background: #b37059;
position: relative;
text-align: center;
margin: 6px 0;
&::before {
content: '';
width: 67px;
height: 20px;
border: 6px solid;
border-left-color: transparent;
border-right-color: transparent;
border-bottom-color: #b37059;
border-top-color: transparent;
position: absolute;
top: 100%;
left: 0;
transform: rotate(180deg);
}
&::after {
content: '';
width: 67px;
height: 20px;
border: 6px solid;
border-left-color: transparent;
border-right-color: transparent;
border-bottom-color: #b37059;
border-top-color: transparent;
position: absolute;
top: -200%;
left: 0;
}
}