/* ===== Featured Products Carousel ===== */
/* 使用 rem.js 的响应式断点: 620-1024, 1350-3840 */

.featured-carousel {
    padding: 8rem 0;
    background: #f9f9f9;
    overflow: hidden;
}

/* 滚动动画 */
@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(5rem);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* 面板滚动动画 */
.hm-ai-panel {
    opacity: 0;
    transform: translateY(3rem);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.hm-ai-panel.hm-ai-panel__active {
    animation: slideUp 0.6s ease forwards;
}

.hm-ai-panel.hm-ai-panel__active.hm-ai-panel__animated {
    opacity: 1;
    transform: translateY(0);
}

/* 按钮悬停放大效果 */
.hm-ai-tab {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.hm-ai-tab:hover {
    transform: scale(1.08);
    box-shadow: 0 0.8rem 2.5rem rgba(0, 0, 0, 0.15);
}

.hm-ai-tab.is-active {
    transform: scale(1.05);
}

/* 面板图片悬停放大效果 */
.hm-ai-panel__right {
    overflow: hidden;
}

.hm-ai-panel__img {
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.5s ease;
    display: block;
}

.hm-ai-panel__img:hover {
    transform: scale(1.05);
    box-shadow: 0 1rem 3rem rgba(0, 0, 0, 0.2);
}

/* 标题滚动动画 */
.hm-sec-title {
    opacity: 0;
    transform: translateY(-2rem);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.hm-sec-title.hm-sec-title__visible {
    opacity: 1;
    transform: translateY(0);
}

/* 按钮组滚动动画 */
.hm-ai-tabs {
    opacity: 0;
    transform: translateY(2rem);
    transition: opacity 0.8s ease 0.2s, transform 0.8s ease 0.2s;
}

.hm-ai-tabs.hm-ai-tabs__visible {
    opacity: 1;
    transform: translateY(0);
}

/* 面板内容逐个显示动画 */
.hm-ai-panel__left {
    opacity: 0;
    transform: translateX(-3rem);
    transition: opacity 0.6s ease 0.3s, transform 0.6s ease 0.3s;
}

.hm-ai-panel__right {
    opacity: 0;
    transform: translateX(3rem);
    transition: opacity 0.6s ease 0.4s, transform 0.6s ease 0.4s;
}

.hm-ai-panel.hm-ai-panel__active .hm-ai-panel__left,
.hm-ai-panel.hm-ai-panel__active .hm-ai-panel__right {
    opacity: 1;
    transform: translateX(0);
}

.hm-inner {
    max-width: 139.4rem;
    margin: 0 auto;
    box-sizing: border-box;
    padding: 0 4rem;
}

.hm-sec-title {
    margin: 0 0 1rem;
    font-size: 1.8em;
    font-weight: 400;
    color: #000;
    text-align: center;
}

.hm-ai-tabs {
    display: flex;
    flex-wrap: nowrap;
    justify-content: center;
    gap: 1.5rem;
    margin-bottom: 4rem;
    margin-top: 4rem;
}

.hm-ai-tab {
    flex: 1;
    min-width: 16rem;
    max-width: 20rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    padding: 2rem 1.5rem;
    font-size: 1.6rem;
    font-weight: 500;
    color: #000;
    background: #fff;
    border-radius: 1.2rem;
    cursor: pointer;
    transition: background .2s, border-color .2s, color .2s, box-shadow .2s;
    border: 0.2rem solid transparent;
}

.hm-ai-tab:hover,
.hm-ai-tab.is-active {
    border-color: #1677ff;
    box-shadow: 0 0.4rem 1.2rem rgba(22, 119, 255, 0.15);
}

.hm-ai-tab__icon {
    width: 10rem;
    height: 10rem;
    object-fit: contain;
}

.hm-ai-tab__label {
    margin-top: 0.1rem;
}

.hm-ai-panel {
    display: none;
    gap: 4rem;
    background: #fff;
    border-radius: 1.6rem;
    padding: 4rem;
    box-shadow: 0 0.4rem 2rem rgba(0, 0, 0, 0.08);
}

.hm-ai-panel__active {
    display: flex;
}

.hm-ai-panel__left {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.hm-ai-panel__head {
    margin-bottom: 3rem;
}

.hm-ai-panel__ico {
    width: 5rem;
    height: 5rem;
    margin-bottom: 2rem;
}

.hm-ai-panel__h {
    font-size: 3.2rem;
    font-weight: 600;
    color: #000;
    line-height: 1.4;
    margin: 0;
}

.hm-ai-panel__list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.hm-ai-panel__list li {
    padding: 1.2rem 0;
    font-size: 1.6rem;
    color: #666;
    position: relative;
    padding-left: 2.4rem;
}

.hm-ai-panel__list li::before {
    content: '◆';
    position: absolute;
    left: 0;
    color: #1677ff;
}

.hm-ai-panel__right {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hm-ai-panel__img {
    width: 90rem;
    height: auto;
    border-radius: 0.8rem;
}

.hm-ai-tab-mobile-hidden {
    display: block;
}

.hm-ai-panel-mobile-hidden {
    display: none;
}

@media (min-width: 62rem) {
    .hm-ai-panel-mobile-hidden.hm-ai-panel__active {
        display: flex;
    }
}

@media (max-width: 62rem) {
    .hm-ai-tabs {
        flex-wrap: wrap;
        gap: 1rem;
    }

    .hm-ai-tab {
        flex: 1;
        min-width: calc(50% - 0.5rem);
        max-width: none;
        padding: 1.5rem 1rem;
        font-size: 1.4rem;
        gap: 1rem;
    }

    .hm-ai-panel {
        flex-direction: column;
        padding: 2rem;
    }

    .hm-sec-title {
        font-size: 1.5rem;
    }

    .hm-ai-panel__h {
        font-size: 2.4rem;
    }

    .hm-ai-panel__img {
        width: 100%;
        max-width: 78.8rem;
    }

    .hm-ai-tab-mobile-hidden {
        display: none !important;
    }

    .hm-ai-panel-mobile-hidden {
        display: none !important;
    }
}

/* 响应式断点适配 */
/* 断点1: 620px - 1024px */
@media (min-width: 62rem) and (max-width: 102.4rem) {
    .featured-carousel {
        padding: 6rem 0;
    }

    .hm-inner {
        padding: 0 3rem;
    }

    .hm-ai-tab {
        min-width: 14rem;
        max-width: 16rem;
        padding: 1.5rem 1rem;
    }

    .hm-ai-tab__icon {
        width: 8rem;
        height: 8rem;
    }

    .hm-ai-panel {
        padding: 3rem;
        gap: 3rem;
    }

    .hm-ai-panel__h {
        font-size: 2.8rem;
    }

    .hm-ai-panel__img {
        width: 70rem;
    }
}

/* 断点2: 1350px - 3840px */
@media (min-width: 135rem) {
    .featured-carousel {
        padding: 10rem 0;
    }

    .hm-inner {
        padding: 0 5rem;
    }

    .hm-ai-tabs {
        gap: 2rem;
        margin-bottom: 5rem;
        margin-top: 5rem;
    }

    .hm-ai-tab {
        min-width: 18rem;
        max-width: 22rem;
        padding: 2.5rem 2rem;
    }

    .hm-ai-tab__icon {
        width: 12rem;
        height: 12rem;
    }

    .hm-ai-panel {
        padding: 5rem;
        gap: 5rem;
    }

    .hm-ai-panel__h {
        font-size: 3.6rem;
    }

    .hm-ai-panel__img {
        width: 100rem;
    }
}

/* ===== Featured Products Carousel End ===== */