<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
<style>
* {
margin: 0px;
padding: 0px;
list-style: none;
}
ul {
width: 291px;
height: 161px;
background: lime;
}
li {
width: 291px;
height: 161px;
overflow: hidden;/* 超出部分隐藏*/
position: relative;
}
img {
width: 291px;
}
p {
position: absolute;
bottom: 0px;
left: 0px;
width: 259px;
padding: 8px 16px;
/* rgba透明色 rgb红