* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei",
    sans-serif;
  background: #0050ff;
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

/* Background glow effect */
body::before {
  content: "";
  position: absolute;
  top: -50px;
  right: -50px;
  height: 300px;
  background: radial-gradient(circle, rgba(100, 200, 255, 0.3) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

/* 3D Cube */
.cube {
  position: absolute;
  top: 80px;
  right: 20px;
  width: 80px;
  height: 80px;
  transform-style: preserve-3d;
  animation: rotate 10s infinite linear;
}

.cube-face {
  position: absolute;
  width: 80px;
  height: 80px;
  background: rgba(0, 200, 255, 0.2);
  border: 2px solid rgba(0, 255, 255, 0.6);
  backdrop-filter: blur(5px);
}

.cube-face:nth-child(1) {
  transform: rotateY(0deg) translateZ(40px);
}

.cube-face:nth-child(2) {
  transform: rotateY(90deg) translateZ(40px);
}

.cube-face:nth-child(3) {
  transform: rotateY(180deg) translateZ(40px);
}

.cube-face:nth-child(4) {
  transform: rotateY(-90deg) translateZ(40px);
}

.cube-face:nth-child(5) {
  transform: rotateX(90deg) translateZ(40px);
}

.cube-face:nth-child(6) {
  transform: rotateX(-90deg) translateZ(40px);
}

@keyframes rotate {
  from {
    transform: rotateX(0deg) rotateY(0deg);
  }

  to {
    transform: rotateX(360deg) rotateY(360deg);
  }
}

/* Language Switcher */
.language-switcher {
  position: absolute;
  top: 10px;
  /* Moved language switcher left to ensure full visibility */
  right: 20px;
  display: flex;
  align-items: center;
  gap: 5px;
  color: white;
  font-size: 14px;
  cursor: pointer;
  z-index: 100;
  padding: 5px 10px;
  border-radius: 15px;
  transition: background 0.3s;
  /* Added white background with transparency for better visibility */
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(5px);
}

.language-switcher:hover {
  background: rgba(255, 255, 255, 0.25);
}

/* Language Icon (remains unchanged) */
.language-icon {
  width: 18px;
  height: 18px;
}

/* Header */
.header {
  padding: 50px 20px 20px;
  color: white;
  /* 添加背景色和z-index确保移动端不透明 */
  background: url(../img/logo.jpg);
  background-size: cover;
  position: relative;
  z-index: 10;
}

.header h1 {
  font-size: 24px;
  font-weight: 600;
  line-height: 1.3;
  margin-bottom: 15px;
}

.header p {
  padding: 10px;
  font-size: 13px;
  line-height: 1.6;
  border-radius: 10px;
  opacity: 0.95;
  background-color: rgba(128, 128, 128, 0.5);
}

/* Main Container */
.container {
  display: flex;
  /* Use sticky positioning to avoid layout shifts */
  position: sticky;
  top: 0;
  padding: 0;
  z-index: 50;
  /* Start with pointer-events to allow page scroll */
  pointer-events: none;
}

/* Sidebar */
.sidebar {
  margin-top: 20px;
  min-width: 80px;
  width: auto;
  max-width: 120px;
  overflow-y: visible;
  flex-shrink: 0;
  position: relative;
  height: auto;
  /* Re-enable pointer events for sidebar */
  pointer-events: auto;
}

.sidebar::-webkit-scrollbar {
  width: 3px;
}

.sidebar::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.3);
  border-radius: 3px;
}

/* Updated menu structure - removed submenu styles since submenus are now hidden */
.menu-item {
  padding: 13px 10px;
  color: white;
  font-size: 12px;
  /* Adjusting for 10 English characters per line */
  flex-wrap: wrap;
  align-items: flex-start;
  display: block;
  width: 100%;
  cursor: pointer;
  transition: all 0.3s;
  border-left: 3px solid transparent;
  word-wrap: break-word;
  word-break: break-all;
  /* 保留 pre-wrap 以支持后台设置的换行符，实现跨行显示 */
  white-space: pre-wrap;
  line-height: 1.4;
  overflow-wrap: break-word;
  min-width: 80px;
}

.menu-item:hover {
  background: rgba(255, 255, 255, 0.1);
}

.menu-item.active {
  background: rgba(255, 255, 255, 0.95);
  color: #0052d4;
  font-weight: 600;
  border-radius: 15px 0 0px 15px;
  border-left-color: #0052d4;
}
/* Content Area */
.content {
  flex: 1;
  background: white;
  margin: 0 15px 15px 0;
  border-radius: 15px;
  padding: 25px 20px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  position: relative;
  height: auto;
  min-height: 100vh;
  /* Re-enable pointer events for content */
  pointer-events: auto;
  /* Removed any overflow constraints that might prevent sticky positioning */
}

/* Add classes for sticky behavior when header is hidden */
.container.sticky {
  /* Keep sticky position, just change height */
  height: 100vh;
  /* Allow interaction when sticky */
  pointer-events: auto;
}

.sidebar.sticky {
  overflow-y: auto;
  height: 100vh;
}
.content.sticky {
  overflow-y: auto;
  height: 100vh;
}

/* Content Header */
.content-header {
  position: relative;
  margin-bottom: 20px;
}

.content-header::before {
  content: attr(data-title);
  position: absolute;
  top: -10px;
  left: 0;
  font-size: 48px;
  font-weight: 900;
  color: rgba(0, 0, 0, 0.03);
  white-space: nowrap;
  z-index: 0;
}

.content-header h2 {
  position: relative;
  font-size: 22px;
  color: #333;
  font-weight: 600;
  z-index: 1;
}
/* Tabs (now removed from the content itself, handled by sidebar clicks) */
.tabs {
  display: flex;
  gap: 20px;
  margin-bottom: 25px;
  border-bottom: 1px solid #e5e7eb;
  padding-bottom: 10px;
  flex-wrap: wrap;
}

.tab {
  color: #0052d4;
  font-size: 14px;
  cursor: pointer;
  padding: 5px 0;
  position: relative;
  transition: all 0.3s;
  white-space: nowrap;
}

.tab::before {
  content: "# ";
  font-weight: 600;
}

.tab:hover {
  color: #003da5;
}

.tab.active {
  font-weight: 600;
}

.tab.active::after {
  content: "";
  position: absolute;
  bottom: -11px;
  left: 0;
  right: 0;
  height: 2px;
  background: #0052d4;
}

/* Tab Content (now content-section) */
.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
}

/* Section is now part of the content-section */
.section {
  margin-bottom: 30px;
}

.section h3 {
  font-size: 16px;
  color: #333;
  margin-bottom: 15px;
  font-weight: 600;
}

.section h3::before {
  content: "● ";
  color: #0052d4;
  margin-right: 5px;
}

.section p {
  font-size: 12px;
  line-height: 1.8;
  color: #555;
  margin-bottom: 15px;
}

.qr-code {
  width: 200px;
  height: 200px;
  margin: 20px auto;
  display: block;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 10px;
  background: white;
}

/* Section Content (hidden by default) - Renamed to content-section */
.section-content {
  display: none;
}

/* Updated content section to show all sections in one scrollable area */
.content-section {
  display: block;
  margin-bottom: 40px;
  /* Increased scroll-margin-top to 120px to account for sticky hashtag tabs */
  scroll-margin-top: 150px;
  padding-top: 20px;
}

/* Added styles for hashtag tabs at top of content */
.hashtag-tabs {
  display: flex;
  gap: 15px;
  margin-bottom: 20px;
  padding-bottom: 15px;
  /*border-bottom: 1px solid #e5e7eb;*/
  flex-wrap: wrap;
  /* Adjusted top position to stack directly below package-list-title (approximately 68px) */
  position: sticky;
  top: 33px;
  background: white;
  z-index: 100;
  padding-top: 10px;
  margin-top: -10px;
  max-height: 75px;
  overflow: hidden;
  transition: max-height 0.3s ease;
  /* Add shadow for visual separation */
  /*box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);*/
  /* Added padding to ensure content doesn't touch edges */
  padding-left: 5px;
  padding-right: 35px;
}

/* Expanded state for hashtag-tabs */
.hashtag-tabs.expanded {
  max-height: 500px;
}

/* Container for hashtag tags */
.hashtag-tabs-content {
  display: flex;
  gap: 15px;
  flex-wrap: wrap;
  flex: 1;
}

/* Toggle button for expand/collapse */
.hashtag-toggle-btn {
  position: absolute;
  /* right: 1px; */
  right: -3px;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  /* background: white; */
  /* border: 1px solid #e5e7eb; */
  /* border-radius: 50%; */
  transition: all 0.3s ease;
  z-index: 101;
}

.hashtag-toggle-btn:hover {
  background: #f3f4f6;
  border-color: #0052d4;
}

.hashtag-toggle-btn svg {
  width: 14px;
  height: 14px;
  transition: transform 0.3s ease;
  pointer-events: none;
}

.hashtag-tabs.expanded .hashtag-toggle-btn svg {
  transform: rotate(180deg);
}

.hashtag-tab {
  display: inline-block;
    vertical-align: top;
    background-color: rgba(0, 117, 255, 0.1);
    border-radius: 4px;
    font-size: 12px;
    line-height: 20px;
    color: #2563EB;
    margin-bottom: 4px;
}

.hashtag-tab::before {
  content: "# ";
  font-weight: 600;
}

.hashtag-tab:hover {
  color: #003da5;
  background: #d0e7ff;
  /* Added border on hover */
  border-color: #0052d4;
}

.hashtag-tab.active {
}

.collapse-btn {
  margin-left: auto;
  cursor: pointer;
  color: #0052d4;
  padding: 5px;
  transition: transform 0.3s;
}

.collapse-btn:hover {
  transform: scale(1.1);
}
.content-html img,
.section img:not(.qr-code) {
  max-width: 70%;
  width: 70%;
  height: auto;
  display: block;
  margin: 20px auto;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  /* Add cursor pointer to indicate clickable */
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

/* Add hover effect for images */
.content-html img:hover,
.section img:not(.qr-code):hover {
  transform: scale(1.02);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Lightbox modal for image zoom */
.lightbox {
  display: none;
  position: fixed;
  z-index: 9999;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
  align-items: center;
  justify-content: center;
}

.lightbox.active {
  display: flex;
}

.lightbox-content {
  position: relative;
  max-width: 90%;
  max-height: 90%;
  animation: zoomIn 0.3s ease;
}

.lightbox-content img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 8px;
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 30px;
  font-size: 40px;
  color: white;
  cursor: pointer;
  z-index: 10000;
  background: rgba(0, 0, 0, 0.5);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s ease;
}

.lightbox-close:hover {
  background: rgba(0, 0, 0, 0.8);
}

@keyframes zoomIn {
  from {
    transform: scale(0.5);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

.package-list-title {
  /* Ensure sticky positioning with solid white background and gradient text */
  position: sticky;
  top: -7px;
  z-index: 101;
  /* 修复标题样式，移除可能导致变形的属性 */
  padding: 15px 5px;
  margin-top: -10px;
  margin-bottom: 10px;
  font-size: 28px;
  line-height: 1.3;
  word-wrap: break-word;
  word-break: normal;
  white-space: normal;
  max-width: 100%;
  font-weight: 600;
  background: white;
  /* 使用渐变文字效果但确保背景完全不透明 */
  background-image: linear-gradient(to bottom, #6b7280, #374151);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* 添加伪元素确保白色背景在渐变文字后面 */
.package-list-title::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: white;
  z-index: -1;
}

/* Add styles for nested white background div */
.title-background {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: #ffffff;
  z-index: 0;
}

/* Add styles for nested gradient text div */
.title-text {
  position: relative;
  z-index: 1;
  background-image: linear-gradient(to bottom, #8a9198, #fff);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Remove ::before pseudo-element */

/* Add responsive font size for package-list-title */
@media (max-width: 768px) {
  .package-list-title {
    font-size: 20px;
    line-height: 1.4;
    padding: 12px 5px;
  }

  /* Adjust sidebar width to 90px minimum on mobile */
  .sidebar {
    min-width: 90px;
    max-width: 120px;
  }

  /* Adjust menu-item min-width for mobile */
  .menu-item {
    min-width: 90px;
  }
}

@media (max-width: 480px) {
  .package-list-title {
    font-size: 18px;
    
    line-height: 1.3;
    padding: 10px 5px;
  }

  /* Adjust sidebar width to 90px minimum on mobile */
  .sidebar {
    min-width: 90px;
    max-width: 120px;
  }

  /* Adjust menu-item min-width for mobile */
  .menu-item {
    min-width: 90px;
  }
}
