/* ==========================================================================
   Central Go 官方网站样式表 (2025 最终汇总版)
   ========================================================================== */

/* 
   =========================================
   1. 全局变量与重置
   ========================================= 
*/
:root {
    --primary-blue: #001D31;
    --hover-blue: #004080;
    --accent-cyan: #3498db;
    --text-main: #333333;
    --text-light: #666666;
    --bg-gray: #f5f5f5;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Microsoft YaHei', -apple-system, BlinkMacSystemFont, sans-serif;
}

body {
    background-color: var(--bg-gray);
    color: var(--text-main);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

a {
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    flex: 1 0 auto;
}

/* 
   占位符设置 
   关键修复：手机端高度减半，消除多余空白
*/
#header-placeholder, 
#footer-placeholder {
    flex-shrink: 0;
}

#header-placeholder {
    min-height: 120px; /* 电脑端：Logo(70) + Nav(50) */
}

/* 
   =========================================
   2. 头部与导航栏
   ========================================= 
*/
.site-header-wrapper {
    width: 100%;
    background: white;
    position: relative;
    z-index: 1000;
}

/* --- 品牌栏 --- */
.brand-bar {
    height: 70px;
    background-color: white;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    position: relative;
    z-index: 1001;
}

.brand-flex {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}

.logo-link img {
    height: 48px;
    width: auto;
    transition: transform 0.3s;
}

.logo-link:hover img {
    transform: scale(1.08);
}

/* --- 导航栏 (桌面) --- */
.main-nav {
    background-color: var(--primary-blue);
    height: 50px;
    width: 100%;
    transition: all 0.3s ease;
}

.sticky-nav {
    position: sticky;
    top: 0;
    z-index: 999;
    box-shadow: 0 4px 15px rgba(0, 29, 49, 0.15);
}

.nav-list {
    display: flex;
    list-style: none;
    height: 50px;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin: 0;
    padding: 0;
}

.nav-list li {
    height: 100%;
    position: relative;
}

.nav-item {
    color: rgba(255, 255, 255, 0.85);
    font-size: 16px;
    font-weight: 500;
    padding: 0 20px;
    height: 100%;
    display: flex;
    align-items: center;
    width: 100%;
}

.nav-item:hover, 
.dropdown.active .nav-item {
    color: #ffffff;
    background-color: rgba(255, 255, 255, 0.05);
}

/* 桌面下划线动画 */
@media (min-width: 769px) {
    .nav-item::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 50%;
        width: 0;
        height: 3px;
        background-color: var(--accent-cyan);
        transition: all 0.3s;
    }
    
    .nav-item:hover::after, 
    .dropdown.active .nav-item::after {
        width: 100%;
        left: 0;
    }
}

/* --- 下拉菜单 --- */
.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    background-color: white;
    min-width: 200px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    border-radius: 8px;
    padding: 8px 0;
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
    border-top: 3px solid var(--accent-cyan);
    z-index: 100;
    list-style: none;
    margin: 0;
}

.dropdown-menu a {
    color: #333;
    padding: 12px 20px;
    font-size: 14px;
    display: block;
}

.dropdown-menu a:hover {
    background-color: #f4f6f8;
    color: var(--primary-blue);
    padding-left: 25px;
}

@media (min-width: 769px) {
    .dropdown:hover .dropdown-menu {
        opacity: 1;
        visibility: visible;
        transform: translateX(-50%) translateY(0);
    }
    
    .plus-icon {
        display: none;
    }
    
    .arrow-icon {
        margin-left: 6px;
        font-size: 10px;
        transition: 0.3s;
    }
    
    .dropdown:hover .arrow-icon {
        transform: rotate(180deg);
    }
}

/* --- 移动端菜单适配 --- */
.mobile-menu-toggle {
    display: none;
}

@media (max-width: 840px) {
    .brand-bar {
        height: 60px;
        padding: 0 10px;
    }
    
    .logo-link img {
        height: 40px;
    }

    #header-placeholder {
        min-height: 60px; /* 手机端：仅 Logo(60) */
    }
    
    /* 汉堡按钮 */
    .mobile-menu-toggle {
        display: flex;
        align-items: center;
        gap: 8px;
        background: transparent;
        border: none;
        cursor: pointer;
        padding: 5px;
    }
    
    .menu-text {
        font-size: 14px;
        font-weight: bold;
        color: var(--primary-blue);
    }
    
    .hamburger-icon {
        width: 24px;
        height: 18px;
        position: relative;
        display: flex;
        flex-direction: column;
        justify-content: space-between;
    }
    
    .hamburger-icon span {
        width: 100%;
        height: 2px;
        background-color: var(--primary-blue);
        transition: all 0.3s;
    }
    
    .mobile-menu-toggle.active .hamburger-icon span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 6px);
    }
    
    .mobile-menu-toggle.active .hamburger-icon span:nth-child(2) {
        opacity: 0;
    }
    
    .mobile-menu-toggle.active .hamburger-icon span:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -6px);
    }
    
    /* 移动端菜单容器 */
    .main-nav {
        /* 定位与初始隐藏 */
        position: absolute;
        top: 60px;
        left: 0;
        width: 100%;
        max-height: 0;
        overflow: hidden;
        
        /* 样式重置 */
        background-color: transparent;
        box-shadow: none;
        padding: 0;
        border: none;
        height: auto !important; /* 关键：覆盖桌面端的 50px 高度 */
        
        transition: max-height 0.4s ease, background-color 0.2s ease;
    }
    
    .main-nav.active {
        max-height: 100vh; /* 展开 */
        padding-bottom: 20px;
        border-top: 1px solid #eee;
        background-color: white;
        box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
    }
    
    /* 列表布局转为纵向 */
    .nav-list {
        flex-direction: column !important; /* 关键：强制纵向 */
        height: auto !important; /* 关键：高度自适应 */
        gap: 0;
    }
    
    .nav-list li {
        width: 100%;
        height: auto;
        border-bottom: 1px solid #f5f5f5;
    }
    
    .nav-item {
        color: #333;
        padding: 15px 20px;
        justify-content: space-between;
        width: 100%; /* 手机端占满整行 */
    }
    
    .nav-item:hover, 
    .dropdown.active .nav-item {
        background-color: #f8f9fa;
        color: var(--primary-blue);
    }
    
    /* 移动端子菜单 */
    .dropdown-menu {
        position: static;
        transform: none;
        box-shadow: none;
        border: none;
        padding: 0;
        min-width: 100%;
        display: none;
        background-color: #f9f9f9;
        opacity: 1;
        visibility: visible;
    }
    
    .dropdown-menu.active {
        display: block;
    }
    
    .dropdown-menu a {
        padding-left: 40px;
        color: #666;
    }
    
    .arrow-icon {
        display: none;
    }
    
    .plus-icon {
        display: inline-block;
        font-weight: bold;
        color: var(--accent-cyan);
        font-size: 18px;
        transition: transform 0.3s;
    }
    
    .dropdown.active .plus-icon {
        transform: rotate(45deg);
    }
}

/* 
   =========================================
   3. 首页特定样式 (Gallery & Toolbar)
   ========================================= 
*/
.gallery {
    width: 100%;
    margin-bottom: 20px;
}

.gallery-item {
    width: 100%;
    margin-bottom: 5px;
    overflow: hidden;
    position: relative;
}

.gallery-item img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.5s ease;
}

.gallery-item:hover img {
    transform: scale(1.02);
}

.toolbar-section {
    padding: 60px 0;
    background-color: #fff;
    border-top: 1px solid #eee;
}

.toolbar-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 20px;
}

.toolbar-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    transition: all 0.3s ease;
    border: 1px solid #f0f0f0;
}

.toolbar-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.toolbar-img {
    width: 100%;
    height: 120px;
    object-fit: cover;
    border-bottom: 1px solid #eee;
}

.toolbar-label {
    padding: 12px;
    color: #333;
    font-size: 14px;
    text-align: center;
    font-weight: 500;
}

@media (max-width: 1200px) {
    .toolbar-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 768px) {
    .toolbar-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 480px) {
    .toolbar-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .toolbar-img {
        height: 100px;
    }
}

/* 
   =========================================
   4. 现代页脚样式 (Modern Footer)
   ========================================= 
*/
.site-footer-wrapper {
    background-color: var(--primary-blue);
    color: #aab8c2;
    font-size: 14px;
    margin-top: auto;
}

.footer-links-section {
    padding: 50px 0 40px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-grid {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 40px;
}

.footer-column {
    flex: 1;
    min-width: 280px;
}

.footer-column h4 {
    color: #fff;
    font-size: 18px;
    margin-bottom: 20px;
    position: relative;
    display: inline-block;
}

.footer-column h4::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -8px;
    width: 30px;
    height: 2px;
    background-color: var(--accent-cyan);
}

.social-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.social-btn {
    display: inline-block;
    padding: 6px 15px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    color: #fff;
    font-size: 13px;
}

.social-btn:hover {
    background-color: #fff;
    color: var(--primary-blue);
    transform: translateY(-2px);
}

.friend-links {
    list-style: none; /* 去除圆点 */
    padding: 0;
    margin: 0;
}

.friend-links a {
    display: flex;
    align-items: center;
    color: #aab8c2;
}

.friend-links a:before {
    content: '›';
    margin-right: 8px;
    color: var(--accent-cyan);
    font-size: 18px;
}

.friend-links a:hover {
    color: #fff;
    padding-left: 5px;
}

.footer-copyright {
    padding: 25px 0;
    background-color: #001524;
}

.copyright-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.beian-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.beian-info img {
    width: 16px;
    height: 16px;
    margin-right: 4px;
}

/* =========================================
   微信二维码悬浮窗样式 (WeChat QR Popup)
   ========================================= */

/* 1. 父容器定位上下文 */
.wechat-trigger {
    position: relative; /* 关键：让子元素绝对定位相对于它 */
    cursor: pointer;
}

/* 2. 二维码弹窗 (默认隐藏) */
.qr-popup {
    display: none; /* 默认隐藏 */
    position: absolute;
    bottom: 140%; /* 位于按钮上方 */
    left: 50%;
    transform: translateX(-50%);
    background: white;
    padding: 10px;
    border-radius: 8px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
    width: 140px;
    text-align: center;
    z-index: 9999;
}

/* 小三角形装饰 */
.qr-popup::after {
    content: '';
    position: absolute;
    top: 100%; /* 位于弹窗底部 */
    left: 50%;
    transform: translateX(-50%);
    border-width: 6px;
    border-style: solid;
    border-color: white transparent transparent transparent;
}

/* 二维码图片 */
.qr-popup img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 4px;
    margin-bottom: 5px;
}

/* 提示文字 */
.qr-popup span {
    display: block;
    font-size: 12px;
    color: #333;
    line-height: 1.4;
    font-weight: normal; /* 覆盖父级可能的 bold */
}

/* 3. 桌面端 Hover 显示 */
@media (min-width: 769px) {
    .wechat-trigger:hover .qr-popup {
        display: block;
        animation: fadeIn 0.2s ease-out;
    }
}

/* 4. 移动端/JS激活状态 (.show 类) */
.wechat-trigger.show .qr-popup {
    display: block;
    animation: fadeIn 0.2s ease-out;
}

/* 简单的淡入动画 */
@keyframes fadeIn {
    from { opacity: 0; transform: translateX(-50%) translateY(10px); }
    to   { opacity: 1; transform: translateX(-50%) translateY(0); }
}

@media (max-width: 768px) {
    .footer-grid {
        flex-direction: column;
        text-align: center;
    }
    
    .footer-column h4::after {
        left: 50%;
        transform: translateX(-50%);
    }
    
    .social-links, 
    .friend-links a, 
    .copyright-content, 
    .beian-info {
        justify-content: center;
        text-align: center;
    }
    
    .beian-info {
        flex-direction: column;
        gap: 5px;
    }
}

/* 
   =========================================
   5. 现代化内页系统 (.modern-page)
   ========================================= 
*/
.modern-page {
    background-color: #f4f6f8;
    color: #2c3e50;
}

.modern-page .container {
    max-width: 1100px;
}

/* --- 分离式头图 (上图下文布局) --- */
.hero-split {
    padding-bottom: 40px;
    background-color: #fff;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

/* 图片区域 */
.hero-media {
    width: 100%;
    overflow: hidden;
    line-height: 0;
}

.hero-media img {
    width: 100%;
    height: 600px;
    object-fit: cover;
    display: block;
    border-radius: 0;
}

/* 文字区域 */
.hero-content {
    padding: 60px 0;
    text-align: left;
}

.hero-content .text-wrapper {
    max-width: 900px;
    margin: 0 auto;
}

.hero-content h1 {
    font-size: 36px;
    font-weight: 800;
    color: var(--primary-blue);
    margin-bottom: 25px;
    line-height: 1.3;
}

.hero-content p {
    font-size: 18px;
    line-height: 1.8;
    margin-bottom: 20px;
    color: #546e7a;
}

/* 按钮组 */
.hero-actions {
    margin-top: 35px;
    display: flex;
    justify-content: flex-start;
    gap: 20px;
}

/* 实心按钮 */
.modern-page .btn-primary {
    background: var(--primary-blue);
    color: white;
    padding: 12px 35px;
    border-radius: 50px;
    font-weight: bold;
    text-transform: uppercase;
    border: 2px solid var(--primary-blue);
    display: inline-block;
    box-shadow: 0 5px 15px rgba(0, 29, 49, 0.2);
    transition: all 0.3s ease;
}

.modern-page .btn-social1 {
    background: linear-gradient(to top, #d57406, #ffb114);
    color: white;
    padding: 14px 35px;
    border-radius: 50px;
    font-weight: bold;
    text-transform: uppercase;
    display: inline-block;
    box-shadow: 0 5px 15px rgba(0, 29, 49, 0.2);
    transition: all 0.3s ease;
}

.modern-page .btn-social2 {
    background: linear-gradient(to top, #d7377d, #ff88b1);
    color: white;
    padding: 14px 35px;
    border-radius: 50px;
    font-weight: bold;
    text-transform: uppercase;
    display: inline-block;
    box-shadow: 0 5px 15px rgba(0, 29, 49, 0.2);
    transition: all 0.3s ease;
}

.modern-page .btn-social3 {
    background: linear-gradient(to top, #a513a0, #f6a83b);
    color: white;
    padding: 14px 35px;
    border-radius: 50px;
    font-weight: bold;
    text-transform: uppercase;
    display: inline-block;
    box-shadow: 0 5px 15px rgba(0, 29, 49, 0.2);
    transition: all 0.3s ease;
}

.modern-page .btn-social4 {
    background: linear-gradient(to top, #1c1c1c, #565656);
    color: white;
    padding: 14px 35px;
    border-radius: 50px;
    font-weight: bold;
    text-transform: uppercase;
    display: inline-block;
    box-shadow: 0 5px 15px rgba(0, 29, 49, 0.2);
    transition: all 0.3s ease;
}

.modern-page .btn-icon {
    vertical-align: middle;
    width: 1.2em;
    height: 1.2em;
    fill: currentColor;
    margin-top: -3px;
}

.modern-page .btn-primary:hover {
    background: var(--hover-blue);
    border-color: var(--hover-blue);
    transform: translateY(-3px);
}

/* 线框按钮 */
.modern-page .btn-outline {
    background: transparent;
    color: var(--primary-blue);
    padding: 12px 35px;
    border-radius: 50px;
    font-weight: bold;
    text-transform: uppercase;
    border: 2px solid var(--primary-blue);
    display: inline-block;
    transition: all 0.3s ease;
}

.modern-page .btn-outline:hover {
    background: var(--primary-blue);
    color: white;
    transform: translateY(-3px);
}

/* --- 通用内容布局 (Card Layout) --- */
.modern-page .content-section {
    background: transparent;
    padding-top: 20px;
}

.modern-page .content-group {
    background: #ffffff;
    padding: 50px;
    border-radius: 20px;
    margin-bottom: 50px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.8);
    transition: all 0.3s ease;
    
    /* 强制 Flex 左右布局 */
    display: flex;
    flex-direction: row; 
    align-items: center;
    gap: 40px;
}

.modern-page .content-group:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
}

.modern-page .content-group.reverse {
    flex-direction: row-reverse;
}

/* 现代排版 */
.modern-page .content-text {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 20px;
    flex: 1;
    min-width: 0;
}

.modern-page .content-text h3 {
    font-size: 28px;
    font-weight: 800;
    color: var(--primary-blue);
    margin-bottom: 25px;
    border-bottom: none;
    position: relative;
    line-height: 1.3;
}

.modern-page .content-text h3::before {
    content: '';
    position: absolute;
    top: -15px;
    left: 0;
    width: 40px;
    height: 4px;
    background: var(--accent-cyan);
    border-radius: 2px;
}

.modern-page .content-text p {
    font-size: 16px;
    line-height: 1.9;
    color: #546e7a;
    text-align: justify;
    margin-bottom: 15px;
}

/* 图片相框 */
.modern-page .content-image {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 1;
    min-width: 0;
}

.modern-page .content-image img {
    width: 100%;
    height: auto;
    border-radius: 12px;
    border: 8px solid #f8f9fa;
    box-shadow: none;
}

/* --- 特殊样式 B: Text Only (深色块) --- */
.modern-page .content-group.text-only {
    background: linear-gradient(120deg, var(--primary-blue), #003366);
    color: white;
    padding: 60px;
    text-align: center;
    border: none;
    display: block;
}

.modern-page .content-group.text-only h3 {
    color: white;
}

.modern-page .content-group.text-only h3::before {
    left: 50%;
    transform: translateX(-50%);
    background: #4cc9f0;
}

.modern-page .content-group.text-only p {
    color: rgba(255, 255, 255, 0.85);
    max-width: 800px;
    margin: 0 auto 15px;
    text-align: center;
}

.modern-page .content-group.text-only a.read-more {
    background: white;
    color: var(--primary-blue);
    border: none;
    margin-top: 20px;
    display: inline-block;
    padding: 12px 30px;
    border-radius: 50px;
    font-weight: bold;
}

.modern-page .content-group.text-only a.read-more:hover {
    background: #4cc9f0;
    color: white;
    transform: scale(1.05);
}

/* --- 普通卡片内按钮 --- */
.modern-page .content-group .read-more {
    background: transparent;
    color: var(--accent-cyan);
    border: 2px solid var(--accent-cyan);
    padding: 8px 25px;
    border-radius: 30px;
    font-weight: 600;
    text-align: center;
    display: inline-block;
    margin-top: 10px;
    box-shadow: none;
}

.modern-page .content-group .read-more:hover {
    background: var(--accent-cyan);
    color: white;
}

/* 视频容器 */
.video-container {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%;
    height: 0;
    border-radius: 20px;
    overflow: hidden;
    background: #000;
    border: 4px solid white;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
}

.video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* --- 响应式微调 (Mobile) --- */
@media (max-width: 768px) {
    /* 头图自适应 */
    .hero-media img {
        height: 400px;
    }
    
    .hero-content {
        padding: 40px 0;
    }
    
    .hero-content h1 {
        font-size: 26px;
    }
    
    .hero-content p {
        font-size: 16px;
    }
    
    /* 按钮堆叠 */
    .hero-actions {
        flex-direction: column;
        width: 100%;
    }
    
    .modern-page .btn-primary,
    .modern-page .btn-outline {
        width: 100%;
        text-align: center;
    }
    
    /* 内容卡片堆叠 */
    .modern-page .content-group {
        padding: 30px 20px;
        flex-direction: column;
    }
    
    .modern-page .content-group.reverse {
        flex-direction: column;
    }
    
    .modern-page .content-text h3::before {
        top: -10px;
    }
}