:root {
  --primary-color: #2F6BFF;
  --accent-color: #6FA3FF;
  --text-main-color: #1F2D3D;
  --text-black: #000000;
  --card-bg: #FFFFFF;
  --bg-color: #F4F7FB;
  --border-color: #D6E2FF;
  --glow-color: #A5C4FF;
  --btn-gradient: linear-gradient(180deg, #4A8BFF 0%, #2F6BFF 100%);
  --header-offset: 122px; /* Desktop: header-top (68px) + main-nav (52px) = 120px + 2px buffer */
}

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

/* Site Header - Fixed Navigation */
.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(--card-bg); /* Use white for the overall header background */
}

/* Header Top Section (Logo + Desktop Buttons / Hamburger + Logo Mobile) */
.header-top {
  box-sizing: border-box;
  min-height: 68px; /* Desktop height */
  height: 68px; /* Desktop height */
  display: flex;
  align-items: center;
  overflow: hidden;
  background-color: var(--primary-color); /* Distinct background for header-top */
  color: #fff;
}

.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; /* Padding for content inside container */
}

/* Logo */
.logo {
  font-size: 28px;
  font-weight: bold;
  color: #fff;
  text-decoration: none;
  display: flex; /* For potential image centering */
  align-items: center;
}
.logo img { /* For image logos, if they were used */
  display: block;
  max-height: 60px; /* Matches header-top height */
  height: auto;
  width: auto;
  max-width: 280px;
  object-fit: contain;
}

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

/* Mobile Navigation Buttons (hidden on desktop) */
.mobile-nav-buttons {
  box-sizing: border-box;
  display: none; /* Hidden on desktop by default */
  min-height: 48px; /* Mobile height */
  background-color: var(--accent-color); /* Distinct background for mobile buttons */
  padding: 0 20px;
  width: 100%;
}

/* Main Navigation Section (Menu) */
.main-nav {
  box-sizing: border-box;
  min-height: 52px; /* Desktop height */
  height: 52px; /* Desktop height */
  display: flex; /* Display on desktop */
  align-items: center;
  overflow: hidden;
  background-color: var(--accent-color); /* Distinct background for main-nav */
  width: 100%;
  flex-direction: row; /* Desktop horizontal */
  position: static; /* Desktop normal flow */
}

.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;
  gap: 30px; /* Spacing between nav links */
}

.nav-link {
  color: #fff;
  text-decoration: none;
  font-weight: 500;
  padding: 5px 0; /* Vertical padding to keep links centered */
  transition: color 0.3s ease;
  white-space: nowrap;
}
.nav-link:hover {
  color: var(--glow-color);
}

/* General Button Styles */
.btn {
  text-decoration: none;
  padding: 10px 20px;
  border-radius: 5px;
  font-weight: bold;
  color: #fff;
  text-align: center;
  white-space: nowrap;
  cursor: pointer;
  border: none;
  background: var(--btn-gradient);
  box-shadow: 0 2px 5px rgba(0,0,0,0.2);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.3);
}

/* Hamburger Menu (hidden on desktop) */
.hamburger-menu {
  display: none; /* Hidden on desktop */
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  width: 30px;
  height: 24px;
  position: relative;
  z-index: 1001; /* Above other header elements */
}
.hamburger-menu span {
  display: block;
  width: 100%;
  height: 3px;
  background-color: #fff;
  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);
}

/* Navigation Overlay (hidden on desktop) */
.nav-overlay {
  display: none; /* Hidden on desktop */
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0,0,0,0.5);
  z-index: 999;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.nav-overlay.active {
  opacity: 1;
  display: block;
}

/* Footer Styles */
.site-footer {
  background-color: var(--text-main-color); /* Dark background for footer */
  color: #fff;
  padding: 40px 0 20px;
}

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

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

.footer-logo {
  font-size: 24px;
  font-weight: bold;
  color: #fff;
  text-decoration: none;
  margin-bottom: 15px;
  display: block;
}

.footer-description {
  font-size: 14px;
  line-height: 1.6;
  color: #ccc;
  word-wrap: break-word; /* Ensure long words break */
  overflow-wrap: break-word; /* Modern property */
}

.footer-col h3 {
  color: var(--accent-color); /* Accent color for footer headings */
  margin-bottom: 15px;
  font-size: 18px;
  font-weight: bold;
}

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

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

.footer-nav li a {
  color: #ccc;
  text-decoration: none;
  font-size: 14px;
  transition: color 0.3s ease;
}
.footer-nav li a:hover {
  color: var(--glow-color);
}

.footer-middle-section,
.footer-slot-anchor-inner[data-slot-anchor^="footer_slot_mid_"],
.footer-slot-anchor-inner[data-slot-anchor^="footer_slot_top_row_"],
.footer-slot-anchor-inner[data-slot-anchor^="footer_slot_bottom_"] {
  min-height: 1px; /* Ensure these slots are renderable */
  /* No visible styles, content will be injected by system */
}
/* Specifically for the fourth column which must be empty */
.footer-col.footer-dynamic-col {
    min-height: 1px; /* Ensure renderable, but no content */
}

.footer-bottom {
  max-width: 1200px;
  margin: 30px auto 0;
  padding: 20px;
  text-align: center;
  border-top: 1px solid rgba(255,255,255,0.1);
  font-size: 13px;
  color: #aaa;
}

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

  /* Header Top Section */
  .header-top {
    min-height: 60px !important;
    height: 60px !important;
    background-color: var(--primary-color); /* Keep primary color for consistency */
  }
  .header-container {
    padding: 0 15px; /* Smaller padding for mobile */
    max-width: none; /* Full width for mobile */
    position: relative; /* For absolute positioning of logo */
  }

  /* Hamburger Menu (visible on mobile) */
  .hamburger-menu {
    display: block;
    position: relative; /* Ensure it's above the logo if logo is absolute */
    z-index: 2;
  }

  /* Logo (centered on mobile using Method 2) */
  .logo {
    position: absolute !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    display: flex !important; /* Keep for text/image logo content */
    align-items: center !important;
    justify-content: center !important;
    max-width: calc(100% - 100px); /* Allow space for hamburger and potential right items */
  }
  .logo img {
    display: block !important;
    max-width: 100%;
    height: auto;
    max-height: 56px; /* Matches mobile header-top height */
  }

  /* Desktop Buttons (hidden on mobile) */
  .desktop-nav-buttons {
    display: none !important;
  }

  /* Mobile Navigation Buttons (visible on mobile, below header-top) */
  .mobile-nav-buttons {
    display: flex !important; /* Show on mobile */
    min-height: 48px;
    align-items: center;
    justify-content: center; /* Center buttons horizontally */
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    padding: 0 15px; /* Smaller padding for mobile */
    overflow: hidden;
    gap: 10px;
    flex-wrap: nowrap; /* Ensure buttons stay in one row */
    background-color: var(--accent-color); /* Ensure distinct background */
    box-shadow: 0 2px 5px rgba(0,0,0,0.1); /* Add shadow to mobile buttons bar */
  }
  .mobile-nav-buttons .btn {
    flex: 1; /* Distribute space evenly */
    min-width: 0; /* Allow shrinking */
    max-width: calc(50% - 5px); /* Max width for two buttons with gap */
    box-sizing: border-box;
    padding: 8px 12px; /* Smaller padding for mobile buttons */
    font-size: 13px; /* Smaller font for mobile buttons */
    white-space: normal; /* Allow text to wrap */
    word-wrap: break-word;
    overflow-wrap: break-word;
  }

  /* Main Navigation (hidden by default on mobile, slides in) */
  .main-nav {
    min-height: 48px !important; /* Mobile height */
    height: calc(100% - var(--header-offset)) !important; /* Fill remaining height */
    width: 80%; /* Width of the sliding menu */
    max-width: 300px; /* Max width for sliding menu */
    position: fixed !important; /* Fixed position for sliding menu */
    top: var(--header-offset) !important; /* Position below header */
    left: 0;
    transform: translateX(-100%); /* Hidden by default */
    transition: transform 0.3s ease;
    background-color: var(--text-main-color); /* Dark background for mobile menu */
    flex-direction: column;
    padding: 20px;
    box-shadow: 2px 0 5px rgba(0,0,0,0.2);
    overflow-y: auto; /* Allow scrolling if menu content is long */
    z-index: 1001;
    display: none; /* Explicitly hidden */
  }
  .main-nav.active {
    transform: translateX(0);
    display: flex; /* Explicitly visible when active */
  }

  .nav-container {
    flex-direction: column;
    align-items: flex-start; /* Align links to the left */
    padding: 0; /* Remove horizontal padding */
    gap: 15px; /* Smaller gap for vertical links */
    height: auto; /* Auto height for content */
    max-width: none;
    width: 100%;
  }
  .nav-link {
    width: 100%;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    white-space: normal;
  }
  .nav-link:last-child {
    border-bottom: none;
  }

  /* Navigation Overlay (visible when active) */
  .nav-overlay {
    display: none; /* Hidden by default */
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0,0,0,0.5);
    z-index: 999;
    opacity: 0;
    transition: opacity 0.3s ease;
  }
  .nav-overlay.active {
    opacity: 1;
    display: block; /* Ensure it becomes block when active */
  }

  /* Body scroll lock */
  body.no-scroll {
    overflow: hidden;
  }

  /* Footer Mobile Styles */
  .footer-top-grid {
    grid-template-columns: 1fr; /* Single column layout for mobile */
    gap: 20px;
  }
  .footer-col {
    align-items: flex-start;
    text-align: left;
  }
  .footer-logo {
    margin: 0 auto 15px 0; /* Align logo left */
  }
  .footer-bottom {
    padding: 15px; /* Smaller padding */
  }

  /* Mobile content overflow protection */
  .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;
  }
}
/* 内容保护（系统追加，请勿删除） */
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;
}
