/* mysite/home/static/home/account_style.css */

/* 我们只在 body.login-body 上应用动画背景
*/
body.login-body {
    font-family: 'ZCOOL+KuaiLe', 'Arial Rounded MT Bold', sans-serif;
    color: #444;
    background: linear-gradient(-45deg, #f0f8ff, #ffefba, #ffe0e0, #e0fffa);
    background-size: 400% 400%;
    animation: gradientBG 20s ease infinite;
    height: 100vh;
    /* 移除 display:flex, 
      让 .login-container 自己来居中 
    */
}

/* 动画背景的 Keyframes */
@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* 新增：登录页的包裹容器 */
.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: calc(100vh - 100px); /* 减去 header 的大致高度 */
    padding: 2rem 0;
}

/* 登录/注册的卡片 */
.account-card {
    background: #ffffff;
    padding: 2.5rem 3rem;
    border-radius: 25px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    width: 380px;
    text-align: center;
    transition: box-shadow 0.4s ease;
    border: 3px solid white;
    margin-top: -50px; /* 向上移动一点，弥补 header 的空间 */
}

.account-card:focus-within {
    box-shadow: 0 0 30px 10px rgba(255, 107, 107, 0.4);
    border: 3px solid rgba(255, 107, 107, 0.6);
}

.account-card h1 {
    font-size: 2.8rem;
    color: #ff6347; 
    margin-top: 0;
    margin-bottom: 2rem;
}

.account-form p { margin-bottom: 1.5rem; text-align: left; }
.account-form label {
    font-size: 1.2rem;
    color: #555;
    display: block;
    margin-bottom: 8px;
}

.account-form input[type="text"],
.account-form input[type="password"] {
    width: 100%;
    padding: 14px;
    border: 2px solid #ddd;
    border-radius: 12px;
    font-size: 1.1rem;
    font-family: 'Arial Rounded MT Bold', sans-serif;
    box-sizing: border-box; 
    transition: border-color 0.3s ease;
}

.account-form input:focus {
    border-color: #ff6b6b;
    outline: none; 
}

.account-form .helptext { font-size: 0.85rem; color: #999; margin-top: 5px; }
.account-form .errorlist {
    color: #e74c3c;
    font-size: 0.9rem;
    list-style: none;
    padding: 0;
    margin-top: 5px;
}

.submit-button {
    width: 100%;
    padding: 15px;
    font-family: 'ZCOOL+KuaiLe', sans-serif;
    font-size: 1.5rem;
    font-weight: bold;
    color: white;
    background-color: #ff6347;
    border: none;
    border-radius: 15px;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    margin-top: 1rem;
}
.submit-button:hover {
    transform: scale(1.03);
    box-shadow: 0 6px 15px rgba(255, 99, 71, 0.4);
}

.switch-link { margin-top: 2rem; font-size: 1.1rem; }
.switch-link a {
    color: #ff6b6b;
    font-weight: bold;
    text-decoration: none;
    transition: transform 0.2s ease;
    display: inline-block;
}
.switch-link a:hover { transform: scale(1.05); text-decoration: underline; }

/* 移除返回首页链接，因为它现在在 header 里了 */
.home-link { display: none; }
/* --- 新添加的表单字段样式 --- */

/* 每个字段（标签 + 输入框 + 错误）的包裹容器 */
.field-wrapper {
    margin-bottom: 15px;
}

/* 字段错误信息的样式 */
.field-errors {
    color: red;
    font-size: 0.9em;
    margin-top: 5px;
}

/* 错误信息里的 <p> 标签 */
.field-errors .error-message {
    margin: 0;
    padding: 0;
}

/* 字段帮助文本 (例如 "密码不能太简单") */
.help-text {
    font-size: 0.9em;
    color: #666;
    margin-top: 5px;
    margin-bottom: 0;
}