html, body { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Arial', sans-serif; color: #333333; }
body { padding-top: var(--header-offset); }
:root { --primary-color: #26A9E0; --auxiliary-color: #FFFFFF; --login-btn-color: #EA7C07; --header-offset: 122px; }

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 1000;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  background-color: var(--auxiliary-color);
}

.header-top {
  box-sizing: border-box;
  min-height: 68px;
  height: 68px;
  display: flex;
  align-items: center;
  overflow: hidden;
  background-color: var(--primary-color);
  color: var(--auxiliary-color);
  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;
}

.logo {
  font-size: 28px;
  font-weight: bold;
  color: var(--auxiliary-color);
  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 18px;
  border-radius: 25px;
  text-decoration: none;
  font-weight: bold;
  font-size: 15px;
  transition: all 0.3s ease;
  white-space: nowrap;
  cursor: pointer;
  border: none;
  text-align: center;
}

.btn-login {
  background-color: var(--login-btn-color);
  color: var(--auxiliary-color);
  box-shadow: 0 4px 8px rgba(234, 124, 7, 0.4);
}
.btn-login:hover {
  background-color: #ff8c00; /* Slightly darker orange */
}

.btn-register {
  background-color: var(--auxiliary-color);
  color: var(--primary-color);
  border: 2px solid var(--primary-color);
  box-shadow: 0 4px 8px rgba(38, 169, 224, 0.2);
}
.btn-register:hover {
  background-color: #e0f2f7; /* Lighter primary blue */
}

.hamburger-menu {
  display: none; /* Hidden on desktop */
  width: 30px;
  height: 24px;
  position: relative;
  cursor: pointer;
  z-index: 1001;
}
.hamburger-menu .bar {
  display: block;
  width: 100%;
  height: 3px;
  background-color: var(--auxiliary-color);
  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: 50%; transform: translateY(-50%); }
.hamburger-menu .bar:nth-child(3) { bottom: 0; }

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

.mobile-nav-buttons {
  box-sizing: border-box;
  display: none; /* Hidden on desktop, shown on mobile */
  min-height: 48px;
  background-color: var(--auxiliary-color);
  border-bottom: 1px solid #eee;
}

.main-nav {
  box-sizing: border-box;
  min-height: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  overflow: hidden;
  background-color: #EBF4FA; /* Lighter blue */
  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;
  flex-wrap: nowrap;
  overflow-x: auto; /* Allow horizontal scroll for many items */
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none; /* Firefox */
}
.nav-container::-webkit-scrollbar { display: none; /* Chrome, Safari, Edge */ }

.nav-link {
  padding: 10px 15px;
  color: #333333;
  text-decoration: none;
  font-size: 16px;
  font-weight: 500;
  white-space: nowrap;
  transition: color 0.3s ease, background-color 0.3s ease;
}
.nav-link:hover, .nav-link.active {
  color: var(--primary-color);
  background-color: rgba(38, 169, 224, 0.1);
  border-radius: 5px;
}

.overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0,0,0,0.5);
  z-index: 999;
  transition: opacity 0.3s ease;
  opacity: 0;
}
.overlay.active { opacity: 1; display: block; }

/* Footer Styles */
.site-footer {
  background-color: #222222;
  color: #cccccc;
  padding-top: 40px;
  font-size: 14px;
}

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

.footer-col h3 {
  color: var(--auxiliary-color);
  font-size: 18px;
  margin-bottom: 20px;
  white-space: nowrap;
}

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

.footer-col .footer-description {
  line-height: 1.6;
  margin-bottom: 15px;
  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: #cccccc;
  text-decoration: none;
  transition: color 0.3s ease;
}
.footer-nav a:hover {
  color: var(--primary-color);
}

.footer-legal {
  background-color: #1a1a1a;
  padding: 15px 0;
}
.footer-legal .footer-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 30px;
}
.footer-legal-nav {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 15px;
}
.footer-legal-nav a {
  color: #999999;
  text-decoration: none;
  font-size: 13px;
  transition: color 0.3s ease;
}
.footer-legal-nav a:hover {
  color: var(--primary-color);
}

.footer-bottom {
  background-color: #111111;
  text-align: center;
  padding: 15px 30px;
  color: #666666;
  font-size: 13px;
}
.footer-bottom p {
  margin: 0;
}

.footer-slot-anchor-inner, .footer-slot-anchor-outer {
  min-height: 1px; /* Ensure visibility for system injection */
}

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

  .header-top {
    min-height: 60px !important;
    height: 60px !important;
    position: relative;
  }
  .header-container {
    width: 100%;
    max-width: none;
    padding: 0 15px;
    justify-content: space-between;
  }
  .logo {
    position: absolute !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    max-width: calc(100% - 100px); /* Leave space for hamburger */
  }
  .logo img {
    max-height: 56px !important;
  }

  .desktop-nav-buttons {
    display: none !important;
  }
  .hamburger-menu {
    display: block;
    position: relative; /* Ensure z-index works */
    z-index: 2; /* Higher than logo if needed */
  }

  .mobile-nav-buttons {
    display: flex !important;
    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;
  }
  .mobile-nav-buttons .btn {
    flex: 1; min-width: 0;
    max-width: calc(50% - 5px);
    box-sizing: border-box;
    padding: 8px 12px;
    font-size: 13px;
    white-space: normal;
    word-wrap: break-word;
    overflow-wrap: break-word;
  }

  .main-nav {
    min-height: 48px !important;
    height: auto; /* Auto height for expanded menu content */
    position: fixed;
    top: var(--header-offset); /* Position below fixed header and mobile buttons */
    left: 0;
    width: 280px;
    max-width: 80%;
    background-color: var(--auxiliary-color);
    flex-direction: column;
    align-items: flex-start;
    transform: translateX(-100%); /* Hidden by default */
    transition: transform 0.3s ease;
    box-shadow: 2px 0 5px rgba(0,0,0,0.2);
    overflow-y: auto;
    display: none; /* Initially hidden, will be block/flex by JS */
    padding: 20px 0;
    z-index: 1001; /* Higher than header */
  }
  .main-nav.active {
    transform: translateX(0);
    display: flex; /* Show when active */
  }

  .nav-container {
    width: 100%;
    max-width: none;
    padding: 0;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    height: auto;
  }
  .nav-link {
    width: 100%;
    padding: 12px 20px;
    color: #333333;
    border-bottom: 1px solid #eee;
  }
  .nav-link:last-child { border-bottom: none; }

  .overlay.active {
    display: block;
  }

  .site-footer {
    padding-top: 30px;
  }
  .footer-grid {
    grid-template-columns: 1fr;
    padding: 0 15px 30px;
  }
  .footer-col h3 {
    margin-top: 25px;
  }
  .footer-col:first-child h3 { margin-top: 0; }

  .footer-legal .footer-container {
    padding: 0 15px;
  }
  .footer-legal-nav {
    flex-direction: column;
    gap: 10px;
    align-items: center;
  }
  .footer-bottom {
    padding: 15px;
  }

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