body {

    /* background-color: #F3F4F4; */

    overflow-x: hidden;
}

.works-section{
    padding: 200px 0 100px 0;
    position: relative;
}

.bg-1{
    content: '';
    position: absolute;
    top: 0;
    left: 5%;
    width: 45%;
    height: 160px;
    
    background-image: url(../pics/works-bg-1.png);
    background-size: 100% 100%;
    background-position: center;
    background-repeat: no-repeat;
    z-index: -1;
    
}

.bg-2{
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 36%;
    height: 568px;
    background-image: url(../pics/works-bg-2.png);
    background-size: 100% 100%;
    background-position: center;
    background-repeat: no-repeat;
    z-index: -1;
}

.bg-3{
    content: '';
    position: absolute;
    top: 20%;
    left: 0;
    width: 23%;
    height: 600px;
    background-image: url(../pics/works-bg-3.png);
    background-size: 100% 100%;
    background-position: center;
    background-repeat: no-repeat;
    z-index: -1;
}

.works-container{
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 15px;
}

.works-title-wrapper{
    width: 100%;
    display: flex;
    justify-content: flex-end;
}
.title{
    width: 45%;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    justify-content: flex-end;
}

.title h2{
    font-family: Microsoft YaHei, Microsoft YaHei;
    font-weight: bold;
    font-size: 40px;
    color: #323566;
    text-align: right;
}

.title p{
    font-family: Microsoft YaHei, Microsoft YaHei;
    font-weight: 400;
    font-size: 20px;
    color: #323566;
    text-align: justified;
    text-indent: 2em;
}


.works-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 70px;
    row-gap: 100px;
    padding: 40px 0;
}

.work-item {
    background: rgba(243,243,243,0.5);
    border-radius: 20px;
    /* overflow: hidden; */
    box-shadow: 0px 0px 10px 0px rgba(0,0,0,0.15);
    transition: all 0.3s ease;
    cursor: pointer;
    padding: 25px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    position: relative;
    z-index: 2;
    min-height: 436px;
}

.work-item:hover {
    padding: 0;
    z-index: 10;
}

.work-item:hover .type-box{
   opacity: 0;
}

.type-box{
    position: absolute;
    top: 30px;
    left: -37px;
    width: 45px;
    height: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-image: url(../pics/type-box-bg-1.png);
    background-size: 100% 100%; 
    background-position: center;
    background-repeat: no-repeat;
    z-index: 1;
}
/* .type-box-2{
    background-image: url(../pics/type-box-bg-2.png);
} */
.type-box-txt{
    transform: rotate(90deg);
    transform-origin: center center; 
    white-space: nowrap; 
    font-family: Microsoft YaHei, Microsoft YaHei;
    font-weight: bold;
    font-size: 14px;
    color: #FFFFFF;
    text-align: center;
    margin: 0;
}
.type-box-2 .type-box-txt{
    letter-spacing: 0.4em;
}

.works-logo{
    width: 100%; 
    height: 60px; 
    margin: 55px 0;  
    display: flex;  
    align-items: center;  
    justify-content: center;  
}

.works-logo img{
    max-width: 100%;  
    max-height: 100%;  
    width: auto;  
    height: auto;  
    object-fit: contain;  
}

.work-image {
    width: 100%;
    overflow: hidden;
}

.work-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 0.3s ease;
    border-radius: 15px;
}


.work-info {
    margin-top: 20px;
}


.work-info p {
    font-family: Microsoft YaHei, Microsoft YaHei;
    font-weight: bold;
    font-size: 20px;
    color: #1D2D5E;
    text-align: center;
}

.hover-item{
    display: none;
    position: absolute;
    width: 380px;  /* 更大的寬度 */
    background: #FFFFFF;
    border-radius: 30px;
    padding: 50px 25px 0 25px;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    z-index: 20;
    background-image: url(../pics/blue-bg.png);
    background-size: 100% 100%;
    background-position: center;
    box-shadow: 0px 0px 20px 0px rgba(0,0,0,0.35);

    transform: translate(-50%, -50%) scale(0.9); /* 初始缩小 */
    opacity: 0; /* 初始透明 */
    transition: all 0.4s ease-out; /* 平滑过渡 */
}

.hover-item h3{
    font-family: Microsoft YaHei, Microsoft YaHei;
    font-weight: bold;
    font-size: 20px;
    color: #FFFFFF;
    text-align: left;

    margin-top: 40px;
}

.hover-item p{
    font-family: Microsoft YaHei, Microsoft YaHei;
    font-weight: 300;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.8);
    text-align: justified;
    margin: 10px 0;
}

.hover-item img{
    max-width: 100%;
    height: auto;
    width: 100%;
}

.detail-btn{
    position: absolute;
    bottom: 5%;
    left: 50%;
    transform: translateX(-50%);
    box-shadow: 0px 0px 10px 0px rgba(0,0,0,0.25);
    background: rgba(29,45,94,0.4);
    border-radius: 40px;
    padding: 8px 20px;
    backdrop-filter: blur(2px);

    opacity: 0; /* 初始透明 */
    transition: all 0.3s ease-out 0.1s; /* 延迟0.2秒触发 */
}

.detail-btn a{
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;

    font-family: Microsoft YaHei, Microsoft YaHei;
    font-weight: bold;
    font-size: 15px;
    color: #FFFFFF;
    text-align: center;
    letter-spacing: 0.1em;
}

.detail-btn a:hover{
    color: #FFFFFF;
}

.detail-btn a img{
    width: 18px;
    height: 18px;
}

.hover-logo {
    position: absolute;
    top: 15px;
    /* left: 25px; */
    display: flex;
    align-items: center;
    justify-content: flex-start;
    height: 40px;
    width: 35%;

    left: -10%; /* 初始在容器外 */
    opacity: 0; /* 初始透明 */
    transition: all 0.3s ease-out 0.1s; /* 延迟0.2秒触发 */
}

.hover-logo img {
    max-width: 100%;  
    max-height: 100%;  
    width: auto;  
    height: auto;  
    object-fit: contain; 
}

.hover-type {
   position: absolute;
   top: 33px;
   /* right: 40px; */
   font-size: 22px;
    color: #FFFFFF;
    font-weight: bold;
    font-family: Microsoft YaHei, Microsoft YaHei;

    right: -10%; /* 初始在容器外 */
    opacity: 0; /* 初始透明 */
    transition: all 0.3s ease-out 0.1s; /* 延迟0.2秒触发 */
}
.hover-type-2{
    /* right: 60px; */
    letter-spacing: 0.1em;
}

.work-item:hover .hover-item{
    display: block;
    opacity: 1; /* 淡入 */
    transform: translate(-50%, -50%) scale(1); /* 放大至正常 */
}

.work-item:hover .work-image{
    display: none;
}
.work-item:hover .work-info{
    display: none;
}
.work-item:hover .works-logo{
    margin: 0;
    display: none;
}
/* 悬停时 hover-logo 滑入 */
.hover-item:hover .hover-logo {
    left: 25px; /* 移动到顶部 */
    opacity: 1;
    z-index: 30;
}

.hover-item:hover .detail-btn{
    opacity: 1;
}

.hover-item:hover .hover-type{
    right: 40px;
    opacity: 1;
}   

.hover-item:hover .hover-type-2{
    right: 60px;
    opacity: 1;
}

.more-tips{
    margin-top: 50px;
}
.more-tips p{
    font-family: Microsoft YaHei, Microsoft YaHei;
    font-weight: bold;
    font-size: 20px;
    color: #1D2D5E;
    text-align: center;
}

.mb{
    display: none;
}

@media (min-width: 1168px) {
.works-section {
    padding: 290px 0 100px 0;
    margin-top: -200px;
}

}


/* 響應式調整 */
@media (max-width: 768px) {
    .works-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
        gap: 20px;
        padding: 20px 0;
    }

    .works-container{
        display: none;
    }
    .works-container.mb{
        display: block;
        padding: 0 30px;
    }

    .works-item-mobile{
        margin: 30px 0;
        position: relative;
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 10px;
        background-image: url(../pics/works-item-bg.png);
        background-size: 100% 100%;
        background-position: center;
        background-repeat: no-repeat;
        border-radius: 20px;
        box-shadow: 0px 0px 10px 0px rgba(0,0,0,0.15);
        transition: all 0.3s ease;

    }

    .mobile-img img{
        border-radius: 15px;
    }

    .works-item-mobile.image-loaded {
        opacity: 1;
      }

    .works-item-mobile:hover{
        transform: translateY(-10px) scale(1.05);
    }

    .mobile-content{
        width: 70%;
        position: absolute;
        bottom: 0px;
        left: 0px;
        /* background: rgba(241,245,255,0.5); */
        box-shadow: 0px 0px 10px 0px rgba(0,0,0,0.15);
        border-radius: 0px 20px 0px 20px;
        padding: 23px 30px;
        backdrop-filter: blur(8px);
        border-image: linear-gradient(180deg, rgba(188, 197, 234, 1), rgba(255, 255, 255, 1), rgba(191, 196, 209, 1)) 1 1;
    
        font-family: Microsoft YaHei, Microsoft YaHei;
        font-weight: bold;
        font-size: 15px;
        color: #1D2D5E;
        letter-spacing: 1px;
        text-align: center;

        background-image: url(../pics/white-bg-item.png);
        background-size: cover;
        background-position: center;
        background-repeat: no-repeat;
    }


    .more-tips p{
        font-size: 16px;
    }

    .works-section{
        padding: 100px 0;
    }

    /* .bg-1,.bg-2,.bg-3{
        display: none;
    } */

    .bg-1{
        left: -50%;
        width: 90%;
        height: 200px;
    }

    .bg-2{
        right: -25%;
        width: 60%;
        height: 300px;
    }

    .bg-3{
        top: 50%;
        left: -10%;
        width: 50%;
        height: 400px;
    }
}
