forked from iti-framework/iTi-Flask
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
358 lines
10 KiB
HTML
358 lines
10 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="zh-CN">
|
|
<head>
|
|
<meta charset="UTF-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<title>500 - 服务器错误</title>
|
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
|
|
<style>
|
|
:root {
|
|
--primary-color: #818cf8;
|
|
--background-color: #ffffff;
|
|
--text-color: #1f2937;
|
|
--transition-speed: 0.3s;
|
|
}
|
|
|
|
[data-theme="dark"] {
|
|
--primary-color: #6366f1;
|
|
--background-color: #111827;
|
|
--text-color: #f3f4f6;
|
|
--card-background: #1f2937;
|
|
--card-shadow: rgba(0, 0, 0, 0.3);
|
|
--button-background: #6366f1;
|
|
--button-text: #ffffff;
|
|
--button-hover: #4f46e5;
|
|
--button-active: #4338ca;
|
|
}
|
|
|
|
* {
|
|
margin: 0;
|
|
padding: 0;
|
|
box-sizing: border-box;
|
|
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
|
|
}
|
|
|
|
body {
|
|
background-color: var(--background-color);
|
|
color: var(--text-color);
|
|
min-height: 100vh;
|
|
display: flex;
|
|
flex-direction: column;
|
|
justify-content: center;
|
|
align-items: center;
|
|
transition: background-color var(--transition-speed), color var(--transition-speed);
|
|
position: relative;
|
|
overflow: hidden;
|
|
padding: 2rem;
|
|
padding-top: 5rem; /* 避免被固定 header 覆盖 */
|
|
text-align: center;
|
|
}
|
|
|
|
/* 背景动画元素 */
|
|
.background-animation {
|
|
position: fixed;
|
|
top: 0;
|
|
left: 0;
|
|
width: 100%;
|
|
height: 100%;
|
|
z-index: -1;
|
|
overflow: hidden;
|
|
}
|
|
|
|
.particle {
|
|
position: absolute;
|
|
border-radius: 50%;
|
|
background-color: var(--primary-color);
|
|
opacity: 0.1;
|
|
animation: float 20s infinite ease-in-out;
|
|
}
|
|
|
|
/* Logo水印 */
|
|
.logo-watermark {
|
|
position: fixed;
|
|
top: 50%;
|
|
left: 50%;
|
|
transform: translate(-50%, -50%) scale(2);
|
|
opacity: 0.03;
|
|
z-index: -1;
|
|
width: 200px;
|
|
height: 200px;
|
|
background-image: url('./logo.png');
|
|
background-size: contain;
|
|
background-repeat: no-repeat;
|
|
background-position: center;
|
|
transition: opacity var(--transition-speed);
|
|
}
|
|
|
|
/* 错误内容容器 */
|
|
.error-container {
|
|
max-width: 600px;
|
|
width: 100%;
|
|
transform: translateY(20px);
|
|
opacity: 0;
|
|
animation: fadeIn 0.8s ease forwards;
|
|
margin-bottom: auto;
|
|
}
|
|
|
|
/* 错误代码 */
|
|
.error-code {
|
|
font-size: 8rem;
|
|
font-weight: 700;
|
|
color: var(--primary-color);
|
|
margin-bottom: 1rem;
|
|
position: relative;
|
|
display: inline-block;
|
|
animation: pulse 2s infinite ease-in-out;
|
|
text-shadow: 0 0 30px rgba(129, 140, 248, 0.2);
|
|
}
|
|
|
|
/* 错误标题 */
|
|
.error-title {
|
|
font-size: 2rem;
|
|
font-weight: 600;
|
|
margin-bottom: 1rem;
|
|
color: var(--text-color);
|
|
}
|
|
|
|
/* 错误描述 */
|
|
.error-description {
|
|
font-size: 1.1rem;
|
|
line-height: 1.8;
|
|
margin-bottom: 2rem;
|
|
color: var(--text-color);
|
|
opacity: 0.9;
|
|
max-width: 500px;
|
|
margin-left: auto;
|
|
margin-right: auto;
|
|
}
|
|
|
|
/* 按钮组 */
|
|
.button-group {
|
|
display: flex;
|
|
gap: 1rem;
|
|
justify-content: center;
|
|
margin-bottom: 2rem;
|
|
}
|
|
|
|
/* 按钮样式 */
|
|
.btn {
|
|
padding: 0.8rem 1.5rem;
|
|
border: none;
|
|
border-radius: 0.5rem;
|
|
font-size: 1rem;
|
|
font-weight: 600;
|
|
cursor: pointer;
|
|
transition: all 0.2s ease;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
gap: 0.5rem;
|
|
background-color: var(--primary-color);
|
|
color: white;
|
|
}
|
|
|
|
.btn:hover {
|
|
opacity: 0.9;
|
|
transform: translateY(-2px);
|
|
}
|
|
|
|
.btn:active {
|
|
opacity: 0.8;
|
|
transform: translateY(0);
|
|
}
|
|
|
|
/* 版权信息区域 */
|
|
.footer {
|
|
margin-top: auto;
|
|
padding: 1.5rem;
|
|
width: 100%;
|
|
border-top: 1px solid rgba(0, 0, 0, 0.1);
|
|
font-size: 0.9rem;
|
|
color: var(--text-color);
|
|
opacity: 0.7;
|
|
transition: all var(--transition-speed);
|
|
}
|
|
|
|
/* 主题切换按钮 */
|
|
.theme-toggle {
|
|
position: fixed;
|
|
top: 1rem;
|
|
right: 1rem;
|
|
background-color: rgba(255, 255, 255, 0.8);
|
|
border: none;
|
|
border-radius: 50%;
|
|
width: 2.5rem;
|
|
height: 2.5rem;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
cursor: pointer;
|
|
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
|
|
transition: all 0.2s ease;
|
|
z-index: 100;
|
|
backdrop-filter: blur(10px);
|
|
}
|
|
|
|
.theme-toggle:hover {
|
|
transform: scale(1.1);
|
|
}
|
|
|
|
.theme-toggle i {
|
|
color: var(--text-color);
|
|
font-size: 1.2rem;
|
|
}
|
|
|
|
/* 动画效果 */
|
|
@keyframes fadeIn {
|
|
to {
|
|
transform: translateY(0);
|
|
opacity: 1;
|
|
}
|
|
}
|
|
|
|
@keyframes pulse {
|
|
0%, 100% {
|
|
transform: scale(1);
|
|
opacity: 1;
|
|
}
|
|
50% {
|
|
transform: scale(1.05);
|
|
opacity: 0.9;
|
|
}
|
|
}
|
|
|
|
@keyframes float {
|
|
0%, 100% {
|
|
transform: translateY(0) translateX(0);
|
|
}
|
|
25% {
|
|
transform: translateY(-20px) translateX(20px);
|
|
}
|
|
50% {
|
|
transform: translateY(-40px) translateX(0);
|
|
}
|
|
75% {
|
|
transform: translateY(-20px) translateX(-20px);
|
|
}
|
|
}
|
|
|
|
/* 响应式调整 */
|
|
@media (max-width: 768px) {
|
|
.error-code {
|
|
font-size: 6rem;
|
|
}
|
|
|
|
.error-title {
|
|
font-size: 1.8rem;
|
|
}
|
|
|
|
.button-group {
|
|
flex-direction: column;
|
|
gap: 0.8rem;
|
|
}
|
|
|
|
.btn {
|
|
width: 100%;
|
|
}
|
|
}
|
|
|
|
@media (max-width: 480px) {
|
|
.error-code {
|
|
font-size: 4.5rem;
|
|
}
|
|
|
|
.error-title {
|
|
font-size: 1.5rem;
|
|
}
|
|
|
|
.error-description {
|
|
font-size: 1rem;
|
|
}
|
|
|
|
.footer {
|
|
font-size: 0.8rem;
|
|
}
|
|
}
|
|
</style>
|
|
</head>
|
|
<body>
|
|
{% include 'errors/header.html' %}
|
|
<!-- 背景动画 -->
|
|
<div class="background-animation" id="backgroundAnimation"></div>
|
|
|
|
<!-- Logo水印 -->
|
|
<div class="logo-watermark"></div>
|
|
|
|
<!-- 错误内容容器 -->
|
|
<div class="error-container">
|
|
<div class="error-code">500</div>
|
|
<h1 class="error-title">服务器错误</h1>
|
|
<p class="error-description">
|
|
抱歉,服务器遇到了意外错误。
|
|
这可能是由于服务器暂时过载、维护或内部故障导致的。
|
|
请稍后重试,或联系管理员报告此问题。
|
|
</p>
|
|
<div class="button-group">
|
|
<button class="btn" id="refreshBtn">
|
|
<i class="fa fa-refresh"></i> 刷新页面
|
|
</button>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- 页脚区域 -->
|
|
{% include 'errors/footer.html' %}
|
|
|
|
<script>
|
|
// 创建背景动画粒子
|
|
function createBackgroundParticles() {
|
|
const container = document.getElementById('backgroundAnimation');
|
|
const particleCount = 20;
|
|
|
|
// 清除现有粒子
|
|
container.innerHTML = '';
|
|
|
|
// 创建新粒子
|
|
for (let i = 0; i < particleCount; i++) {
|
|
const particle = document.createElement('div');
|
|
particle.classList.add('particle');
|
|
|
|
// 随机大小
|
|
const size = Math.random() * 100 + 50;
|
|
particle.style.width = `${size}px`;
|
|
particle.style.height = `${size}px`;
|
|
|
|
// 随机位置
|
|
particle.style.left = `${Math.random() * 100}%`;
|
|
particle.style.top = `${Math.random() * 100}%`;
|
|
|
|
// 随机动画延迟
|
|
particle.style.animationDelay = `${Math.random() * 20}s`;
|
|
|
|
// 随机动画持续时间
|
|
particle.style.animationDuration = `${Math.random() * 20 + 20}s`;
|
|
|
|
container.appendChild(particle);
|
|
}
|
|
}
|
|
|
|
// 按钮功能
|
|
const refreshBtn = document.getElementById('refreshBtn');
|
|
|
|
refreshBtn.addEventListener('click', () => {
|
|
window.location.reload();
|
|
});
|
|
|
|
// 页面加载完成后执行
|
|
window.addEventListener('DOMContentLoaded', () => {
|
|
document.body.classList.add('loaded');
|
|
createBackgroundParticles();
|
|
});
|
|
|
|
// 窗口大小改变时重新创建粒子
|
|
window.addEventListener('resize', () => {
|
|
createBackgroundParticles();
|
|
});
|
|
</script>
|
|
</body>
|
|
</html>
|