:root {
  --header-offset: 122px;
  --primary-color: #FF8C1A;
  --secondary-color: #FFA53A;
  --button-gradient: linear-gradient(180deg, #FFA53A 0%, #D96800 100%);
  --card-bg: #17191F;
  --page-bg: #0D0E12;
  --text-main: #FFF3E6;
  --border-color: #A84F0C;
  --glow-color: #FFB04D;
  --deep-orange: #D96800;
}

body {
  padding-top: var(--header-offset);
  font-family: Arial, sans-serif;
  margin: 0;
  background-color: var(--page-bg);
  color: var(--text-main);
  overflow-x: hidden;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 1000;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
  box-sizing: border-box;
}

.header-top {
  box-sizing: border-box;
  height: 68px;
  display: flex;
  align-items: center;
  background-color: var(--page-bg); /* Darker background 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 20px;
}

.logo {
  font-size: 28px;
  font-weight: bold;
  color: var(--primary-color);
  text-decoration: none;
  display: flex;
  align-items: center;
  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: 10px;
  align-items: center;
}

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

.btn {
  padding: 10px 18px;
  border-radius: 25px;
  text-decoration: none;
  color: var(--text-main);
  font-weight: bold;
  background: var(--button-gradient);
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.btn:hover {
  filter: brightness(1.1);
  box-shadow: 0 0 10px var(--glow-color);
}

.main-nav {
  box-sizing: border-box;
  height: 52px;
  display: flex;
  align-items: center;
  background-color: var(--card-bg); /* Slightly lighter background for main-nav */
  width: 100%;
  transition: transform 0.3s ease;
}

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

.nav-link {
  color: var(--text-main);
  text-decoration: none;
  padding: 0 15px;
  height: 100%;
  display: flex;
  align-items: center;
  font-size: 15px;
  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(255, 255, 255, 0.05);
}

.hamburger-menu {
  display: none; /* Hidden on desktop */
  width: 30px;
  height: 24px;
  position: relative;
  cursor: pointer;
  z-index: 1001;
  margin-right: 15px;
}

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

.hamburger-menu span:nth-child(1) { top: 0; }
.hamburger-menu span:nth-child(2) { top: 50%; transform: translateY(-50%); }
.hamburger-menu span:nth-child(3) { bottom: 0; }

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

.mobile-overlay {
  display: none;
  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-overlay.active {
  display: block;
  opacity: 1;
}

/* Footer Styles */
.site-footer {
  background-color: var(--card-bg);
  padding: 40px 20px 20px;
  color: var(--text-main);
  font-size: 14px;
  box-sizing: border-box;
}

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

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

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

.footer-col .footer-description {
  line-height: 1.6;
  margin-bottom: 15px;
  word-wrap: break-word;
  overflow-wrap: break-word;
  color: #c0c0c0;
}

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

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

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

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

.footer-dynamic-col .footer-slot-anchor-inner {
  display: flex;
  flex-wrap: wrap;
  flex-direction: row;
  align-items: flex-start;
  gap: 5px;
}

.footer-dynamic-row {
  max-width: 1200px;
  margin: 0 auto 20px;
}

.footer-dynamic-row .footer-slot-anchor-inner {
  display: flex;
  flex-wrap: wrap;
  flex-direction: row;
  align-items: flex-start;
  gap: 8px;
  width: 100%;
}

.footer-bottom {
  max-width: 1200px;
  margin: 0 auto;
  padding-top: 20px;
  border-top: 1px solid var(--border-color);
  text-align: center;
  color: #999;
}

.footer-bottom p {
  margin: 0;
}

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

  .header-top {
    height: 60px !important;
    padding-left: 15px;
    padding-right: 15px;
    justify-content: space-between;
  }

  .header-container {
    width: 100%;
    max-width: none;
    padding: 0;
    justify-content: space-between; /* Hamburger left, Logo center, Space right */
  }

  .logo {
    flex: 1 !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    margin: 0;
    font-size: 24px;
  }

  .logo img {
    max-height: 56px !important;
  }

  .desktop-nav-buttons {
    display: none;
  }

  .hamburger-menu {
    display: block;
    margin-right: 0;
    position: relative;
    z-index: 1001;
  }

  .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;
    background-color: var(--card-bg);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
    z-index: 990; /* Below header, above main content */
  }

  .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;
    text-align: center;
  }

  .main-nav {
    height: 100vh;
    width: 280px;
    position: fixed;
    top: 0;
    left: 0;
    transform: translateX(-100%);
    background-color: var(--card-bg);
    padding-top: var(--header-offset); /* Account for header height */
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.5);
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    z-index: 1000;
    overflow-y: auto;
    display: none; /* Default hidden */
  }

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

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

  .nav-link {
    width: 100%;
    padding: 12px 20px;
    justify-content: flex-start;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 16px;
  }

  .footer-top-grid {
    grid-template-columns: 1fr;
  }

  .footer-col {
    margin-bottom: 20px;
  }

  .footer-col:last-child {
    margin-bottom: 0;
  }

  .footer-bottom {
    padding-left: 15px;
    padding-right: 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;
  }
}
