/* 页面整体样式 */
html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  font-family: Arial, sans-serif;
  background: url("/img/bg.jpg") no-repeat center center fixed;
  background-size: cover;
  color: #fff;
  display: flex;
  flex-direction: column;
}

/* 头部 */
header {
  text-align: center;
  background: rgba(0,0,0,0.6);
  padding: 20px;
  font-size: 24px;
  font-weight: bold;
  flex-shrink: 0;
}

/* 主体（中间区域） */
main {
  flex: 1;  /* 占满中间剩余空间 */
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 20px;
}

/* 列表容器 */
ul {
  list-style: none;
  padding: 0;
  margin: 0;
  width: 90%;
  max-width: 900px;

  display: grid;
  grid-template-columns: 1fr 1fr; /* 默认两列 */
  gap: 15px;

  /* 滚动区域 */
  max-height: 400px;
  overflow-y: auto;
  background: rgba(0,0,0,0.4);
  border-radius: 10px;
  padding: 15px;
}

/* 每个 li 样式 */
li {
  display: flex;
  align-items: center;
  background: rgba(0,0,0,0.5);
  padding: 10px;
  border-radius: 8px;
  transition: background 0.3s ease, transform 0.2s ease;
}

li:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-3px);
}

li img {
  width: 60px;
  height: 60px;
  border-radius: 6px;
  margin-right: 15px;
  flex-shrink: 0;
}

li span {
  font-size: 18px;
  font-weight: 500;
}

/* 整个 li 可点击 */
li a {
  display: flex;
  align-items: center;
  text-decoration: none;
  color: #fff;
  width: 100%;
}

/* 美化滚动条 */
ul::-webkit-scrollbar {
  width: 8px;
}
ul::-webkit-scrollbar-thumb {
  background: #888;
  border-radius: 4px;
}
ul::-webkit-scrollbar-thumb:hover {
  background: #555;
}

/* 尾部固定在底部 */
footer {
  text-align: center;
  background: rgba(0,0,0,0.6);
  padding: 15px;
  font-size: 14px;
  flex-shrink: 0;
}

/* 🔹 移动端适配 */
@media (max-width: 768px) {
  body {
    background: url("/img/bgyd.jpg") no-repeat center center fixed;
    background-size: cover;
  }

  ul {
    grid-template-columns: repeat(2, 1fr); /* 移动端保持两列 */
    max-height: 60vh; /* 高度改为相对屏幕更适配 */
  }

  li img {
    width: 50px;
    height: 50px;
    margin-right: 10px;
  }

  li span {
    font-size: 16px;
  }
}
