:root {
  --primary-color: #F2C14E;
  --secondary-color: #FFD36B;
  --button-gradient: linear-gradient(180deg, #FFD86A 0%, #DDA11D 100%);
  --card-bg: #111111;
  --background-color: #0A0A0A;
  --text-main: #FFF6D6;
  --border-color: #3A2A12;
  --glow-color: #FFD36B;
  --header-offset: 122px; /* Desktop: 68px top + 52px main nav */
}

body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding-top: var(--header-offset);
  background-color: var(--background-color);
  color: var(--text-main);
  line-height: 1.6;
}

.site-header {
  position: fixed;
  top: 0;
  width: 100%;
  background-color: var(--background-color);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
  z-index: 1000;
  min-height: 68px; /* Based on 68px top bar height */
  display: flex;
  align-items: center;
}

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 10px 30px; /* Adjusted padding */
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  min-height: 48px; /* Main nav min height */
}

.logo {
  flex-shrink: 0;
  font-size: 28px;
  font-weight: bold;
  color: var(--primary-color);
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 1px;
  display: block;
}

.hamburger-menu {
  display: none;
}

.main-nav {
  flex: 1;
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  gap: 25px;
  margin: 0 20px;
}

.main-nav .nav-link {
  color: var(--text-main);
  text-decoration: none;
  font-size: 16px;
  padding: 5px 0;
  position: relative;
  transition: color 0.2s ease, transform 0.2s ease;
}

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

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

.main-nav .nav-link:hover {
  color: var(--primary-color);
  transform: translateY(-2px);
}

.desktop-nav-buttons {
  display: flex;
  gap: 10px;
  flex-shrink: 0;
}

.mobile-nav-buttons {
  display: none !important;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 20px;
  border-radius: 25px;
  font-size: 15px;
  font-weight: bold;
  text-decoration: none;
  color: #333; /* Text color for gradient buttons */
  background: var(--button-gradient);
  border: none;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 4px 10px rgba(242, 193, 78, 0.3);
  white-space: nowrap;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(242, 193, 78, 0.5);
}

/* Footer styles */
.site-footer {
  background-color: var(--background-color);
  color: var(--text-main);
  padding: 40px 20px 20px;
  font-size: 14px;
  border-top: 1px solid var(--border-color);
}

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

.footer-col h3 {
  font-size: 18px;
  color: var(--primary-color);
  margin-bottom: 20px;
  text-transform: uppercase;
}

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

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

.footer-nav a {
  display: block;
  color: rgba(255, 246, 214, 0.8);
  text-decoration: none;
  margin-bottom: 10px;
  transition: color 0.2s ease;
}

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

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

.footer-slot-anchor-inner {
  min-height: 10px; /* Ensure anchor is visible for injection */
}

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

  .header-container {
    width: 100%;
    max-width: none;
    padding: 10px 15px;
    justify-content: space-between;
    min-height: 60px; /* Adjust min height for mobile header */
  }

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

  .hamburger-menu {
    display: block;
    flex-shrink: 0;
    background: none;
    border: none;
    font-size: 28px;
    color: var(--text-main);
    cursor: pointer;
    z-index: 1001;
    padding: 5px;
  }

  .hamburger-menu.active::before {
    content: '\2715'; /* 'X' icon */
  }

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

  .mobile-nav-buttons {
    display: flex !important;
    gap: 8px;
    flex-shrink: 0;
  }

  .main-nav {
    display: none; /* Hidden by default */
    flex-direction: column;
    position: fixed;
    top: var(--header-offset); /* Start below the fixed header */
    left: 0;
    width: 280px;
    height: calc(100vh - var(--header-offset));
    background-color: var(--card-bg);
    padding: 20px;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.5);
    transform: translateX(-100%); /* Slide out initially */
    transition: transform 0.3s ease-out;
    z-index: 999;
    overflow-y: auto;
    align-items: flex-start; /* Align links to start */
  }

  .main-nav.active {
    display: flex; /* Must be flex to display */
    transform: translateX(0); /* Slide in */
  }

  .main-nav .nav-link {
    color: var(--text-main);
    padding: 12px 0;
    border-bottom: 1px solid var(--border-color);
    width: 100%;
    font-size: 18px;
  }

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

  .mobile-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 998;
    transition: opacity 0.3s ease-out;
    opacity: 0;
  }

  .mobile-menu-overlay.active {
    display: block;
    opacity: 1;
  }

  body.no-scroll {
    overflow: hidden;
  }

  .footer-main-content {
    grid-template-columns: 1fr;
    gap: 20px;
  }

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

  .footer-logo {
    display: inline-block;
  }

  .footer-nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px 20px;
  }

  .footer-nav a {
    display: inline-block;
    margin: 0;
  }

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