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

body {
  padding-top: var(--header-offset);
  overflow-x: hidden; /* Prevent horizontal scroll on body */
}

body.no-scroll {
  overflow: hidden;
}

/* General styles for the site-header */
.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.2);
  background-color: #140C0C; /* Background */
  box-sizing: border-box;
  overflow-x: hidden; /* Prevent header content overflow */
}

/* Header Top Area */
.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%;
  padding: 0 20px; /* Padding for the header-top itself */
}

.header-container {
  box-sizing: border-box;
  width: 100%;
  height: 100%;
  max-width: 1200px; /* Centered container within header-top padding */
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Logo */
.logo {
  color: #F3C54D; /* Gold */
  font-size: 28px;
  font-weight: bold;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 1px;
  display: block;
}

/* Desktop Navigation Buttons */
.desktop-nav-buttons {
  display: flex;
  gap: 12px;
  align-items: center;
}

/* Mobile Navigation Buttons (hidden by default) */
.mobile-nav-buttons {
  box-sizing: border-box;
  display: none; /* Hidden by default, shown on mobile */
  min-height: 48px;
  width: 100%;
  background-color: #2A1212; /* Card BG */
  padding: 10px 20px; /* Padding for the mobile buttons container */
  justify-content: center;
  align-items: center;
  overflow: hidden;
}

/* Main Navigation Area */
.main-nav {
  box-sizing: border-box;
  min-height: 52px;
  height: 52px;
  display: flex; /* Desktop: default flex for horizontal */
  align-items: center;
  overflow: hidden;
  background-color: #2A1212; /* Card BG */
  width: 100%;
  padding: 0 20px; /* Padding for the main-nav itself */
}

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

.nav-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 25px;
}

.nav-links li a {
  color: #FFF1E8; /* Text Main */
  text-decoration: none;
  font-size: 16px;
  padding: 5px 0;
  position: relative;
  transition: color 0.3s ease;
}

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

/* Buttons (General) */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 20px;
  border-radius: 25px;
  text-decoration: none;
  color: #140C0C; /* Dark text for bright button */
  font-weight: bold;
  font-size: 15px;
  background: linear-gradient(180deg, #FFB04A 0%, #D86A14 100%);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  white-space: nowrap;
  cursor: pointer;
  border: none;
  box-shadow: 0 4px 15px rgba(255, 176, 74, 0.4);
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 176, 74, 0.6);
}

/* Hamburger Menu (hidden by default on desktop) */
.hamburger-menu {
  display: none; /* Hidden on desktop */
  background: none;
  border: none;
  cursor: pointer;
  padding: 10px;
  z-index: 1001;
  order: -1; /* Place hamburger on the left */
}

.hamburger-menu span {
  display: block;
  width: 25px;
  height: 3px;
  background-color: #F3C54D; /* Gold */
  margin-bottom: 5px;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.hamburger-menu span:last-child {
  margin-bottom: 0;
}

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

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

.hamburger-menu.active span:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}

/* Overlay (hidden by default) */
.overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  z-index: 999;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.overlay.active {
  opacity: 1;
  visibility: visible;
}

/* Footer Styles */
.site-footer {
  background-color: #140C0C; /* Background */
  color: #FFF1E8; /* Text Main */
  padding: 40px 20px 20px;
  font-size: 14px;
  line-height: 1.6;
  box-sizing: border-box;
}

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

.footer-col h3 {
  color: #F3C54D; /* Gold */
  font-size: 18px;
  margin-bottom: 15px;
}

.footer-col .footer-logo {
  color: #F3C54D; /* Gold */
  font-size: 24px;
  font-weight: bold;
  text-decoration: none;
  text-transform: uppercase;
  display: block;
  margin-bottom: 15px;
}

.footer-col .footer-description {
  color: #FFF1E8; /* Text Main */
  word-wrap: break-word;
  overflow-wrap: break-word;
}

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

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

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

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

.footer-slot-anchor-inner {
  /* This container is intentionally left empty for dynamic content injection */
  margin-top: 15px; /* Add some spacing for injected content */
}

.footer-bottom {
  border-top: 1px solid #6A1E1E; /* Border */
  padding-top: 20px;
  margin-top: 20px;
  text-align: center;
  color: #FFF1E8; /* Text Main */
}

.footer-bottom p {
  margin: 0;
}

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

  .header-top {
    min-height: 60px !important;
    height: 60px !important;
    padding: 0 15px; /* Adjust padding for mobile */
  }

  .header-container {
    width: 100%;
    max-width: none; /* Ensure full width on mobile */
    justify-content: space-between;
    position: relative; /* For absolute positioning of logo */
  }

  .logo {
    position: absolute !important; /* Force absolute positioning */
    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 */
    font-size: 24px; /* Adjust logo size */
  }

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

  .mobile-nav-buttons {
    display: flex !important; /* Show mobile buttons */
    min-height: 48px;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    padding: 10px 15px; /* Adjust padding for mobile buttons */
    overflow: hidden;
    gap: 10px;
    flex-wrap: nowrap; /* Ensure buttons stay in one line */
    background-color: #2A1212; /* Card BG */
  }

  .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 */
    flex-direction: column; /* Vertical layout for menu items */
    position: fixed; /* Fixed position for off-canvas menu */
    top: var(--header-offset); /* Start below the fixed header + mobile buttons */
    left: 0;
    width: 280px; /* Width of the off-canvas menu */
    height: calc(100vh - var(--header-offset)); /* Full height below header */
    background-color: #2A1212; /* Card BG */
    transform: translateX(-100%); /* Off-screen by default */
    transition: transform 0.3s ease;
    padding: 20px 0;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.3);
    overflow-y: auto; /* Enable scrolling for long menus */
    z-index: 1001; /* Above overlay */
  }

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

  .nav-container {
    width: 100%;
    max-width: none; /* Full width */
    height: auto; /* Adjust height based on content */
    padding: 0; /* No horizontal padding for nav-container */
    align-items: flex-start; /* Align menu items to start */
  }

  .nav-links {
    flex-direction: column;
    width: 100%;
    gap: 0; /* Remove gap between li items */
  }

  .nav-links li {
    width: 100%;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

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

  .nav-links li a {
    padding: 12px 20px; /* Padding for mobile menu items */
    display: block;
    font-size: 15px;
  }

  .hamburger-menu {
    display: block; /* Show hamburger on mobile */
    position: relative; /* Ensure it's clickable */
    z-index: 1002; /* Above logo and desktop buttons */
  }

  /* Footer Mobile Styles */
  .site-footer {
    padding: 30px 15px 15px; /* Adjust padding */
  }

  .footer-top-grid {
    grid-template-columns: 1fr; /* Single column layout */
    gap: 25px;
    margin-bottom: 25px;
  }

  .footer-col h3 {
    font-size: 16px;
  }
  .footer-col .footer-logo {
    font-size: 20px;
  }

  /* Prevent content images from overflowing */
  .page-content img {
    max-width: 100% !important;
    height: auto !important;
    display: block;
  }
  .page-content {
    overflow-x: hidden;
    max-width: 100%;
  }
}
/* 移动端内容区防溢出（系统追加，请勿删除） */
@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;
  }
}
/* 内容保护（系统追加，请勿删除） */
body {
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}
input, textarea, select, [contenteditable="true"] {
  -webkit-user-select: text;
  -moz-user-select: text;
  user-select: text;
}
