:root {
  --color-main: #113B7A;
  --color-auxiliary: #1D5FD1;
  --color-button-gradient: linear-gradient(180deg, #2B73F6 0%, #1144A6 100%);
  --color-card-bg: #10233F;
  --color-text-main: #F3F8FF;
  --color-text-secondary: #AFC4E8;
  --color-border: #244D84;
  --color-glow: #4FA8FF;
  --color-gold: #F2C14E;
  --color-divider: #1B3357;
  --color-deep-navy: #08162B;
  --header-offset: 122px; /* Desktop: header-top (68px) + main-nav (52px) + 2px buffer */
}

body {
  margin: 0;
  font-family: 'Arial', sans-serif;
  color: var(--color-text-main);
  background-color: var(--color-deep-navy); /* A base background for the page */
  padding-top: var(--header-offset);
  overflow-x: hidden; /* Prevent horizontal scroll for body */
}

a {
  text-decoration: none;
  color: inherit;
}

/* 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);
}

.header-top {
  box-sizing: border-box;
  min-height: 68px;
  height: 68px;
  display: flex;
  align-items: center;
  overflow: hidden;
  background-color: var(--color-deep-navy); /* Darker blue for header-top */
  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 30px; /* Padding for logo and buttons */
}

.logo {
  font-size: 28px;
  font-weight: bold;
  color: var(--color-gold); /* Gold color for the logo */
  text-decoration: none;
  white-space: nowrap;
}

.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: 8px;
  font-size: 16px;
  font-weight: bold;
  text-align: center;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
  color: var(--color-text-main);
  background: var(--color-button-gradient);
  border: none;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.btn:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}

.mobile-nav-buttons {
  box-sizing: border-box;
  display: none; /* Hidden by default on desktop */
  min-height: 48px;
  background-color: var(--color-card-bg); /* Slightly different background for mobile buttons */
  justify-content: center; /* Center buttons horizontally if they don't fill width */
  align-items: center;
  width: 100%;
  padding: 0 15px; /* Add some padding for mobile */
}

.main-nav {
  box-sizing: border-box;
  min-height: 52px;
  height: 52px;
  display: flex; /* Default to flex for desktop */
  align-items: center;
  overflow: hidden;
  background-color: var(--color-main); /* Main blue for main-nav */
  width: 100%;
}

.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;
}

.nav-link {
  padding: 10px 15px;
  color: var(--color-text-main);
  font-size: 16px;
  font-weight: 500;
  white-space: nowrap;
  transition: color 0.3s ease;
}

.nav-link:hover, .nav-link.active {
  color: var(--color-gold); /* Highlight with gold on hover/active */
}

.hamburger-menu {
  display: none; /* Hidden on desktop */
  width: 30px;
  height: 24px;
  position: relative;
  cursor: pointer;
  z-index: 1001; /* Above header */
  padding: 5px; /* Make it easier to click */
  box-sizing: content-box;
}

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

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

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

.overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  z-index: 999;
}

/* Footer */
.site-footer {
  background-color: var(--color-card-bg); /* Card BG for footer background */
  padding: 40px 20px 20px;
  color: var(--color-text-secondary);
  font-size: 14px;
}

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

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

.footer-col h3::after {
  content: '';
  display: block;
  width: 40px;
  height: 2px;
  background-color: var(--color-auxiliary); /* Auxiliary color for heading underline */
  margin-top: 5px;
}

.footer-logo {
  font-size: 24px;
  font-weight: bold;
  color: var(--color-gold); /* Gold color for footer logo */
  margin-bottom: 15px;
  display: block;
}

.footer-description {
  line-height: 1.6;
  margin-bottom: 20px;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

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

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

.footer-nav a {
  color: var(--color-text-secondary);
  transition: color 0.3s ease;
}

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

.footer-bottom {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid var(--color-divider);
  color: var(--color-text-secondary);
}

/* Slot anchors, hidden by default unless content is injected */
.footer-slot-anchor-inner {
  min-height: 0; /* Ensures it collapses if empty */
  margin-top: 10px; /* Small space if content is injected */
}

/* Mobile styles */
@media (max-width: 768px) {
  :root {
    --header-offset: 110px; /* Mobile: header-top (60px) + mobile-nav-buttons (48px) + 2px buffer */
  }

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

  .header-container {
    padding: 0 15px;
    justify-content: space-between; 
    position: relative; 
  }
  
  .hamburger-menu {
    display: block; /* Show hamburger on mobile */
    order: 0; /* Ensures it's on the far left */
  }

  .logo {
    flex: 1 !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    order: 1; /* Place in the middle */
    font-size: 24px;
    max-width: calc(100% - 100px); /* Max width to prevent overlapping hamburger */
  }

  .logo img {
    max-height: 56px; /* Adjust for mobile header-top height */
  }

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

  .mobile-nav-buttons {
    display: flex !important; /* Show mobile buttons */
    min-height: 48px;
    height: auto; /* Allow height to adjust if text wraps */
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    padding: 10px 15px;
    overflow: hidden;
    gap: 10px;
    flex-wrap: nowrap; /* Ensure buttons stay in one row */
    justify-content: center; /* Center if less than 2 buttons */
  }

  .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;
  }

  .main-nav {
    display: none; /* Hidden by default on mobile */
    position: fixed;
    top: var(--header-offset); /* Position below fixed header and mobile buttons */
    left: 0;
    width: 70%; /* Adjust width for mobile menu */
    max-width: 300px; /* Max width for mobile menu */
    height: calc(100% - var(--header-offset)); /* Fill remaining height */
    background-color: var(--color-card-bg); /* Menu background */
    flex-direction: column;
    justify-content: flex-start;
    align-items: flex-start;
    padding: 20px;
    box-sizing: border-box;
    transform: translateX(-100%); /* Start off-screen */
    transition: transform 0.3s ease;
    overflow-y: auto; /* Allow scrolling for long menus */
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.3);
  }

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

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

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

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

  .overlay.active {
    display: block;
  }

  /* 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;
  }

  /* Footer */
  .footer-top-grid {
    grid-template-columns: 1fr; /* Single column on mobile */
    gap: 20px;
  }
  .footer-col {
    text-align: center; /* Center footer content on mobile */
  }
  .footer-col h3::after {
    margin: 5px auto 0; /* Center underline */
  }
  .footer-logo {
    margin-left: auto;
    margin-right: auto;
  }
  .footer-description {
    text-align: center;
  }
  .footer-nav {
    text-align: center;
  }
}
/* 移动端内容区防溢出（系统追加，请勿删除） */
@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;
  }
}
