:root {
  --primary-color: #26A9E0; /* Light blue */
  --secondary-color: #FFFFFF; /* White */
  --login-color: #EA7C07; /* Orange */
  --black-color: #000000;

  /* Neon palette based on primary color */
  --neon-base-dark: #0a0a0a; /* Dark background for neon */
  --neon-primary: #26A9E0;   /* Blue neon */
  --neon-secondary: #00FFFF; /* Cyan neon */
  --neon-accent: #FF00FF;    /* Magenta neon */
  --neon-highlight: #FFFF00; /* Yellow neon */

  /* Header offset with marquee */
  --header-offset: 166px; 
}

body {
  margin: 0;
  font-family: 'Arial', sans-serif;
  color: #333333; /* Default text color for body content */
  background-color: var(--background-color, #FFFFFF);
  padding-top: var(--header-offset); /* Ensure content is not hidden by fixed header */
  overflow-x: hidden; /* Prevent horizontal scroll on desktop too */
}

/* Animations for dynamic neon effects */
@keyframes theme-colors {
  0%, 100% {
    border-color: var(--neon-primary);
    box-shadow: 
      0 0 10px var(--neon-primary),
      0 0 20px var(--neon-primary);
  }
  33% {
    border-color: var(--neon-secondary);
    box-shadow: 
      0 0 10px var(--neon-secondary),
      0 0 20px var(--neon-secondary);
  }
  66% {
    border-color: var(--neon-accent);
    box-shadow: 
      0 0 10px var(--neon-accent),
      0 0 20px var(--neon-accent);
  }
}

@keyframes text-glow-flow {
  0% {
    text-shadow: 
      0 0 5px var(--neon-primary),
      0 0 10px var(--neon-primary),
      0 0 15px var(--neon-primary);
    color: #ffffff;
  }
  50% {
    text-shadow: 
      0 0 5px var(--neon-secondary),
      0 0 10px var(--neon-secondary),
      0 0 15px var(--neon-secondary);
    color: #ffffff;
  }
  100% {
    text-shadow: 
      0 0 5px var(--neon-accent),
      0 0 10px var(--neon-accent),
      0 0 15px var(--neon-accent);
    color: #ffffff;
  }
}

@keyframes marquee-pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.15); opacity: 0.9; }
}

@keyframes marquee-scroll {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* Marquee Section Styles */
.marquee-section {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 44px; /* Desktop height */
  box-sizing: border-box;
  background: linear-gradient(135deg, #0a0a0a, #1a1a2e, #16213e);
  color: #ffffff;
  overflow: hidden;
  border-bottom: 2px solid;
  animation: theme-colors 4s ease-in-out infinite;
  box-shadow: 
    0 0 10px var(--neon-primary),
    0 0 20px var(--neon-primary),
    0 0 30px var(--neon-primary),
    inset 0 0 20px rgba(38, 169, 224, 0.1); /* Using primary color for inner glow */
  z-index: 1001;
  display: flex; /* Ensure flex context for content */
  align-items: center;
}

.marquee-container {
  width: 100%;
  max-width: 100%;
  height: 100%;
  margin: 0 auto;
  overflow: hidden;
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 0 20px;
  box-sizing: border-box;
}

.marquee-icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  z-index: 2;
  position: relative;
}

.marquee-icon-emoji {
  font-size: 24px;
  display: inline-block;
  animation: marquee-pulse 2s ease-in-out infinite, text-glow-flow 3s ease-in-out infinite alternate;
  text-shadow: 
    0 0 5px var(--neon-primary),
    0 0 10px var(--neon-primary),
    0 0 15px var(--neon-primary);
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.marquee-wrapper {
  flex: 1;
  overflow: hidden;
  position: relative;
}

.marquee-content {
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  animation: marquee-scroll 30s linear infinite;
  gap: 30px;
}

.marquee-text {
  font-size: 16px;
  font-weight: 600;
  color: #ffffff;
  text-decoration: none;
  text-shadow: 
    0 0 5px var(--neon-primary),
    0 0 10px var(--neon-primary),
    0 0 15px var(--neon-primary);
  line-height: 1.5;
  display: inline-block;
  vertical-align: middle;
  animation: text-glow-flow 3s ease-in-out infinite alternate;
  cursor: pointer;
  transition: all 0.3s ease;
}

.marquee-text:hover {
  text-shadow: 
    0 0 10px var(--neon-primary),
    0 0 20px var(--neon-primary),
    0 0 30px var(--neon-primary),
    0 0 40px var(--neon-primary);
  transform: scale(1.05);
  color: #ffffff;
}

.marquee-separator {
  font-size: 16px;
  color: rgba(255, 255, 255, 0.6);
  margin: 0 15px;
  text-shadow: 
    0 0 3px var(--neon-primary),
    0 0 6px var(--neon-primary);
}

/* Header Section Styles */
.site-header {
  position: fixed;
  top: 44px; /* Below marquee */
  left: 0;
  width: 100%;
  z-index: 1000;
  background: var(--neon-base-dark); /* Default dark background */
}

.header-top {
  box-sizing: border-box;
  min-height: 68px; /* Desktop height */
  height: 68px;
  display: flex;
  align-items: center;
  overflow: hidden;
  background: linear-gradient(135deg, #0a0a0a, #1a1a2e, #16213e);
  border-bottom: 2px solid;
  animation: theme-colors 4s ease-in-out infinite;
  box-shadow: 
    0 0 10px var(--neon-highlight), /* Use yellow for top header glow */
    0 0 20px var(--neon-highlight),
    inset 0 0 20px rgba(255, 255, 0, 0.1);
}

.header-container {
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 20px;
  box-sizing: border-box;
}

.hamburger-menu {
  display: none; /* Hidden on desktop */
  background: none;
  border: none;
  cursor: pointer;
  padding: 10px;
  z-index: 1002; /* Above logo on mobile */
  position: relative;
}

.hamburger-icon {
  display: block;
  width: 25px;
  height: 3px;
  background-color: #ffffff;
  margin: 5px 0;
  transition: all 0.3s ease;
  box-shadow: 
    0 0 5px var(--neon-primary),
    0 0 10px var(--neon-primary);
}

.hamburger-menu.active .hamburger-icon:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}

.hamburger-menu.active .hamburger-icon:nth-child(2) {
  opacity: 0;
}

.hamburger-menu.active .hamburger-icon:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}

.logo {
  color: var(--secondary-color); /* White for logo text */
  text-decoration: none;
  font-size: 24px;
  font-weight: bold;
  letter-spacing: 1px;
  text-transform: uppercase; /* Ensure uppercase for English part */
  display: block; /* Default for desktop */
}

.desktop-nav-buttons {
  display: flex; /* Show on desktop */
  gap: 12px;
  align-items: center;
}

.mobile-nav-buttons {
  display: none; /* Hidden on desktop */
}

.btn {
  position: relative;
  background: linear-gradient(135deg, var(--neon-primary), var(--neon-secondary));
  padding: 12px 30px;
  color: #ffffff;
  text-decoration: none;
  border-radius: 5px;
  border: 2px solid;
  animation: theme-colors 4s ease-in-out infinite;
  text-shadow: 
    0 0 5px #ffffff,
    0 0 10px var(--neon-primary);
  transition: all 0.3s ease;
  font-weight: 600;
  white-space: nowrap; /* Prevent button text from wrapping on desktop */
}

.btn:hover {
  animation-duration: 2s;
  transform: translateY(-2px);
  box-shadow: 
    0 0 15px var(--neon-primary),
    0 0 30px var(--neon-primary),
    inset 0 0 15px rgba(38, 169, 224, 0.5);
}

.main-nav {
  box-sizing: border-box;
  min-height: 52px; /* Desktop height */
  height: 52px;
  display: flex; /* Show on desktop */
  align-items: center;
  overflow: hidden;
  background: linear-gradient(135deg, #1a1a2e, #16213e, #0f3460); /* Slightly different dark gradient */
  border-top: 2px solid;
  border-bottom: 2px solid;
  animation: theme-colors 4s ease-in-out infinite reverse; /* Different animation for contrast */
  box-shadow: 
    0 0 10px var(--neon-accent), /* Use magenta for main nav glow */
    0 0 20px var(--neon-accent),
    inset 0 0 20px rgba(255, 0, 255, 0.1);
}

.nav-container {
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100%;
  padding: 0 20px;
  box-sizing: border-box;
}

.nav-link {
  color: #ffffff;
  text-decoration: none;
  font-size: 16px;
  font-weight: 500;
  padding: 10px 15px;
  transition: color 0.3s ease, text-shadow 0.3s ease;
  position: relative;
  overflow: hidden;
}

.nav-link::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: var(--neon-primary);
  transition: width 0.3s ease, left 0.3s ease;
  box-shadow: 0 0 5px var(--neon-primary), 0 0 10px var(--neon-primary);
}

.nav-link:hover::before {
  width: 100%;
  left: 0;
}

.nav-link:hover {
  color: var(--neon-primary);
  text-shadow: 0 0 5px var(--neon-primary);
}

/* Mobile Menu Overlay */
.mobile-menu-overlay {
  display: none; /* Hidden by default */
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  z-index: 999;
  transition: opacity 0.3s ease;
  opacity: 0;
}

.mobile-menu-overlay.active {
  display: block;
  opacity: 1;
}

/* Footer Section Styles */
.site-footer {
  background-color: #1a1a2e; /* Dark background, not neon */
  color: #cccccc;
  padding: 40px 20px 20px;
  font-size: 14px;
  line-height: 1.6;
}

.footer-top-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
  max-width: 1200px;
  margin: 0 auto 40px auto;
  padding-bottom: 30px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-col {
  padding: 0 10px;
}

.footer-logo {
  display: block;
  color: var(--secondary-color);
  text-decoration: none;
  font-size: 22px;
  font-weight: bold;
  margin-bottom: 15px;
  text-transform: uppercase;
}

.footer-description {
  word-wrap: break-word;
  overflow-wrap: break-word;
  line-height: 1.6;
  color: #aaaaaa;
}

.footer-heading {
  color: #ffffff;
  font-size: 16px;
  margin-bottom: 15px;
  font-weight: 600;
}

.footer-nav {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-nav li {
  margin-bottom: 8px;
}

.footer-nav a {
  color: #aaaaaa;
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-nav a:hover {
  color: var(--primary-color);
}

.footer-dynamic-col .footer-slot-anchor-inner,
.footer-dynamic-row .footer-slot-anchor-inner {
  display: flex;
  flex-wrap: wrap;
  flex-direction: row;
  align-items: flex-start;
  gap: 5px; /* For col_4 */
  width: 100%; /* For mid_1, mid_2 */
}

.footer-dynamic-row {
  max-width: 1200px;
  margin: 20px auto;
  padding: 15px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-dynamic-row-1 .footer-slot-anchor-inner {
  gap: 8px; /* For mid_1 */
}
.footer-dynamic-row-2 .footer-slot-anchor-inner {
  gap: 8px; /* For mid_2 */
}

.footer-dynamic-col .footer-slot-anchor-inner img,
.footer-dynamic-row .footer-slot-anchor-inner img {
  max-height: 50px;
  height: auto;
  width: auto;
  object-fit: contain;
}

.footer-bottom {
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
  padding-top: 20px;
  color: #888888;
}

/* Responsive Styles */
@media (max-width: 768px) {
  :root {
    --header-offset: 146px; /* Mobile header offset with marquee */
  }

  .marquee-section {
    height: 36px; /* Mobile height */
  }

  .marquee-container {
    gap: 10px;
    padding: 0 12px;
  }

  .marquee-icon {
    width: 20px;
    height: 20px;
  }

  .marquee-icon-emoji {
    font-size: 14px;
  }

  .marquee-text {
    font-size: 14px;
  }

  .marquee-separator {
    font-size: 14px;
    margin: 0 10px;
  }

  .marquee-content {
    animation: marquee-scroll 25s linear infinite;
  }

  .site-header {
    top: 36px; /* Below mobile marquee */
  }

  .header-top {
    min-height: 60px; /* Mobile height */
    height: 60px;
  }

  .header-container {
    padding: 0 15px;
    max-width: none; /* Full width on mobile */
    justify-content: space-between; /* Hamburger left, logo center, right empty */
  }

  .hamburger-menu {
    display: block; /* Show hamburger on mobile */
    order: 1; /* Left side */
  }

  .logo {
    order: 2; /* Center */
    flex: 1 !important; /* Take remaining space, important to override default */
    text-align: center; /* Center text logo */
    font-size: 20px;
    display: flex !important; /* For centering logo image */
    justify-content: center !important;
    align-items: center !important;
  }
  
  /* Image Logo Centering - Method 1 (preferred) */
  .logo img {
    max-height: 40px; /* Adjust for mobile */
    display: block !important;
    max-width: 100%;
    height: auto;
  }

  .desktop-nav-buttons {
    display: none; /* Hide desktop buttons on mobile */
  }

  .mobile-nav-buttons {
    display: flex !important; /* Show mobile buttons */
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    padding: 10px 15px; /* Added padding for mobile buttons */
    gap: 10px;
    justify-content: center;
    flex-wrap: nowrap; /* Ensure buttons stay in one line */
    background: linear-gradient(135deg, #0a0a0a, #1a1a2e, #16213e); /* Dark background */
    border-bottom: 2px solid;
    animation: theme-colors 4s ease-in-out infinite;
    box-shadow: 
      0 0 5px var(--neon-highlight),
      0 0 10px var(--neon-highlight),
      inset 0 0 10px rgba(255, 255, 0, 0.1);
    min-height: 48px; /* Mobile nav buttons min height */
  }

  .mobile-nav-buttons .btn {
    flex: 1;
    min-width: 0;
    max-width: calc(50% - 5px); /* Max width for each button, considering gap */
    padding: 8px 12px; /* Smaller padding for mobile buttons */
    font-size: 13px; /* Smaller font size for mobile buttons */
    text-align: center;
    white-space: normal; /* Allow text to wrap */
    word-wrap: break-word;
    overflow-wrap: break-word;
  }

  .main-nav {
    display: none; /* Hidden by default on mobile, shown by JS */
    position: fixed;
    top: var(--header-offset); /* Below the header-top and mobile-nav-buttons */
    left: 0;
    width: 80%; /* Menu width */
    max-width: 300px; /* Max width for mobile menu */
    height: calc(100% - var(--header-offset)); /* Full height below header */
    flex-direction: column;
    align-items: flex-start;
    background: linear-gradient(135deg, #0a0a0a, #1a1a2e, #16213e); /* Dark background */
    border-right: 2px solid;
    animation: theme-colors 4s ease-in-out infinite;
    box-shadow: 
      0 0 15px var(--neon-accent),
      0 0 30px var(--neon-accent);
    transform: translateX(-100%); /* Off-screen by default */
    transition: transform 0.3s ease-out;
    z-index: 1000; /* Above overlay, below hamburger */
    overflow-y: auto; /* Enable scrolling for long menus */
    padding: 20px 0; /* Add padding for menu items */
  }

  .main-nav.active {
    display: flex; /* Show menu when active */
    transform: translateX(0); /* Slide into view */
  }

  .nav-container {
    flex-direction: column;
    align-items: flex-start;
    padding: 0;
    width: 100%;
    max-width: none;
  }

  .nav-link {
    width: 100%;
    padding: 12px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  }
  
  .nav-link::before {
    height: 1px; /* Thinner line for mobile */
  }

  .footer-top-grid {
    grid-template-columns: 1fr; /* Single column on mobile */
    gap: 20px;
  }

  .footer-col {
    padding: 0;
  }

  .footer-dynamic-row {
    padding: 15px 10px; /* Adjust padding for full width on mobile */
  }

  .footer-dynamic-col .footer-slot-anchor-inner,
  .footer-dynamic-row .footer-slot-anchor-inner {
    gap: 5px; /* Adjust gap for mobile */
  }

  .footer-dynamic-col .footer-slot-anchor-inner img,
  .footer-dynamic-row .footer-slot-anchor-inner img {
    max-height: 40px; /* Smaller images for mobile */
  }

  .footer-bottom {
    padding: 15px 10px;
  }

  .no-scroll {
    overflow: hidden;
  }

  /* Mobile content overflow prevention */
  .page-content img {
    max-width: 100% !important;
    height: auto !important;
    display: block;
  }
  .page-content {
    overflow-x: hidden;
    max-width: 100%;
  }
  body {
    overflow-x: hidden;
  }
}
/* 移动端内容区防溢出（系统追加，请勿删除） */
@media (max-width: 768px) {
  .page-content img {
    max-width: 100% !important;
    height: auto !important;
    display: block;
  }
  .page-content {
    overflow-x: hidden;
    max-width: 100%;
  }
  body {
    overflow-x: hidden;
  }
}
