body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
  overflow-x: hidden; /* 防止水平滚动 */
  height: 100vh; /* 使 body 高度占满整个视窗 */
}

.header {
  position: absolute; /* 使用 absolute 定位 */
  top: 10px; /* 距离顶部一定距离 */
  left: 10px; /* 距离左侧一定距离 */
  z-index: 1000; /* 确保它在最上层 */
}

.title {
  color: white;
  font-size: 2rem;
}

.carousel-inner {
  width: 100%;
  height: calc(100vh - 100px); /* Fullscreen height minus the footer height */
  overflow: hidden; /* 隐藏溢出 */
}

.carousel-item {
  height: 100%;
}

.carousel-item img {
  width: 100%;
  height: 100%;
  object-fit: cover; /* Ensures the image is fully contained within the container */
}

.carousel-caption {
  background: rgba(0, 0, 0, 0.5); /* 半透明背景 */
  padding: 1rem;
  position: absolute;
  bottom: 60px; /* 距离底部一定距离，确保不遮挡底部 */
  left: 50%;
  transform: translateX(-50%);
  width: 80%; /* 控制宽度 */
  text-align: center;
  color: white;
}

.carousel-caption h5, .carousel-caption p {
  margin: 0;
}

.carousel-caption h5 {
  font-size: 1.5rem; /* 新闻标题的字体大小 */
  color: white; /* 设置新闻标题的颜色为白色 */
}

.carousel-caption .image-source {
  font-size: 0.8rem; /* 图片来源的字体大小 */
  color: white; /* 设置图片来源的颜色为白色 */
}

/* 设置链接颜色 */
.carousel-caption a {
  color: white; /* 确保所有链接的颜色为白色 */
  text-decoration: none; /* 去掉链接下划线 */
}

.carousel-caption a:hover {
  color: #ccc; /* 设置链接悬停时的颜色为浅灰色 */
}

.footer {
  background-color: #333;
  color: white;
  text-align: center;
  padding: 1rem 0;
  position: absolute;
  bottom: 0;
  width: 100%;
  box-sizing: border-box; /* 确保 padding 不会导致溢出 */
  height: 100px; /* 固定高度 */
}

form {
  margin-bottom: 1rem;
}

form input[type="email"] {
  padding: 0.5rem;
  font-size: 1rem;
  margin-right: 0.5rem;
}

form button {
  padding: 0.5rem 1rem;
  font-size: 1rem;
  background-color: #007BFF;
  color: white;
  border: none;
  cursor: pointer;
}

form button:hover {
  background-color: #0056b3;
}

/* Media query for smaller screens */
@media (max-width: 767px) {
  .carousel-inner {
    height: calc(100vh - 150px); /* Adjust height for smaller screens */
  }

  .carousel-caption {
    bottom: 80px; /* Adjust bottom distance for smaller screens */
    width: 90%; /* Adjust width for smaller screens */
    font-size: 0.9rem; /* Adjust font size for smaller screens */
  }

  .carousel-caption h5 {
    font-size: 1.2rem; /* Adjust title font size for smaller screens */
  }

  .carousel-caption .image-source {
    font-size: 0.7rem; /* Adjust image source font size for smaller screens */
  }
}
.dropdown-hover {
  position: relative;
  display: inline-block;
}

.dropdown-menu-custom {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background-color: transparent; /* 完全透明 ✅ */
  padding: 4px 0;
  border-radius: 0;
  z-index: 2000;
  min-width: 160px;
  box-shadow: none; /* 去掉阴影 ✅ */
}

.dropdown-hover:hover .dropdown-menu-custom {
  display: block;
}

.dropdown-button {
  display: block;
  padding: 8px 12px;
  margin-bottom: 6px;
  background-color: transparent;
  border: none;
  border-radius: 4px;
  color: white;
  font-weight: 500;
  text-decoration: none;
  transition: background-color 0.3s, color 0.3s;
}

.dropdown-button:hover {
  background-color: rgba(255, 255, 255, 0.1);
  color: #ddd;
  text-decoration: none;
}

