HTML代码
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>404 - 页面未找到</title>
<style type="text/css">
/* 统一设置字体 */
body {
font-family: 'Courgette', cursive;
background: linear-gradient(#e5f9f7, #d1f5f1, #f7fdfc); /* 使用线性渐变背景色 */
margin: 0;
padding: 0;
}
/* 居中显示内容 */
.container {
width: 100%;
height: 100vh; /* 视窗高度 */
display: flex;
justify-content: center;
align-items: center;
flex-direction: column;
}
.container .in {
background: #fff;
padding: 0 10%;
border: 4px solid #c0ece7;
border-color: rgba(192, 237, 232, 07);
}
/* 优化Logo样式 */
.container .in h2 {
line-height: 50px;
font-size: 30px;
font-family:MicrosoftYaHei;
color: #e94c3c;
border-bottom: 1px dashed #aacdd5;
padding: 18px 0;
}
.container .in p {
padding: 30px 0 50px 0;
text-align: center;
color: #e94c3c;
}
</style>
</head>
<body>
<div class="container">
<div class="in">
<div class="textThis">
<h2>出错啦404!</h2>
<p>SORRY,页面没有找到</p>
</div>
</div>
</div>
</body>
</html>