* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Microsoft Yahei", sans-serif;
}

body {
  background-color: #f5f7fa;
  color: #333;
}

/* 登录页样式 */
.login-wrap {
  width: 100%;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #2c3e50;
}
.login-box {
  width: 380px;
  padding: 40px 30px;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 0 20px rgba(0,0,0,0.2);
}
.login-box h2 {
  text-align: center;
  margin-bottom: 30px;
  color: #2c3e50;
}
.form-item {
  margin-bottom: 20px;
}
.form-item label {
  display: block;
  margin-bottom: 8px;
  font-weight: 500;
}
.form-item input {
  width: 100%;
  height: 42px;
  padding: 0 12px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 14px;
}
.btn {
  width: 100%;
  height: 44px;
  border: none;
  border-radius: 4px;
  background: #3498db;
  color: #fff;
  font-size: 16px;
  cursor: pointer;
  transition: 0.2s;
}
.btn:hover {
  background: #2980b9;
}
.tip {
  margin-top: 15px;
  text-align: center;
  color: #e74c3c;
  font-size: 14px;
}

/* 后台布局 */
.admin-container {
  display: flex;
  min-height: 100vh;
}
.sidebar {
  width: 220px;
  background: #2c3e50;
  color: #fff;
  padding-top: 20px;
}
.sidebar h3 {
  text-align: center;
  padding-bottom: 20px;
  border-bottom: 1px solid #445566;
  margin-bottom: 20px;
}
.sidebar-menu li {
  list-style: none;
}
.sidebar-menu li a {
  display: block;
  padding: 14px 25px;
  color: #bdc3c7;
  text-decoration: none;
  transition: 0.2s;
}
.sidebar-menu li a:hover,
.sidebar-menu li a.active {
  background: #34495e;
  color: #fff;
}

.main {
  flex: 1;
  padding: 30px;
}
.title {
  font-size: 22px;
  margin-bottom: 25px;
  padding-bottom: 10px;
  border-bottom: 1px solid #eee;
}

/* 表格样式 */
.table-box {
  background: #fff;
  padding: 20px;
  border-radius: 6px;
  box-shadow: 0 1px 5px rgba(0,0,0,0.1);
  margin-bottom: 30px;
}
table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 15px;
}
th, td {
  border: 1px solid #eee;
  padding: 12px;
  text-align: center;
}
th {
  background: #f8f9fa;
}

/* 弹窗/表单 */
.add-form {
  background: #fff;
  padding: 20px;
  border-radius: 6px;
  box-shadow: 0 1px 5px rgba(0,0,0,0.1);
  margin-bottom: 20px;
}
.add-form input {
  padding: 8px;
  margin: 0 8px;
  border: 1px solid #ddd;
  border-radius: 4px;
}
.btn-sm {
  padding: 6px 12px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  margin: 0 4px;
}
.btn-add {
  background: #27ae60;
  color: #fff;
}
.btn-del {
  background: #e74c3c;
  color: #fff;
}
.btn-edit {
  background: #f39c12;
  color: #fff;
}

/* 模块切换 */
.module {
  display: none;
}
.module.show {
  display: block;
}