<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
</head>
<body>
<div class="demo"></div>
<div class="demo1"></div>
</body>
<style>
.demo{
width: 0;
height: 0;
border-left: 50px solid transparent;
border-right: 50px solid transparent;
border-bottom: 100px solid red;
}
.demo1{
width: 100px;
height: 100px;
border-radius: 50%;
background-color: green;
background-image: linear-gradient(to bottom left, red, transparent); /* 从左上角到右下角的线性渐变 */
}
</style>
</html>