﻿/* 定义跳跃动画 */
@keyframes jump {
    0% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-5px); /* 跳跃的高度 */
    }
    100% {
        transform: translateY(0);
    }
}

/* 应用动画到导航链接 */
.navbar-nav .nav-link:hover {
    animation: jump 0.5s ease; /* 动画持续时间和缓动效果 */
}

/* 设置下划线效果 */
.nav-item-hover-effect .nav-link {
    position: relative;
    text-decoration: none;
    color: inherit; /* 确保链接颜色与父元素一致 */
}

.nav-item-hover-effect .nav-link::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background-color: #ff0000; /* 下划线颜色 */
    transition: width 0.3s ease, left 0.3s ease;
}

.nav-item-hover-effect .nav-link:hover::before,
.nav-item-hover-effect .nav-link.active::before {
    width: 100%;
    left: 0;
}

/* 自定义样式 */
body {
    font-family: "Helvetica Neue", Helvetica, Arial, Tahoma, "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", "Heiti SC", "WenQuanYi Micro Hei", sans-serif;
    margin: 0;
    padding: 0;
}

.swiper {
    width: 100%;
    height: 100vh;
}

.swiper-slide {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100vh;
}

.swiper-container-inner {
    width: 100%;
    height: 300px;
}

.swiper-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* 右边淡入动画 */
.fade-in-right {
    opacity: 0;
    transform: translateX(50%);
    animation: opacity 0.5s ease-in-out, transform 0.5s ease-in-out;
}

.swiper-slide-active .fade-in-right {
    animation: fadeInRight 2s ease forwards;
}

@keyframes fadeInRight {
    from {
        opactiy: 0;
        transform: translateX(50%);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/*.fade-in-right:nth-of-type(2) {*/
/*    animation-delay: 2s;*/
/*}*/

/* 左边淡入动画 */
.fade-in-left {
    opacity: 0;
    transform: translateX(50%);
    animation: opacity 0.5s ease-in-out, transform 0.5s ease-in-out;
}

.swiper-slide-active .fade-in-left {
    animation: fadeInLeft 2s ease forwards;
}

@keyframes fadeInLeft {
    from {
        opactiy: 0;
        transform: translateX(-50%);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}


/*下方淡入动画*/
.fade-in-end {
    opacity: 0;
    transform: translateY(50%);
    animation: opacity 2s ease, transform 2s ease;
}

.swiper-slide-active .fade-in-end {
    animation: fadeInEnd 2s ease forwards;
}

@keyframes fadeInEnd {
    from {
        opacity: 0;
        transform: translateY(100%);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.background-image-style {
    background-image: url('../assets/img/banner01.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    min-height: 100vh;
}

.about-us-bg-img {
    background-image: url('../assets/img/aboutus-bg-img.png');
    background-size: cover;
    background-position: left;
    background-repeat: no-repeat;
    min-height: 100vh;
}

.slide-in {
    opacity: 0;
    transform: translateX(100%);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.slide-in.active {
    opacity: 1;
    transform: translateX(0);
}

.first-line-indent {
    text-indent: 2em;
}

.font-style {
    font-size: 48px;
}

/*鼠标划过效果*/
.hovereffect {
    float: left;
    overflow: hidden;
    position: relative;
    text-align: center;
    cursor: default;
}

.hovereffect .overlay {
    width: 100%;
    height: 100%;
    position: absolute;
    overflow: hidden;
    top: 0;
    left: 0;
    -webkit-transition: all 0.4s ease-in-out;
    transition: all 0.4s ease-in-out;
}

.hovereffect:hover .overlay {
    background-color: rgba(246, 168, 89, 0.4);
}

.hovereffect img {
    height: 100%;
    width: auto;
    display: block;
    position: relative;
    -webkit-transform: scale(1.1);
    -ms-transform: scale(1.1);
    transform: scale(1.1);
    -webkit-transition: all .4s linear;
    transition: all .4s linear;
}

.hovereffect:hover img {
    -webkit-transform: scale(1);
    -ms-transform: scale(1);
    transform: scale(1);
}

.hovereffect a.info {
    display: inline-block;
    text-decoration: none;
    text-transform: uppercase;
    color: #000;
    border: 1px solid #fff;
    box-shadow: 0 0 3px #fff;
    margin: 20% auto;
    background-color: transparent;
    opacity: 0;
    filter: alpha(opacity=0);
    -ms-transform: scale(1.5);
    transform: scale(1.5);
    -webkit-transition: all 0.4s ease-in-out;
    transition: all 0.4s ease-in-out;
    height: 45%;
    width: 85%;
    position: absolute;
    top: 10%;
    left: 8%;
    padding: 20%;
}

.hovereffect:hover a.info {
    opacity: 1;
    filter: alpha(opacity=100);
    -webkit-transform: scale(1);
    -ms-transform: scale(1);
    transform: scale(1);
    background-color: rgba(224, 242, 206, 0.4);
}

/* banner图片逐渐变小效果 */
/* 初始状态 */
.scale-image-effect img {
    transform: scale(1.2);
    will-change: transform; /* 提示浏览器提前准备好动画 */
}

/* 动画效果 */
@keyframes scale-image {
    0% {
        transform: scale(1.2);
    }
    100% {
        transform: scale(1);
    }
}

/* 动态添加的动画类 */
.animate-scale img {
    animation: scale-image 12s linear;
}

/* 背景居中变色 */
.swiper-slide.slide-half-bg {
    background: linear-gradient(to bottom, white 50%, #260404 50%);
}

.mt-6 {
    margin-top: 6rem;
}

.footer-font-style {
    color: #d8d8d8;
    text-decoration: none;
}

.footer-font-style:hover {
    color: #fff;
}

.footer-info-style {
    font-size: 8px;
    color: #c0c0c0;
}

.footer-info-style a {
    color: #c0c0c0;
    text-decoration: none;
}

.footer-info-style a:hover {
    color: #fff;
    text-decoration: underline;
}

.products-nav-style:hover {
    color: #0041a0;
    text-decoration: underline;
}

.product_hover_effect {
    width: 100%;
    height: 100%;
    float: left;
    overflow: hidden;
    position: relative;
    text-align: center;
    cursor: default;
    border-radius: 0.5rem;
    transition: all .3s ease;
}

.product_hover_effect .overlay {
    width: 100%;
    height: 100%;
    position: absolute;
    overflow: hidden;
    top: 0;
    left: 0;
    opacity: 0;
    background-color: rgba(0, 0, 0, 0.5);
    -webkit-transition: all .4s ease-in-out;
    transition: all .4s ease-in-out

}

.product_hover_effect img {
    position: relative;
    -webkit-transition: all .4s linear;
    transition: all .4s linear;

}

.product_hover_effect h2 {
    text-transform: uppercase;
    color: #fff;
    text-align: center;
    position: relative;
    font-size: 24px;
    background: rgba(0, 0, 0, 0.5);
    -ms-transform: translatey(-100px);
    transform: translatey(-100px);
    -webkit-transition: all .2s ease-in-out;
    transition: all .2s ease-in-out;
    padding: 10px;
}

.product_hover_effect p {
    color: #fff;
    text-align: center;
    position: relative;
    font-size: 16px;
    background: rgba(0, 0, 0, 0.5);
    -webkit-transition: all .2s ease-in-out;
    transition: all .2s ease-in-out;
    padding: 5px;
}

.product_hover_effect a.info {
    text-decoration: none;
    display: inline-block;
    text-transform: uppercase;
    color: #fff;
    border: 1px solid #fff;
    background-color: transparent;
    opacity: 0;
    filter: alpha(opacity=0);
    -webkit-transition: all .2s ease-in-out;
    transition: all .2s ease-in-out;
    padding: 7px 14px;
}

.product_hover_effect:hover {
    box-shadow: 0 0 15px rgba(248, 167, 167, 0.5);
}

.product_hover_effect a.info:hover {
    box-shadow: 0 0 5px #fff;
}

.product_hover_effect:hover img {
    -ms-transform: scale(1.2);
    transform: scale(1.2);

}

.product_hover_effect:hover .overlay {
    opacity: 1;
    filter: alpha(opacity=100);

}

.product_hover_effect:hover h2, .product_hover_effect:hover a.info {
    opacity: 1;
    filter: alpha(opacity=100);
    -ms-transform: translatey(0);
    transform: translatey(0);
}

.product_hover_effect:hover a.info {
    -webkit-transition-delay: .1s;
    transition-delay: .1s;
}

.hover-effect {
    width: 100%;
    -webkit-backface-visibility: hidden;
    transform: translateY(0);
    transition: all .3s ease;
}

.hover-effect:hover {
    transform: translateY(-.2rem);
    box-shadow: 0 0 15px rgba(248, 167, 167, 0.5);
}

.alert-floating {
    position: fixed;
    top: 90px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1050; /* 确保它在其他内容之上 */
    text-align: center; /* 确保文本居中 */
}

/* 首行缩进 */
.text-indent {
    text-indent: 2em;
}