@font-face {
    font-family: AlibabaPuHui;
    src: url('/static/font/AlibabaPuHuiTi-3-55-Regular.ttf')
}

@font-face {
    font-family: HarmonyOSSansSCBold;
    src: url('/static/font/HarmonyOS_Sans_SC_Bold.ttf')
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: AlibabaPuHui;
}

:root {
    --primary: rgb(254, 197, 1);
    --secondary: #7ECEFD;
    --accent: #FFC36B;
    --dark: rgba(28, 28, 28, 0.95);
    --light: #FFFFFF;
    --gray: #F5F5F5;
    --background-color: rgba(28, 28, 28, 0.7);
}

body {
    color: var(--dark);
    background-color: var(--light);
    overflow-x: hidden;
}

/* 导航栏样式 */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 1.2rem 5%;
    /*background-color: var(--background-color);*/
    z-index: 1000;
    transition: all 0.3s ease;
    height: 6rem;

}

nav:hover {
    background-color: var(--background-color);
}

.nav-scrolled {
    padding: 0.8rem 5%;
    background-color: var(--background-color);

}

.logo {
    width: 7.344vw;
    height: 3.292vw;
    display: block;
    background: url(/static/image/logo.png) center;
    background-size: 100%;
    /*margin-left: -15.312vw;*/
    object-fit: cover;
}

.logo i {
    margin-right: 0.5rem;
    font-size: 2.2rem;
}

.nav-links {
    display: flex;
    list-style: none;
}

.nav-links li {
    margin: 0 1.2rem;
}

.nav-links a {
    text-decoration: none;
    color: #feedef;
    font-size: 18px;
    position: relative;
    padding: 0.5rem 0;
    transition: color 0.3s;
    letter-spacing: -1px;
    line-height: 17px;
}

.nav-links a:hover, .nav-links a.active {
    color: var(--primary);
}

.nav-links a.active {
    color: var(--primary);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    /*background-color: var(--primary);*/
    transition: width 0.3s ease;
}

.nav-links a:hover::after, .nav-links a.active::after {
    width: 100%;
}

.nav-actions {
    display: flex;
    align-items: center;
}

.nav-actions i {
    font-size: 1.4rem;
    margin-left: 1.5rem;
    cursor: pointer;
    color: var(--dark);
    transition: color 0.3s;
}

.nav-actions i:hover {
    color: var(--primary);
}

.menu-toggle {
    display: none;
}

/* 页面标题 */
.page-header {
    /*margin: 80px auto 0;*/
    padding: 5rem 5%;
    text-align: center;
    /*background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);*/
    color: white;
    position: relative;
    overflow: hidden;
    height: 58rem;
    background-image: url("/static/image/productsSeries/1-1.png");
    background-size: cover;
}

.page-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(0, 0, 0, 0.3), rgba(0, 0, 0, 0.3));
    opacity: 0.15;
}

.page-header h1 {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    position: relative;
}

.page-header p {
    font-size: 1.3rem;
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.6;
    position: relative;
}

/* 产品分类导航 - 横向轮播样式 */
.product-categories {
    padding: 3.3rem 5%;
    z-index: 200;
    transition: all 0.4s ease;
    position: relative;
    left: 0;
    right: 0;
}

.product-categories-scrolled {
    top: 60px;
}

.categories-carousel-container {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    overflow: hidden;
}

.categories-container {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    display: grid;
    justify-content: center;
    transition: all 0.4s ease;
    padding: 0 40px;
    align-items: center;
}

.category-btn {
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    background: none;
    border: none;
    margin: 0 30px;
    cursor: pointer;
    transition: all 0.3s ease;
    opacity: 0.7;
    /*width: 90px;*/
    flex-shrink: 0;
    flex-direction: column;
    justify-content: flex-end;
    align-items: center;
}

.category-btn:hover {
    opacity: 1;
    transform: translateY(-5px);
}

.category-btn.active {
    opacity: 1;
    transform: translateY(-5px);
}

.icon-container {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 12px;
    margin-top: 20px;
    /*background: linear-gradient(135deg, #BF2229 0%, #ff0000 100%);*/
    /*box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);*/
    transition: all 0.3s ease;
}

.category-btn.active .icon-container {
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.2);
    transform: scale(1.1);
    background: linear-gradient(135deg, #ff0000 0%, #BF2229 100%);
}

.category-btn i {
    font-size: 28px;
    color: white;
}

.category-btn img{
        width: 100%;
    object-fit: cover;
    height: 100%;
}
.category-name {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 2rem auto;
    color: var(--light);
    background-color: #000000;
    width: 70%;
}

/* 导航轮播控制按钮 */
.category-scroll-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(255, 255, 255, 0.9);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    color: #333;
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.category-scroll-btn:hover {
    background-color: var(--primary);
    color: white;
    transform: translateY(-50%) scale(1.1);
}

.category-scroll-btn.left {
    left: 0;
}

.category-scroll-btn.right {
    right: 0;
}

/* 产品部分通用样式 */
.product-section {
    padding: 0 5%;
    display: none;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.product-section.active {
    display: block;
    opacity: 1;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.section-title {
    font-size: 2.8rem;
    text-align: center;
    margin-bottom: 3rem;
    color: var(--dark);
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background-color: var(--primary);
    border-radius: 2px;
}

/* 产品卡片样式 */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.product-card {
    background-color: white;
    /*border-radius: 12px;*/
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s, box-shadow 0.3s;
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.product-img {
    /*height: 350px;*/
    overflow: hidden;
}

.product-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

#poster .product-img {
    height: 700px;
    overflow: hidden;
}

.product-card:hover .product-img img {
    transform: scale(1.1);
}

.product-info {
    padding: 1.5rem;
}

.product-info h3 {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    text-align: center;
}

.product-info p {
    color: #666;
    margin-bottom: 1rem;
    text-align: center;
}

.product-price {
    font-weight: bold;
    font-size: 1.2rem;
    color: var(--primary);
}

/* 页脚 */
footer {
    background-color: var(--dark);
    color: white;
    padding: 4rem 5% 2rem;
}


.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.footer-column {
    padding: 0 2rem 0 2rem;
    margin-bottom: 3rem;
}

.footer-column h3 {
    font-size: 1.4rem;
    margin-bottom: 1.5rem;
    position: relative;
    padding-bottom: 0.5rem;
    padding-top: 4rem;
}

.footer-column h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 3px;
    background-color: var(--primary);
}

.footer-column p {
    line-height: 1.6;
    margin-bottom: 1rem;
    color: #ccc;
    font-size: 0.8rem;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.8rem;
}

.footer-links a {
    color: #ccc;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: var(--primary);
}

.social-icons {
    display: flex;
    margin-top: 1.5rem;
}

.social-icons a {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #444;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-right: 1rem;
    color: white;
    text-decoration: none;
    transition: all 0.3s;
}

.social-icons a:hover {
    background-color: var(--primary);
    transform: translateY(-3px);
}

.footer-bottom {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #444;
    text-align: center;
    color: #999;
}

.footer-column a {
    text-decoration: none;
    outline: none;
    color: var(--light)
}

/* 响应式设计 */
@media (max-width: 992px) {
    .categories-container {
        flex-wrap: wrap;
        gap: 1rem;
    }

    .category-btn {
        padding: 0.6rem 1.5rem;
        font-size: 1rem;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
    }

    .menu-toggle {
        display: block;
        font-size: 1.5rem;
        cursor: pointer;
    }

    .page-header h1 {
        font-size: 2.5rem;
    }

    .section-title {
        font-size: 2.2rem;
    }

    .category-scroll-btn {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }

    .category-btn {
        width: 70px;
        margin: 0 10px;
    }

    .icon-container {
        width: 50px;
        height: 50px;
    }

    .category-btn i {
        font-size: 22px;
    }
}

@media (max-width: 576px) {
    .page-header h1 {
        font-size: 2rem;
    }

    .section-title {
        font-size: 1.8rem;
    }

    .categories-container {
        flex-direction: column;
        align-items: center;
    }

    .category-btn {
        width: 200px;
        text-align: center;
        margin: 10px 0;
    }

    .product-categories {
        position: relative;
        bottom: 0;
    }

    .page-header {
        height: auto;
        padding-bottom: 10rem;
    }
}