:root {
  --primary-color: #113B7A;
  --secondary-color: #1D5FD1;
  --button-gradient: linear-gradient(180deg, #2B73F6 0%, #1144A6 100%);
  --card-bg: #10233F;
  --text-main: #F3F8FF;
  --text-secondary: #AFC4E8;
  --border-color: #244D84;
  --glow-color: #4FA8FF;
  --gold-color: #F2C14E;
  --divider-color: #1B3357;
  --deep-navy: #08162B;

  /* Header offset calculation - No marquee */
  --header-offset: 122px; /* Desktop: 68px (header-top) + 52px (main-nav) */
}

body {
  padding-top: var(--header-offset);
  margin: 0;
  font-family: Arial, sans-serif;
  color: var(--text-main);
  background-color: var(--card-bg); /* Default background for body */
  overflow-x: hidden; /* Prevent horizontal scroll on desktop too */
}

/* Site Header */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
  background-color: transparent; /* Base for fixed header, actual colors for sub-sections */
  box-sizing: border-box;
}

.header-top {
  background-color: var(--deep-navy); /* Darker blue */
  min-height: 68px;
  height: 68px;
  display: flex;
  align-items: center;
  overflow: hidden;
  width: 100%;
  box-sizing: border-box;
}

.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; /* Padding for logo and buttons */
}

.logo {
  font-size: 28px;
  font-weight: bold;
  color: var(--gold-color);
  text-decoration: none;
  white-space: nowrap;
  padding: 0;
  display: flex;
  align-items: center;
}

.logo img {
  display: block;
  max-height: 60px;
  height: auto;
  width: auto;
  max-width: 280px;
  object-fit: contain;
}

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

.btn {
  padding: 10px 20px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  color: var(--text-main);
  background: var(--button-gradient);
  border: none;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.2s ease;
  white-space: nowrap;
  box-sizing: border-box;
}

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

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

.hamburger-menu .bar {
  display: block;
  width: 100%;
  height: 3px;
  background-color: var(--text-main);
  border-radius: 2px;
  position: absolute;
  left: 0;
  transition: all 0.3s ease;
}

.hamburger-menu .bar:nth-child(1) { top: 0; }
.hamburger-menu .bar:nth-child(2) { top: 10px; }
.hamburger-menu .bar:nth-child(3) { top: 20px; }

.hamburger-menu.active .bar:nth-child(1) { transform: translateY(10px) rotate(45deg); }
.hamburger-menu.active .bar:nth-child(2) { opacity: 0; }
.hamburger-menu.active .bar:nth-child(3) { transform: translateY(-10px) rotate(-45deg); }

.mobile-nav-buttons {
  box-sizing: border-box;
  display: none; /* Hidden on desktop, controlled by media query */
  min-height: 48px;
  background-color: var(--primary-color); /* Matches main-nav for mobile */
  width: 100%;
  padding: 8px 15px; /* Adjust padding for mobile buttons */
  justify-content: center;
  align-items: center;
  gap: 10px;
  flex-wrap: nowrap;
  overflow: hidden;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

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

.main-nav {
  background-color: var(--primary-color); /* Lighter blue than header-top */
  min-height: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  overflow: hidden;
  width: 100%;
  box-sizing: border-box;
}

.nav-container {
  box-sizing: border-box;
  height: 100%;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  padding: 0 20px;
  gap: 25px; /* Spacing between nav links */
}

.nav-link {
  color: var(--text-main);
  text-decoration: none;
  font-weight: 600;
  padding: 5px 0;
  position: relative;
  transition: color 0.3s ease;
  white-space: nowrap;
}

.nav-link:hover {
  color: var(--gold-color);
}

.nav-link::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 2px;
  background-color: var(--gold-color);
  transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

.overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  z-index: 998;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.overlay.active {
  opacity: 1;
  visibility: visible;
}

/* Site Footer */
.site-footer {
  background-color: var(--deep-navy);
  color: var(--text-secondary);
  padding: 40px 20px 20px;
  font-size: 14px;
  line-height: 1.6;
  box-sizing: border-box;
}

.footer-top-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
  max-width: 1200px;
  margin: 0 auto 30px;
  border-bottom: 1px solid var(--divider-color);
  padding-bottom: 30px;
}

.footer-col h3 {
  color: var(--text-main);
  font-size: 18px;
  margin-bottom: 15px;
  position: relative;
}

.footer-col h3::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -5px;
  width: 40px;
  height: 2px;
  background-color: var(--gold-color);
}

.footer-logo {
  font-size: 28px;
  font-weight: bold;
  color: var(--gold-color);
  text-decoration: none;
  margin-bottom: 15px;
  display: inline-block;
}

.footer-description {
  margin-top: 15px;
  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: var(--text-secondary);
  text-decoration: none;
  transition: color 0.3s ease;
}

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

.footer-mid-slots {
  max-width: 1200px;
  margin: 0 auto 20px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  border-bottom: 1px solid var(--divider-color);
  padding-bottom: 20px;
}

.footer-slot-anchor-inner {
  min-height: 10px;
}

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

.footer-bottom p {
  margin: 0;
  color: var(--text-secondary);
}

/* Mobile Responsive Styles */
@media (max-width: 768px) {
  :root {
    --header-offset: 110px; /* Mobile: 60px (header-top) + 48px (main-nav) */
  }

  body.no-scroll {
    overflow: hidden;
  }

  /* Prevent content images from overflowing */
  .page-content img {
    max-width: 100% !important;
    height: auto !important;
    display: block;
  }
  .page-content {
    overflow-x: hidden;
    max-width: 100%;
  }
  body {
    overflow-x: hidden;
  }

  .site-header {
    box-shadow: 0 1px 5px rgba(0, 0, 0, 0.2);
  }

  .header-top {
    min-height: 60px !important;
    height: 60px !important;
    padding: 0 15px; /* Adjust padding for mobile */
    justify-content: space-between; /* Space between hamburger and logo */
  }

  .header-container {
    padding: 0; /* Handled by header-top now */
    max-width: none; /* No max-width on mobile */
    width: 100%;
    position: relative; /* For logo absolute centering */
  }

  .logo {
    flex: 1 !important;
    display: flex !important;
    justify-content: center !important; /* Center logo horizontally */
    align-items: center !important;
    position: absolute; /* Absolute positioning for better centering */
    left: 50%;
    transform: translateX(-50%);
    max-width: calc(100% - 100px); /* Leave space for hamburger */
    z-index: 1; /* Below hamburger menu */
  }

  .logo img {
    max-height: 56px !important; /* Smaller logo for mobile */
  }

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

  .hamburger-menu {
    display: block; /* Show hamburger menu on mobile */
    order: -1; /* Place it at the beginning */
  }

  .mobile-nav-buttons {
    display: flex !important; /* Show mobile buttons */
  }

  .main-nav {
    position: fixed;
    top: calc(60px + 48px); /* Calculated: header-top (60px) + mobile-nav-buttons (48px) */
    left: 0;
    width: 280px; /* Sidebar width */
    height: calc(100vh - (60px + 48px)); /* Fill remaining viewport height */
    background-color: var(--primary-color);
    flex-direction: column;
    justify-content: flex-start;
    padding-top: 0; /* Reset padding-top, as 'top' is calculated */
    transform: translateX(-100%); /* Hidden by default */
    transition: transform 0.3s ease-in-out;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.3);
    z-index: 999;
    overflow-y: auto;
    display: none; /* Hidden by default, JS will change to block/flex */
  }

  .main-nav.active {
    transform: translateX(0); /* Show menu */
    display: flex; /* Ensure it's visible when active */
  }

  .nav-container {
    flex-direction: column;
    align-items: flex-start; /* Align menu items to the left */
    padding: 0 20px;
    gap: 15px; /* Smaller gap for mobile menu items */
    width: 100%;
    max-width: none;
    height: auto;
  }

  .nav-link {
    width: 100%;
    padding: 10px 0;
    border-bottom: 1px solid var(--divider-color);
  }

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

  .nav-link::after {
    display: none; /* Hide underline animation for mobile menu */
  }

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

  .footer-col h3::after {
    left: 50%;
    transform: translateX(-50%);
  }

  .footer-col {
    text-align: center; /* Center footer content */
  }

  .footer-nav {
    text-align: center;
  }

  .footer-logo {
    margin-bottom: 10px;
  }

  .footer-mid-slots {
    grid-template-columns: 1fr;
    gap: 15px;
    padding-bottom: 15px;
  }
}
/* 移动端内容区防溢出（系统追加，请勿删除） */
@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;
}
