/* 基本样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    /* 优雅的浅灰渐变背景 */
    background: linear-gradient(135deg, #f5f7fa 0%, #e9ecef 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    color: #343a40;
}

.container {
    background-color: #ffffff;
    padding: 40px 50px;
    border-radius: 8px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
    text-align: center;
    width: 100%;
    max-width: 400px;
}

h1 {
    margin-bottom: 30px;
    color: #343a40;
    font-weight: 600;
    font-size: 1.8em;
}

/* 关键：这是控制 Label 和 Input 布局的样式 */
.input-group {
    margin-bottom: 25px;
    text-align: left; /* 让内部元素靠左对齐 */
}

/* 关键：控制 Label 的样式 */
.input-group label {
    display: block; /* 让 Label 独占一行，显示在输入框上方 */
    margin-bottom: 8px; /* Label 和输入框之间的距离 */
    font-weight: 500;
    color: #495057;
}

/* 关键：控制 Input 的样式 */
.input-group input[type="text"], /* 同时应用于 type="text" */
.input-group input[type="password"] { /* 和 type="password" */
    width: 100%; /* 输入框宽度占满父容器 (.input-group) */
    padding: 12px 15px; /* 输入框内部边距 */
    border: 1px solid #ced4da;
    border-radius: 5px;
    font-size: 1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    color: #495057;
}

.input-group input[type="text"]:focus,
.input-group input[type="password"]:focus {
    outline: none;
    border-color: #adb5bd;
    box-shadow: 0 0 0 3px rgba(173, 181, 189, 0.25);
}

button {
    background-color: #495057;
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    transition: background-color 0.3s ease, transform 0.1s ease;
    width: 100%; /* 按钮宽度占满 */
    margin-top: 5px; /* 与上方输入框组稍微隔开一点距离 */
}

button:hover {
    background-color: #343a40;
}

button:active {
    transform: scale(0.98);
}

#statusMessage {
    margin-top: 25px;
    font-weight: 500;
    min-height: 1.2em;
}

.success {
    color: #198754;
}

.error {
    color: #dc3545;
}