/* 全局样式 */
:root {
    --primary-color: #003366;
    --secondary-color: #50b674;
    --accent-color: #d4b87b;
    --light-color: #f5f5f5;
    --dark-color: #333333;
    --gray-color: #f5f5f5;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Microsoft YaHei', sans-serif;
    line-height: 1.6;
    color: var(--dark-color);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.btn {
    display: inline-block;
    background-color: #012f78;
    color: var(--light-color);
    padding: 12px 24px;
    text-decoration: none;
    border-radius: 4px;
    transition: all 0.3s ease;
    font-weight: 500;
}

.btn:hover {
    background-color: #012f78;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

section {
    padding: 80px 0;
}

h2 {
    font-size: 2.5rem;
    margin-bottom: 30px;
    position: relative;
}

/* 轮播图样式 */
.hero-slider {
    position: relative;
    width: 100%;
    height: 100vh;
    overflow: hidden;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1s ease;
    z-index: 1;
}

.slide.active {
    opacity: 1;
    z-index: 2;
}

.slide-content {
    display: flex;
    flex-direction: column;
    align-items: center; /* 水平居中 */
    justify-content: center; /* 垂直居中 */
    height: 100%;
    width: 100%; /* 添加宽度100% */
    padding: 0; /* 移除左侧padding */
    text-align: center; /* 文本居中 */
}

.main-title {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.sub-title {
    font-size: 2.5rem;
    font-weight: 600;
    margin-bottom: 2rem;
}

.master-logo {
    position: relative;
    display: inline-block;
}

.master-logo::after {
    content: "";
    position: absolute;
    top: -15px;
    right: -30px;
    width: 25px;
    height: 25px;
    background: linear-gradient(135deg, #ff7700, #ff0000);
    border-radius: 50%;
    filter: blur(1px);
}

.section-intro {
    display: flex;
    flex-direction: row; /* 改为水平排列 */
    align-items: center;
    justify-content: center; /* 添加水平居中 */
    gap: 20px; /* 添加图片间距 */
    max-width: 100%;
}

.slider-controls {
    position: absolute;
    bottom: 50px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    display: flex;
    gap: 20px;
    align-items: center;
}

.slider-controls button {
    background-color: rgba(255,255,255,0.3);
    color: var(--light-color);
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.slider-controls button:hover {
    background-color: var(--secondary-color);
    transform: scale(1.1);
}

.dots-container {
    display: flex;
    gap: 10px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: rgba(255,255,255,0.5);
    cursor: pointer;
    transition: all 0.3s ease;
}

.dot.active {
    background-color: var(--secondary-color);
    transform: scale(1.2);
}




.section-image {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 30px 0;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}



.news-section {
    background-color: var(--light-color);
    text-align: center;
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 50px;
}

.news-card {
    background-color: var(--light-color);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.news-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

.news-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.news-info {
    padding: 20px;
    text-align: left;
}

.news-info span {
    display: block;
    color: var(--secondary-color);
    font-weight: 500;
    margin-bottom: 10px;
}

.news-info h3 {
    font-size: 1.3rem;
    margin-bottom: 15px;
    color: var(--dark-color);
}

.news-info a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    position: relative;
    padding-bottom: 5px;
}

.news-info a::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}

.news-info a:hover::after {
    width: 100%;
}

/* 移动端响应式样式 */
@media (max-width: 992px) {
    .slide-content {
        padding: 0 5%;
        text-align: center;
    }

    .main-title {
        font-size: 2.8rem;
    }

    .sub-title {
        font-size: 2rem;
    }

    .section-intro {
        margin: 0 auto;
    }

    .certificate-content {
        margin: 0 auto;
    }

    .service-content,
    .certificate-content {
        max-width: 100%;
        text-align: center;
    }
}

@media (max-width: 768px) {
    .hero-slider {
        height: 80vh;
    }

    .slider-controls {
        bottom: 30px;
    }

    .main-title {
        font-size: 2.3rem;
    }

    .sub-title {
        font-size: 1.8rem;
    }

    h2 {
        font-size: 2rem;
    }
}

@media (max-width: 576px) {
    .hero-slider {
        height: 70vh;
    }

    .main-title {
        font-size: 1.8rem;
    }

    .sub-title {
        font-size: 1.4rem;
    }

    .section-intro {
        padding: 20px;
    }

    section {
        padding: 60px 0;
    }
}


/* 添加关键帧动画 */
@keyframes slideUpFadeIn {
    0% {
        transform: translateY(100px);
        opacity: 0;
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}


.slide-content img {
    opacity: 0;
    transition: none;
    display: block; /* 确保可以应用动画 */

    margin: 10px 0; /* 上下间距 */
}

/* 添加动画类 */
.slide-content .text-animate {
    animation: slideUpFadeIn 1s ease-out forwards;
}




/* 内容区域通用样式 */
.content-section {
    padding: 80px 0;
    background-size: cover;
    background-position: center;
    position: relative;
}

.content-section::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.content-container {
    position: relative;
    z-index: 2;
    max-width: 1400px;
    margin-left: 10%;
    padding: 0 20px;
}

.text-content {
    padding: 30px;
    /* 毛玻璃效果核心属性 */
    background: rgba(255, 255, 255, 0.5); /* 半透明底色 */
    backdrop-filter: blur(10px); /* 模糊效果 */
    -webkit-backdrop-filter: blur(10px); /* Safari兼容Safari */
    border-radius: 8px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1); /* 增强层次感 */
    border: 1px solid rgba(255, 255, 255, 0.18); /* 半透明白色边框 */
    color: var(--dark-color);
}

/* 左侧内容样式 */
.content-left .text-content {
    max-width: 40%;
    margin-right: auto;
}

/* 右侧内容样式 */
.content-right .text-content {
    max-width: 40%;
    margin-left: auto;
}

/* 中间内容样式 */
.content-center .text-content {
    max-width: 40%;
    margin: 0 auto;
}

/* 移动端布局调整 */
@media (max-width: 768px) {
    .content-left .text-content,
    .content-right .text-content,
    .content-center .text-content {
        max-width: 100%;
        margin: 0 auto;
    }
}

/* 企业介绍板块动画效果 */
.text-content {
    transition: all 0.3s ease;
    transform: translateY(0);
}

.text-content:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}


.text-content:hover .text-content {
    transform: translateX(10px);
}

/* 优化按钮动画 */
.btn {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.btn:hover::after {
    left: 100%;
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}



/* 手机端适配（屏幕宽度≤768px） */
@media (max-width: 768px) {
    /* 轮播图内容适配 */
    .slide-content {
        padding: 0 20px; /* 增加左右内边距，避免内容贴边 */
    }
    .slide-content img {
        max-width: 100%; /* 图片自适应屏幕宽度 */
        height: auto;
    }

    /* 内容区块布局调整（左右排版改为上下排版） */
    .content-section {
        background-position: center; /* 背景图居中显示 */
        padding: 40px 0; /* 减少上下 padding，避免内容过长 */
    }
    .content-container {
        width: 90%; /* 容器宽度适配手机 */
        margin: 0 auto;
    }
    .text-content {
        width: 100%; /* 文字区域占满宽度，不再分左右 */
        padding: 20px;
    }
    .text-content h2 {
        font-size: 24px; /* 调整标题大小 */
    }
    .text-content p {
        font-size: 14px; /* 调整文字大小 */
        line-height: 1.6;
    }

    /* 新闻区域适配 */
    .news-grid {
        display: flex;
        flex-direction: column; /* 新闻卡片垂直排列 */
        gap: 20px;
    }
    .news-card {
        width: 100%; /* 单张卡片占满宽度 */
    }

    /* 按钮适配触摸操作 */
    .btn {
        padding: 12px 24px; /* 增大按钮点击区域 */
        font-size: 16px;
    }

    /* 页脚布局调整 */
    .footer-middle {
        flex-direction: column; /* 公司信息和右侧内容上下排列 */
        gap: 30px;
        text-align: center; /* 文字居中 */
    }
    .company-info p {
        font-size: 13px; /* 缩小文字 */
    }
}


/* 文字介绍部分动画定义 */
@keyframes slideInFromLeft {
    0% {
        transform: translateX(-100px);
        opacity: 0;
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideInFromRight {
    0% {
        transform: translateX(100px);
        opacity: 0;
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

/* 初始状态 - 左侧滑入元素 */
.left-animate {
    opacity: 0;
    transform: translateX(-100px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

/* 初始状态 - 右侧滑入元素 */
.right-animate {
    opacity: 0;
    transform: translateX(100px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

/* 动画触发类 */
.animate-in {
    opacity: 1;
    transform: translateX(0);
}