/* login.css */

/* 基础主体样式可以从 styles.css 继承或在这里覆盖 */
body {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    /* 移除默认边距 */
    /* 可以考虑设置与 index.html 一致的背景色 */
    /* background-color: var(--background-color); */
    /* color: var(--text-color); */
}

header {
    width: 100%;
    text-align: center;
    padding: 1rem 0;
    border-bottom: 1px solid #ccc;
    background-color: #f8f8f8;
    /* 示例浅色背景 */
    position: relative;
    /* 为了主题按钮定位 */
}

header h1,
header h2,
header h3 {
    margin: 0.2em 0;
}

/* 如果需要复用主题切换按钮样式，确保 styles.css 中的相关规则能应用 */
#theme-toggle-button {
    position: absolute;
    top: 10px;
    right: 20px;
    padding: 8px 12px;
    background: none;
    border: 1px solid #ccc;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1.2em;
}

main {
    flex-grow: 1;
    /* 让 main 区域占据剩余空间 */
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    padding: 2rem;
}

.login-container {
    width: 100%;
    max-width: 400px;
    /* 限制登录框最大宽度 */
    padding: 2rem;
    border: 1px solid #ddd;
    border-radius: 8px;
    background-color: #fff;
    /* 登录框背景 */
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.login-container h2 {
    text-align: center;
    margin-bottom: 1.5rem;
    color: #333;
}

.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: bold;
    color: #555;
}

.form-group input[type="email"],
.form-group input[type="password"] {
    width: 100%;
    padding: 0.8rem;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-sizing: border-box;
    /* 防止 padding 撑大元素 */
    font-size: 1rem;
}

button[type="submit"] {
    width: 100%;
    padding: 0.8rem;
    background-color: #007bff;
    /* 示例按钮颜色 */
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1.1rem;
    transition: background-color 0.3s ease;
}

button[type="submit"]:hover {
    background-color: #0056b3;
}

.error-message {
    color: red;
    margin-top: 1rem;
    text-align: center;
    font-size: 0.9em;
}

.signup-link {
    text-align: center;
    margin-top: 1rem;
    font-size: 0.9em;
    color: #555;
}

.signup-link a {
    color: #007bff;
    text-decoration: none;
}

.signup-link a:hover {
    text-decoration: underline;
}

/* 英文文本样式 (如果需要区分) */
.en-text {
    font-size: 0.85em;
    color: #666;
    margin-left: 5px;
}