用html + css 写一个好看的404页面
时间: 2024-06-04 11:14:08 浏览: 88
<!DOCTYPE html>
<html>
<head>
<title>404 Error</title>
<style type="text/css">
body {
background-color: #f1f1f1;
font-family: Arial, sans-serif;
color: #333;
}
.container {
margin: 0 auto;
max-width: 800px;
text-align: center;
padding: 100px 0;
}
h1 {
font-size: 6em;
margin-bottom: 0;
color: #d9534f;
}
p {
font-size: 1.5em;
margin-top: 0;
}
a {
color: #d9534f;
text-decoration: none;
border-bottom: 2px solid #d9534f;
padding-bottom: 3px;
}
a:hover {
background-color: #d9534f;
color: #fff;
}
</style>
</head>
<body>
<div class="container">
<h1>404</h1>
<p>Oops! The page you were looking for doesn't exist.</p>
<p>Go back to <a href="#">Homepage</a></p>
</div>
</body>
</html>
阅读全文