12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758 |
- body {
- font-family: Arial, sans-serif; /* 设置字体风格为Arial,无衬线 */
- background: #f4f4f4; /* 设置背景颜色 */
- margin: 0;
- padding: 0;
- display: flex; /* 使用Flexbox布局 */
- justify-content: center; /* 水平居中内容 */
- align-items: center; /* 垂直居中内容 */
- height: 100vh; /* 高度占满视口 */
- }
- .login-container {
- background: white; /* 白色背景 */
- padding: 20px; /* 内边距20像素 */
- border-radius: 5px; /* 边角圆滑化 */
- box-shadow: 0 0 10px rgba(0,0,0,0.1); /* 盒子阴影效果 */
- text-align: center; /* 文本居中 */
- }
- .form-group {
- margin-bottom: 15px; /* 底部外边距 */
- text-align: left; /* 左对齐文本 */
- }
- label {
- display: block; /* 让标签独占一行 */
- margin-bottom: 5px; /* 标签下方外边距 */
- }
- input[type="text"],
- input[type="password"] {
- width: calc(100% - 22px); /* 计算宽度,保留一些空间 */
- padding: 10px; /* 内边距 */
- border: 1px solid #ddd; /* 边框 */
- border-radius: 5px; /* 边角圆滑化 */
- }
- button {
- width: 100%; /* 按钮宽度100% */
- padding: 10px; /* 内边距 */
- background-color: #5c67f2; /* 按钮背景颜色 */
- border: none; /* 无边框 */
- color: white; /* 文字颜色白色 */
- border-radius: 5px; /* 边角圆滑化 */
- cursor: pointer; /* 鼠标悬停指针形状 */
- }
- button:hover {
- background-color: #4a54e1; /* 鼠标悬停时变色 */
- }
- a {
- color: #5c67f2; /* 链接颜色 */
- text-decoration: none; /* 无下划线 */
- }
- a:hover {
- text-decoration: underline; /* 悬停时出现下划线 */
- }
|