:root {
  --header-offset: 122px; /* Desktop: 68px (header-top) + 52px (main-nav) + 2px buffer */
  --primary-color: #2F6BFF;
  --secondary-color: #6FA3FF;
  --text-main-color: #1F2D3D;
  --button-gradient: linear-gradient(180deg, #4A8BFF 0%, #2F6BFF 100%);
  --card-bg-color: #FFFFFF;
  --page-bg-color: #F4F7FB;
  --border-color: #D6E2FF;
  --glow-color: #A5C4FF;
}

body {
  margin: 0;
  font-family: Arial, sans-serif;
  padding-top: var(--header-offset); /* Ensure content is not hidden by fixed header */
  overflow-x: hidden; /* Prevent horizontal scroll on body */
}

body.no-scroll {
  overflow: hidden;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1); /* Suspended effect */
  background-color: var(--card-bg-color); /* Neutral background for the whole header */
}

.header-top {
  box-sizing: border-box;
  min-height: 68px;
  height: 68px; /* Fixed height desktop */
  display: flex;
  align-items: center;
  background-color: var(--primary-color); /* Different from main-nav */
  width: 100%;
}

.header-container {
  box-sizing: border-box;
  width: 100%;
  height: 100%;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 20px; /* Inner padding for logo and buttons */
}

.logo {
  font-size: 28px;
  font-weight: bold;
  color: #FFFFFF; /* White text for logo on primary background */
  text-decoration: none;
  display: block; /* Ensure it's treated as a block for alignment */
  flex-shrink: 0; /* Prevent logo from shrinking */
}

.logo img {
  display: block;
  max-height: 60px; /* Max height for logo on desktop */
  height: auto;
  width: auto;
  max-width: 280px; /* Prevent excessively wide logos */
  object-fit: contain;
}

.hamburger-menu {
  display: none; /* Hidden on desktop */
  background: none;
  border: none;
  cursor: pointer;
  padding: 10px;
  z-index: 1002; /* Above other elements in header */
  position: relative;
  width: 30px;
  height: 24px;
  flex-shrink: 0;
}

.hamburger-menu span {
  display: block;
  width: 100%;
  height: 3px;
  background-color: #FFFFFF; /* White lines for hamburger */
  margin-bottom: 5px;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.hamburger-menu span:last-child {
  margin-bottom: 0;
}

.desktop-nav-buttons {
  display: flex; /* Visible on desktop */
  gap: 12px; /* Spacing between buttons */
  align-items: center;
  flex-shrink: 0;
}

.mobile-nav-buttons {
  box-sizing: border-box;
  display: none; /* Hidden on desktop, shown on mobile */
  min-height: 48px; /* Fixed height for mobile buttons */
}

.btn {
  display: inline-block;
  padding: 10px 20px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  color: #FFFFFF; /* White text on button */
  background: var(--button-gradient); /* Gradient button background */
  transition: background-color 0.3s ease, transform 0.2s ease;
  white-space: nowrap; /* Prevent button text from wrapping on desktop */
  box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.main-nav {
  box-sizing: border-box;
  min-height: 52px;
  height: 52px; /* Fixed height desktop */
  display: flex; /* Visible on desktop */
  align-items: center;
  background-color: var(--secondary-color); /* Different from header-top */
  width: 100%;
  position: static; /* Desktop: normal flow */
}

.nav-container {
  box-sizing: border-box;
  height: 100%;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
  display: flex;
  flex-direction: row; /* Horizontal on desktop */
  justify-content: center; /* Center nav items */
  align-items: center;
  padding: 0 20px;
  overflow-x: auto; /* Allow scrolling if too many items, but preferably avoid */
}

.nav-link {
  color: #FFFFFF; /* White text for nav links */
  text-decoration: none;
  padding: 10px 15px;
  font-weight: bold;
  white-space: nowrap; /* Prevent nav links from wrapping */
  transition: background-color 0.3s ease, color 0.3s ease;
}

.nav-link:hover {
  background-color: rgba(255, 255, 255, 0.2);
  border-radius: 3px;
}

/* Footer styles */
.site-footer {
  background-color: var(--text-main-color); /* Dark background for footer */
  color: #FFFFFF;
  padding: 40px 20px 20px;
  font-size: 14px;
}

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

.footer-col h3 {
  color: var(--secondary-color); /* Secondary color for footer headings */
  font-size: 16px;
  margin-bottom: 15px;
}

.footer-logo {
  font-size: 24px;
  font-weight: bold;
  color: #FFFFFF;
  text-decoration: none;
  display: block;
  margin-bottom: 15px;
}

.footer-description {
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.8);
  word-wrap: break-word;
  overflow-wrap: break-word;
}

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

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

.footer-nav a {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  transition: color 0.3s ease;
}

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

.footer-slot-anchor-inner {
  /* Placeholder for injected content */
  min-height: 10px; /* Ensure visibility for debugging */
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 20px;
  margin-top: 20px;
  text-align: center;
  color: rgba(255, 255, 255, 0.6);
}

/* Overlay for mobile menu */
.overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 999;
  display: none; /* Hidden by default */
}

.overlay.active {
  display: block;
}

/* Mobile styles */
@media (max-width: 768px) {
  :root {
    --header-offset: 110px; /* Mobile: 60px (header-top) + 48px (mobile-nav-buttons) + 48px (main-nav) = 156px. Re-evaluating based on prompt: 60px (header-top) + 48px (main-nav) = 108px. So 110px is correct. */
  }

  /* Mobile overflow protection */
  .page-content img {
    max-width: 100% !important;
    height: auto !important;
    display: block;
  }
  .page-content {
    overflow-x: hidden;
    max-width: 100%;
  }

  .header-top {
    min-height: 60px !important;
    height: 60px !important;
  }

  .header-container {
    width: 100%;
    max-width: none; /* No max-width on mobile */
    padding: 0 15px; /* Smaller padding for mobile */
    justify-content: space-between; /* Hamburger left, Logo center, space right */
    position: relative; /* For absolute logo positioning if needed */
  }

  .hamburger-menu {
    display: block; /* Visible on mobile */
    order: 0; /* Leftmost */
  }

  .logo {
    flex: 1 !important; /* Take available space */
    display: flex !important;
    justify-content: center !important; /* Center logo */
    align-items: center !important;
    order: 1; /* Center position */
    font-size: 24px; /* Slightly smaller logo text */
  }
  .logo img {
    max-height: 56px !important; /* Max height for logo on mobile */
  }

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

  .mobile-nav-buttons {
    display: flex !important; /* Show mobile buttons */
    min-height: 48px;
    align-items: center;
    width: 100%; max-width: 100%;
    box-sizing: border-box;
    padding: 0 15px;
    overflow: hidden;
    gap: 10px;
    flex-wrap: nowrap;
    justify-content: center;
    background-color: var(--secondary-color); /* Background for mobile buttons bar */
    box-shadow: inset 0 -1px 3px rgba(0,0,0,0.1); /* Subtle separator */
  }

  .mobile-nav-buttons .btn {
    flex: 1; min-width: 0;
    max-width: calc(50% - 5px); /* For two buttons with 10px gap */
    box-sizing: border-box;
    padding: 8px 12px;
    font-size: 13px;
    white-space: normal;
    word-wrap: break-word;
    overflow-wrap: break-word;
    text-align: center;
  }

  .main-nav {
    display: none; /* Hidden by default on mobile */
    position: fixed; /* Fixed position for mobile menu */
    top: var(--header-offset); /* Below fixed header */
    left: 0;
    width: 100%;
    height: calc(100vh - var(--header-offset)); /* Full height minus header */
    overflow-y: auto; /* Scrollable if content is long */
    flex-direction: column; /* Vertical layout for menu items */
    background-color: var(--text-main-color); /* Dark background for mobile menu */
    transform: translateX(-100%); /* Slide out to the left */
    transition: transform 0.3s ease;
    z-index: 1001; /* Above overlay and header-top */
  }

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

  .nav-container {
    width: 100%;
    max-width: none; /* No max-width on mobile */
    padding: 20px 15px; /* Padding inside the mobile menu */
    flex-direction: column; /* Vertical links */
    align-items: flex-start; /* Align links to the left */
  }

  .nav-link {
    width: 100%; /* Full width for mobile nav links */
    padding: 12px 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    color: #FFFFFF; /* White text on dark background */
  }

  .nav-link:last-child {
    border-bottom: none;
  }

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

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

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

  .site-footer {
    padding: 30px 15px 15px;
  }

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

  .footer-col {
    margin-bottom: 20px;
  }
  .footer-col:last-of-type {
    margin-bottom: 0;
  }
}
/* 移动端内容区防溢出（系统追加，请勿删除） */
@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;
  }
}
/* 内容保护（系统追加，请勿删除） */
body {
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}
input, textarea, select, [contenteditable="true"] {
  -webkit-user-select: text;
  -moz-user-select: text;
  user-select: text;
}
