|
|
<!DOCTYPE html> |
|
|
<html lang="zh-CN"> |
|
|
<head> |
|
|
<meta charset="UTF-8"> |
|
|
<title>登录</title> |
|
|
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;600&display=swap" rel="stylesheet"> |
|
|
<style> |
|
|
:root { |
|
|
--bg-primary: #f4f6f9; |
|
|
--card-bg: #ffffff; |
|
|
--text-primary: #2c3e50; |
|
|
--text-secondary: #6c757d; |
|
|
--border-color: #e2e8f0; |
|
|
--primary-color: #3498db; |
|
|
} |
|
|
* { box-sizing: border-box; margin: 0; padding: 0; } |
|
|
body { |
|
|
font-family: 'Inter', sans-serif; |
|
|
background-color: var(--bg-primary); |
|
|
color: var(--text-primary); |
|
|
display: flex; |
|
|
justify-content: center; |
|
|
align-items: center; |
|
|
height: 100vh; |
|
|
} |
|
|
.login-form { |
|
|
background: var(--card-bg); |
|
|
padding: 40px; |
|
|
border-radius: 16px; |
|
|
box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08); |
|
|
width: 100%; |
|
|
max-width: 400px; |
|
|
} |
|
|
h2 { |
|
|
text-align: center; |
|
|
margin-bottom: 20px; |
|
|
color: var(--text-primary); |
|
|
} |
|
|
input { |
|
|
width: 100%; |
|
|
padding: 12px 15px; |
|
|
margin: 10px 0; |
|
|
border: 1px solid var(--border-color); |
|
|
border-radius: 8px; |
|
|
font-size: 16px; |
|
|
} |
|
|
button { |
|
|
width: 100%; |
|
|
padding: 12px; |
|
|
background-color: var(--primary-color); |
|
|
color: white; |
|
|
border: none; |
|
|
border-radius: 8px; |
|
|
cursor: pointer; |
|
|
transition: background-color 0.3s; |
|
|
} |
|
|
button:hover { background-color: #2980b9; } |
|
|
</style> |
|
|
</head> |
|
|
<body> |
|
|
<div class="login-form"> |
|
|
<h2>管理员登录</h2> |
|
|
<form action="/manager/login" method="post"> |
|
|
<input type="password" name="password" placeholder="输入管理员密码" required> |
|
|
<button type="submit">登录</button> |
|
|
</form> |
|
|
</div> |
|
|
{% if error %} |
|
|
<div id="notification" style="position: fixed; top: 20px; left: 50%; transform: translateX(-50%); background-color: #f44336; color: white; padding: 10px 20px; border-radius: 8px; box-shadow: 0 4px 8px rgba(0,0,0,0.2); display: block; z-index: 1000;">密码错误</div> |
|
|
<script> |
|
|
setTimeout(() => { |
|
|
document.getElementById('notification').style.display = 'none'; |
|
|
}, 2000); |
|
|
</script> |
|
|
{% endif %} |
|
|
</body> |
|
|
</html> |