:root {
  --header-offset: 122px; /* desktop: header-top (68) + main-nav (52) + 2px buffer */
}

body {
  padding-top: var(--header-offset);
  overflow-x: hidden; /* Prevent horizontal scroll for body */
  margin: 0;
  font-family: 'Arial', sans-serif;
  color: #FFF1E8; /* Text Main */
  background-color: #140C0C; /* Background */
}

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

.header-top {
  box-sizing: border-box;
  min-height: 68px;
  height: 68px;
  display: flex;
  align-items: center;
  overflow: hidden;
  background-color: #7E0D0D; /* Deep Red */
  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-left: 20px;
  padding-right: 20px;
}

.logo {
  font-size: 24px;
  font-weight: bold;
  color: #F3C54D; /* Gold */
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
  max-width: 300px; /* Limit logo width */
}

.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 {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 20px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.3s ease;
  color: #FFF1E8; /* Text Main */
}

.btn-primary {
  background: linear-gradient(180deg, #FFB04A 0%, #D86A14 100%);
  border: 1px solid #D86A14;
}

.btn-primary:hover {
  opacity: 0.9;
}

.btn-secondary {
  background-color: #C61F1F; /* Primary color */
  border: 1px solid #E53030; /* Secondary color */
}

.btn-secondary:hover {
  background-color: #E53030; /* Secondary color */
}

.mobile-nav-buttons {
  box-sizing: border-box;
  display: none; /* Hidden by default on desktop */
  min-height: 48px;
  background-color: #2A1212; /* Card BG, distinct from header-top */
  width: 100%;
}

.main-nav {
  box-sizing: border-box;
  min-height: 52px;
  height: 52px;
  display: flex; /* Desktop default */
  align-items: center;
  overflow: hidden;
  background-color: #2A1212; /* Card BG */
  width: 100%;
}

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

.nav-link {
  color: #FFF1E8; /* Text Main */
  text-decoration: none;
  padding: 8px 12px;
  font-weight: bold;
  white-space: nowrap;
  transition: color 0.3s ease;
}

.nav-link:hover,
.nav-link.active {
  color: #F3C54D; /* Gold */
}

.hamburger-menu {
  display: none; /* Hidden by default on desktop */
  flex-direction: column;
  justify-content: space-around;
  width: 30px;
  height: 25px;
  cursor: pointer;
  padding: 5px;
  z-index: 1001;
}

.hamburger-menu .bar {
  display: block;
  width: 100%;
  height: 3px;
  background-color: #FFF1E8; /* Text Main */
  border-radius: 2px;
  transition: all 0.3s ease;
}

.hamburger-menu.active .bar:nth-child(1) {
  transform: translateY(11px) rotate(45deg);
}

.hamburger-menu.active .bar:nth-child(2) {
  opacity: 0;
}

.hamburger-menu.active .bar:nth-child(3) {
  transform: translateY(-11px) 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;
}

/* Footer Styles */
.site-footer {
  background-color: #140C0C; /* Background */
  color: #FFF1E8; /* Text Main */
  padding: 40px 20px 20px;
  font-size: 14px;
  border-top: 1px solid #6A1E1E; /* Border */
}

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

.footer-col {
  display: flex;
  flex-direction: column;
}

.footer-logo {
  font-size: 20px;
  font-weight: bold;
  color: #F3C54D; /* Gold */
  text-decoration: none;
  margin-bottom: 15px;
}

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

.footer-heading {
  font-size: 16px;
  color: #F3C54D; /* Gold */
  margin-bottom: 15px;
  white-space: nowrap;
}

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

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

.footer-nav a {
  color: #FFF1E8; /* Text Main */
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-nav a:hover {
  color: #F3C54D; /* Gold */
}

.footer-slot-anchor-inner {
  margin-top: 15px; /* Spacing for injected content */
}

.footer-bottom {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid #6A1E1E; /* Border */
  font-size: 13px;
}

.footer-bottom p {
  margin: 0;
}

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

  body {
    overflow-x: hidden;
  }

  .page-content img {
    max-width: 100% !important;
    height: auto !important;
    display: block;
  }

  .page-content {
    overflow-x: hidden;
    max-width: 100%;
  }

  .header-top {
    min-height: 60px !important;
    height: 60px !important;
    justify-content: space-between; /* For hamburger and potential right icon */
  }

  .header-container {
    width: 100%;
    max-width: none;
    padding-left: 15px;
    padding-right: 15px;
    position: relative; /* For absolute positioning of logo if needed */
  }

  .logo {
    flex: 1 !important; /* For centering with hamburger */
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    max-width: calc(100% - 80px); /* Account for hamburger width */
  }

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

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

  .mobile-nav-buttons {
    display: flex !important;
    min-height: 48px;
    align-items: center;
    justify-content: center;
    width: 100%; max-width: 100%;
    box-sizing: border-box;
    padding-left: 15px;
    padding-right: 15px;
    overflow: hidden;
    gap: 10px;
    flex-wrap: nowrap;
  }

  .mobile-nav-buttons .btn {
    flex: 1; min-width: 0;
    max-width: calc(50% - 5px); /* 50% - (gap/2) */
    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 */
    flex-direction: column; /* Vertical layout */
    position: fixed;
    top: var(--header-offset); /* Below fixed header and mobile buttons */
    left: 0;
    width: 100%;
    height: calc(100% - var(--header-offset)); /* Full height below header */
    background-color: #140C0C; /* Background color for menu */
    overflow-y: auto;
    transform: translateX(-100%); /* Off-screen by default */
    transition: transform 0.3s ease;
    z-index: 1001; /* Above overlay */
    padding-bottom: 20px; /* Add some padding at the bottom */
    box-sizing: border-box;
  }

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

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

  .nav-link {
    width: 100%;
    padding: 12px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

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

  .hamburger-menu {
    display: flex; /* Show hamburger on mobile */
  }

  .mobile-overlay.active {
    display: block;
  }

  .footer-grid {
    grid-template-columns: 1fr; /* Single column layout */
  }

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

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

.no-scroll {
  overflow: 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;
  }
}
