/* ========== FAQ 手风琴（丝滑展开版） ========== */

.faq-list {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 0;
}

.faq-item {
    border: 1px solid #ddd;
    border-radius: 6px;
    margin-bottom: 14px;
    overflow: hidden;
    transition: border-color 0.3s;
}

.faq-item:hover {
    border-color: #ea5504;
}

.faq-question {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 18px 20px;
    cursor: pointer;
    user-select: none;
}

.faq-icon {
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    background: transparent;
    border: 1px solid #ccc;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 700;
    color: #ea5504;
    transition: all 0.3s;
}

.faq-question:hover .faq-icon {
    background: #ea5504;
    border-color: #ea5504;
    color: #fff;
}

.faq-question h4 {
    font-size: 18px !important;
    text-align: left !important;
    font-weight: 600;
    color: #222;
    margin: 0;
    flex: 1;
    line-height: 1.5;
}

/* ========== 丝滑动画核心 ========== */
.faq-answer {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 0 20px;
}

/* 内层容器：负责隐藏溢出内容 */
.faq-answer > div {
    overflow: hidden;
    font-size: 15px !important;
    text-align: left !important;
    line-height: 1.8;
    color: #555;
    padding-bottom: 0;
    border-top: 1px solid transparent;
    transition: padding-bottom 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                border-color 0.3s;
}

/* 展开状态 */
.faq-item.active .faq-answer {
    grid-template-rows: 1fr;
}

.faq-item.active .faq-answer > div {
    padding-bottom: 18px;
    border-top-color: #e0e0e0;
    padding-top: 14px;
}

.faq-item.active .faq-icon {
    background: #ea5504;
    border-color: #ea5504;
    color: #fff;
}

/* ========== H5 ========== */
@media (max-width: 768px) {
    .faq-list {
        padding: 12px;
    }

    .faq-item {
        margin-bottom: 10px;
        border-radius: 4px;
    }

    .faq-question {
        padding: 14px 16px;
        gap: 12px;
    }

    .faq-icon {
        width: 24px;
        height: 24px;
        font-size: 16px;
    }

    .faq-question h4 {
        font-size: 16px !important;
    }

    .faq-answer {
        padding: 0 16px;
    }

    .faq-answer > div {
        font-size: 14px !important;
    }

    .faq-item.active .faq-answer > div {
        padding-bottom: 14px;
        padding-top: 12px;
    }
}