/* ============================================
   @FONT-FACE: 定制英文字体与数字字体引入
============================================ */
@font-face {
  font-family: 'Gilroy';
  src: url('../fonts/Gilroy-Regular.woff2') format('woff2'),
       url('../fonts/Gilroy-Regular.woff') format('woff');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Gilroy';
  src: url('../fonts/Gilroy-SemiBold.woff2') format('woff2'),
       url('../fonts/Gilroy-SemiBold.woff') format('woff');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Mistral';
  src: url('../fonts/Mistral.woff2') format('woff2'),
       url('../fonts/Mistral.woff') format('woff');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "iconfont";
  src: url('../fonts/iconfont.woff2') format('woff2');
}

/* 新增本地化 PT Sans 字体 */
@font-face {
  font-family: 'PT Sans';
  font-style: normal;
  font-weight: 400;
  src: url('../fonts/PTSans-Regular.woff2') format('woff2');
}
@font-face {
  font-family: 'PT Sans';
  font-style: normal;
  font-weight: 700;
  src: url('../fonts/PTSans-Bold.woff2') format('woff2');
}


/* ============================================
   CSS VARIABLES & BASE RESET
============================================ */
:root {
  --primary: #00479D;
  --primary-dark: #003580;
  --primary-light: #1a6fcc;
  --accent-green: #00A65A;
  --accent-orange: #FF6B00;
  --bg-light: #F5F5F7;
  --bg-dark: #1A1A1A;
  --text-dark: #222226; 
  --text-muted: #5f6368; 
  --border-light: rgba(0,0,0,0.08);
  --shadow-sm: 0 2px 12px rgba(0,0,0,0.08);
  --shadow-md: 0 8px 32px rgba(0,0,0,0.12);
  --shadow-lg: 0 16px 48px rgba(0,0,0,0.16);
  --radius: 12px;
  --radius-sm: 6px;
  --transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  
  --font-main: "PingFang SC", "Source Han Sans CN", "Microsoft YaHei", "STSong", "SimSun", Arial, sans-serif;
  --font-display: 'Gilroy', 'Helvetica Neue', Arial, sans-serif;
  --font-en: 'PT Sans', Arial, sans-serif;
  --font-art: 'Mistral', cursive;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; } 
body {
  font-family: var(--font-main);
  color: var(--text-dark);
  background: #fff;
  overflow-x: hidden;
  line-height: 1.85; 
  font-size: 1rem;
  -webkit-font-smoothing: antialiased; 
  -moz-osx-font-smoothing: grayscale;
}
a { text-decoration: none; color: inherit; }
img { max-width: 100%; }
ul { list-style: none; padding: 0; margin: 0; }

/* Section Titles (公共标题样式) */
.section-header { text-align: center; margin-bottom: 48px; }
.section-title {
  font-size: clamp(1.8rem, 3.5vw, 2.4rem);
  font-weight: 700;
  color: var(--text-dark);
  letter-spacing: 0.05em;
  position: relative;
  display: inline-block;
  margin-bottom: 14px;
}
.section-title::after {
  content: ''; display: block; width: 58px; height: 4px;
  background: var(--primary); margin: 14px auto 0; border-radius: 2px;
}
.section-subtitle { font-size: 1.1rem; color: var(--text-muted); letter-spacing: 0.02em; }

/* 公共按钮样式 */
.btn-primary-custom { display: inline-flex; align-items: center; gap: 8px; background: var(--primary); color: #fff; padding: 14px 32px; border-radius: 50px; font-size: 1.05rem; font-weight: 600; border: 2px solid var(--primary); transition: var(--transition); cursor: pointer; }
.btn-primary-custom:hover { background: transparent; color: var(--primary); }

/* ============================================
   NAVBAR
============================================ */
#main-navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 9999;
  background: transparent; 
  box-shadow: 0 0 0 transparent;
  border-bottom: 1px solid transparent;
  transition: background 0.4s ease, box-shadow 0.4s ease;
}
#main-navbar.scrolled { 
  background: #fff; 
  box-shadow: 0 4px 20px rgba(0,0,0,0.08); 
}
.navbar-inner { position: relative; display: flex; align-items: center; justify-content: space-between; height: 80px; padding: 0 32px; max-width: 1400px; margin: 0 auto; }
.navbar-logo { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.navbar-logo img { height: 58px; width: auto; object-fit: contain; transition: filter 0.4s ease; }
#main-navbar:not(.scrolled) .navbar-logo img { filter: brightness(0) invert(1); }

.nav-menu { display: flex; align-items: center; gap: 8px; height: 100%; }
.nav-item { position: static; height: 80px; display: flex; align-items: center; }
.nav-link-item {
  display: flex; align-items: center; gap: 6px; padding: 0 16px; height: 80px;
  font-size: 1.05rem; font-weight: 500; color: #fff; white-space: nowrap;
  cursor: pointer; border-bottom: 3px solid transparent; 
  transition: color 0.4s ease, border-color 0.4s ease, opacity 0.4s ease; position: relative;
}
#main-navbar:not(.scrolled) .nav-link-item:hover, 
#main-navbar:not(.scrolled) .nav-link-item.active { color: #fff; border-bottom-color: #fff; opacity: 0.9; }
#main-navbar.scrolled .nav-link-item { color: var(--text-dark); }
#main-navbar.scrolled .nav-link-item:hover, 
#main-navbar.scrolled .nav-link-item.active { color: var(--primary); border-bottom-color: var(--primary); font-weight: 700; }
.nav-link-item .fa-chevron-down { font-size: 0.7rem; transition: transform 0.3s; }
.nav-item:hover .fa-chevron-down { transform: rotate(180deg); }

/* TOP ACTIONS */
.nav-actions { display: flex; align-items: center; gap: 8px; }
.action-btn { 
  background: none; border: none; font-size: 1.25rem; color: #fff; cursor: pointer; transition: color 0.4s ease; 
  display: flex; align-items: center; justify-content: center; height: 80px; padding: 0 12px; outline: none;
}
#main-navbar.scrolled .action-btn { color: var(--text-dark); }
#main-navbar.scrolled .action-btn:hover { color: var(--primary); }
.navbar-mobile-toggle { display: none; }

/* SEARCH PANEL */
.search-panel {
  position: absolute; top: 100%; left: 0; right: 0; background: #fff; box-shadow: 0 10px 20px rgba(0,0,0,0.06);
  padding: 24px 32px; opacity: 0; visibility: hidden; transform: translateY(-10px); transition: all 0.3s ease; 
  z-index: 9997; border-top: 1px solid #eee;
}
.search-panel.open { opacity: 1; visibility: visible; transform: translateY(0); }
.search-input-wrap { display: flex; align-items: center; max-width: 800px; margin: 0 auto; border-bottom: 2px solid var(--primary); padding: 8px 12px; }
.search-input-wrap .fa-search { color: var(--primary); font-size: 1.2rem; }
.search-input-wrap input { flex: 1; border: none; outline: none; font-size: 1.1rem; padding: 0 16px; color: var(--text-dark); background: transparent; }
.search-input-wrap .close-search { background: none; border: none; color: #999; font-size: 1.4rem; cursor: pointer; transition: color 0.3s; padding: 0; outline: none; }
.search-input-wrap .close-search:hover { color: var(--accent-orange); }

/* Mega Menu */
.mega-menu {
  position: fixed; left: 0; right: 0; top: 80px; background: #fff; border-radius: 0 0 var(--radius) var(--radius); box-shadow: var(--shadow-lg);
  opacity: 0; visibility: hidden; transform: translateY(-8px); transition: opacity 0.28s ease, transform 0.28s ease, visibility 0.28s; z-index: 9998; overflow: hidden;
}
.nav-item:hover .mega-menu, .nav-item:focus-within .mega-menu { opacity: 1; visibility: visible; transform: translateY(0); }
.mega-menu-inner { max-width: 1200px; margin: 0 auto; display: flex; padding: 32px 32px; gap: 0; }
.mega-col-cats { min-width: 200px; border-right: 1px solid var(--border-light); padding-right: 24px; margin-right: 24px; }
.mega-cat-item { display: flex; align-items: center; justify-content: space-between; padding: 10px 16px; border-radius: var(--radius-sm); cursor: pointer; font-size: 0.95rem; color: #333; transition: var(--transition); white-space: nowrap; margin-bottom: 4px; }
.mega-cat-item:hover, .mega-cat-item.active { background: #EEF5FF; color: var(--primary); font-weight: 700; }
.mega-cat-item .fa { font-size: 0.7rem; opacity: 0.5; }
.mega-col-subs { min-width: 200px; border-right: 1px solid var(--border-light); padding-right: 24px; margin-right: 24px; }
.mega-sub-panel { display: none; }
.mega-sub-panel.active { display: block; }
.mega-sub-item { display: block; padding: 8px 16px; border-radius: var(--radius-sm); font-size: 0.95rem; color: #555; transition: var(--transition); margin-bottom: 4px; white-space: nowrap; }
.mega-sub-item:hover { background: #f0f4ff; color: var(--primary); }
.mega-col-image { flex: 1; min-width: 240px; }
.mega-img-wrap { border-radius: var(--radius-sm); overflow: hidden; background: var(--bg-light); }
.mega-img-caption { padding: 12px 16px; font-size: 0.9rem; color: var(--text-muted); line-height: 1.6; }
.mega-img-caption strong { display: block; font-size: 1rem; color: var(--text-dark); margin-bottom: 4px; }
.simple-col { min-width: 200px; border-right: 1px solid var(--border-light); padding-right: 24px; margin-right: 24px; }
.simple-col:last-child { border-right: none; margin-right: 0; }

/* ============================================
   MOBILE SIDE PANEL
============================================ */
/* 核心修改：将 z-index 提升至 10000 和 10001，确保完全盖住 z-index 为 9999 的主导航栏 */
.mobile-nav-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.5); z-index: 10000; backdrop-filter: blur(2px); }
.mobile-nav-panel {
  position: fixed; top: 0; right: -100%; width: min(320px, 85vw); height: 100vh;
  background: #fff; z-index: 10001; display: flex; flex-direction: column;
  transition: right 0.35s cubic-bezier(0.4,0,0.2,1); box-shadow: var(--shadow-lg);
}
.mobile-nav-panel.open { right: 0; }
.mobile-nav-overlay.show { display: block; }
.mobile-nav-header { display: flex; align-items: center; justify-content: space-between; padding: 20px 24px; border-bottom: 1px solid var(--border-light); background: #f8f9fc; flex-shrink: 0; }
.mobile-nav-logo { font-size: 1.3rem; font-weight: 800; color: var(--primary); letter-spacing: 1px;}
.mobile-close-btn { background: transparent; border: none; font-size: 1.6rem; color: #888; cursor: pointer; padding: 4px 8px; line-height: 1; transition: color 0.3s; outline: none; }
.mobile-close-btn:hover { color: var(--accent-orange); }
.mobile-nav-body { overflow-y: auto; flex: 1; padding-bottom: 40px; }
.mobile-nav-item { border-bottom: 1px solid var(--border-light); }
.mobile-nav-link { display: flex; align-items: center; justify-content: space-between; padding: 16px 24px; font-size: 1.1rem; font-weight: 500; color: var(--text-dark); cursor: pointer; }
.mobile-nav-link:hover { color: var(--primary); }
.mobile-sub-list { padding: 0 24px 12px 36px; display: none; }
.mobile-sub-list.open { display: block; }
.mobile-sub-list a { display: block; padding: 10px 0; font-size: 1rem; color: var(--text-muted); border-bottom: 1px dashed var(--border-light); }
.mobile-sub-list a:hover { color: var(--primary); }

/* ============================================
   FOOTER
============================================ */
.site-footer { background: var(--bg-dark); color: rgba(255,255,255,0.8); padding: 80px 0 0; }
.footer-grid { display: grid; grid-template-columns: 1fr 1fr 1fr 1.5fr; gap: 40px; padding-bottom: 50px; }
.footer-col-title { font-size: 1.1rem; font-weight: 700; color: #fff; letter-spacing: 0.06em; margin-bottom: 24px; position: relative; padding-bottom: 12px; }
.footer-col-title::after { content: ''; position: absolute; bottom: 0; left: 0; width: 32px; height: 2px; background: var(--primary); }
.footer-links { display: flex; flex-direction: column; gap: 12px; }
.footer-links a { font-size: 0.95rem; color: rgba(255,255,255,0.7); transition: color 0.3s; display: flex; align-items: center; gap: 8px; }
.footer-links a::before { content: '›'; color: var(--primary); font-size: 1.2rem; }
.footer-links a:hover { color: #fff; }
.footer-brand { margin-bottom: 24px; }
.footer-brand .brand-logo-img { display: inline-block; margin-bottom: 24px; }
.footer-brand .brand-logo-img img { height: 48px; width: auto; object-fit: contain; filter: brightness(0) invert(1); }
.footer-contact { font-size: 0.95rem; color: rgba(255,255,255,0.7); line-height: 1.8; margin-bottom: 20px; }
.footer-contact strong { color: rgba(255,255,255,0.9); }
.footer-qr-group { display: flex; gap: 16px; margin-top: 24px; }
.footer-qr-btn { display: inline-flex; align-items: center; gap: 8px; background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.15); color: #fff; font-size: 0.95rem; padding: 10px 20px; border-radius: 6px; cursor: pointer; transition: all 0.3s; }
.footer-qr-btn i { font-size: 1.2rem; }
.footer-qr-btn.wx:hover { background: #07c160; border-color: #07c160; }
.footer-qr-btn.dy:hover { background: #fe2c55; border-color: #fe2c55; }
.footer-copyright { border-top: 1px solid rgba(255,255,255,0.1); padding: 24px 0; font-size: 0.9rem; color: rgba(255,255,255,0.5); display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; }
.footer-copyright span { font-family: var(--font-display), var(--font-main); letter-spacing: 0.02em;}

/* ============================================
   BACK TO TOP BUTTON
============================================ */
#backToTop { position: fixed; right: 40px; bottom: 40px; width: 48px; height: 48px; background-color: var(--primary); color: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 1.2rem; box-shadow: 0 4px 16px rgba(0, 71, 157, 0.35); cursor: pointer; z-index: 9995; opacity: 0; visibility: hidden; transform: translateY(20px); transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1); }
#backToTop.show { opacity: 1; visibility: visible; transform: translateY(0); }
#backToTop:hover { background-color: var(--primary-dark); transform: translateY(-6px); box-shadow: 0 8px 24px rgba(0, 71, 157, 0.5); }

/* ============================================
   GLOBAL RESPONSIVE
============================================ */
@media (max-width: 1199px) { 
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 40px; } 
}
@media (max-width: 991px) {
  .nav-menu { display: none; } 
  .navbar-mobile-toggle { display: flex; }
}
@media (max-width: 767px) {
  .navbar-inner { padding: 0 16px; height: 64px; }
  .action-btn { height: 64px; }
  .section-header { margin-bottom: 36px; } 
  .site-footer { padding: 50px 0 0; }
  .footer-grid { grid-template-columns: 1fr; gap: 0; padding-bottom: 30px;}
  .footer-grid .footer-col:not(.footer-brand) { display: none; } 
  .footer-copyright { flex-direction: column; text-align: center; }
  #backToTop { right: 20px; bottom: 20px; width: 42px; height: 42px; font-size: 1rem; } 
}
