/* ===============================================================
 * 产品详情页 · 常见问题（手风琴）
 *
 * 位置：紧跟「更多产品推荐」（灰底 #f8f8f9）之后、页脚之前，
 * 本块用纯白底，形成灰 → 白 → 黑的三段过渡，不额外加分割线。
 *
 * 视觉沿用 products.page.css 的变量与标题体系：
 * --product-blue #152ad3 / --product-text #1d1d1d / --product-muted #6a7282
 * 容器 1400px，标题复用 .srs-product-heading（居中），列表宽 1040px。
 *
 * 与 FAQ 页（faq.page.css）是两套组件，类名用 srs-pfaq 前缀隔离，
 * 避免同一套 .srs-faq-item 在两个页面各自覆写、互相污染。
 *
 * 1. 区块与标题
 * 2. 列表与细分隔线（方案 A）
 * 3. 问题行
 * 4. 答案面板（含无 JS 降级）
 * 5. 底部咨询行
 * 6. 响应式
 * =============================================================== */

/* ---------------------------------------------------------------
 * 1. 区块与标题
 * --------------------------------------------------------------- */
.srs-product-faq {
    padding: 104px 0 110px;
    background: #fff
}

.srs-product-faq .srs-product-heading h2 {
    font-size: 45px
}

.srs-product-faq .srs-product-heading p {
    width: min(820px, 100%);
    /* 两行引导语用 balance 断行，避免末行只剩一两个字 */
    text-wrap: balance
}

/* ---------------------------------------------------------------
 * 2. 列表与细分隔线（方案 A）
 *
 * 不用卡片：产品页上方已有大量圆角卡片（亮点、特性、场景），
 * FAQ 再用卡片会糊成一片。这里用 1px 分隔线 + 直角 + 展开时
 * 浅蓝底与左侧 3px 蓝条，靠「线」而不是「块」来分条。
 * --------------------------------------------------------------- */
.srs-product-faq__list {
    max-width: 1040px;
    margin: 56px auto 0;
    padding: 0;
    border-top: 1px solid #e5e8ee;
    list-style: none
}

.srs-pfaq-item {
    border-bottom: 1px solid #e5e8ee;
    background: #fff;
    transition: background .25s
}

.srs-pfaq-item:hover {
    background: #fafbfd
}

/* 左侧蓝条用 inset 阴影而不是 border —— 后者会把内容整体推右 3px，
   展开/收起时问题行会横向抖动。 */
.srs-pfaq-item.is-open {
    background: #f5f8ff;
    box-shadow: inset 3px 0 0 0 var(--product-blue)
}

/* ---------------------------------------------------------------
 * 3. 问题行
 *
 * h3 只做语义层级，视觉尺寸交给内部按钮，避免继承正文标题样式。
 * --------------------------------------------------------------- */
.srs-pfaq-item__q {
    margin: 0;
    font-size: inherit;
    font-weight: inherit;
    line-height: inherit
}

.srs-pfaq-item__trigger {
    width: 100%;
    padding: 30px 28px;
    border: 0;
    background: none;
    color: var(--product-text);
    font-family: inherit;
    font-size: 20px;
    font-weight: 600;
    line-height: 1.55;
    text-align: left;
    cursor: pointer;
    display: flex;
    align-items: flex-start;
    gap: 20px;
    transition: color .25s
}

.srs-pfaq-item__trigger:hover,
.srs-pfaq-item.is-open .srs-pfaq-item__trigger {
    color: var(--product-blue)
}

/* 键盘焦点：行内缩 4px，不贴到分隔线上 */
.srs-pfaq-item__trigger:focus-visible {
    outline: 2px solid var(--product-blue);
    outline-offset: -4px
}

.srs-pfaq-item__text {
    flex: 1
}

/* 序号：工业资料感，不抢标题 */
.srs-pfaq-item__no {
    flex: none;
    width: 34px;
    color: #b9c0cd;
    font-size: 15px;
    font-weight: 500;
    font-variant-numeric: tabular-nums;
    line-height: 2.1;
    transition: color .25s
}

.srs-pfaq-item.is-open .srs-pfaq-item__no {
    color: var(--product-blue)
}

/* +/− 图标：两条伪元素，展开时竖线转过 90° 并淡出 */
.srs-pfaq-item__icon {
    position: relative;
    flex: none;
    width: 20px;
    height: 20px;
    margin-top: 4px;
    color: inherit
}

.srs-pfaq-item__icon::before,
.srs-pfaq-item__icon::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    background: currentColor;
    border-radius: 2px;
    transition: transform .3s, opacity .3s
}

.srs-pfaq-item__icon::before {
    width: 18px;
    height: 2px;
    transform: translate(-50%, -50%)
}

.srs-pfaq-item__icon::after {
    width: 2px;
    height: 18px;
    transform: translate(-50%, -50%)
}

.srs-pfaq-item.is-open .srs-pfaq-item__icon::after {
    transform: translate(-50%, -50%) rotate(90deg);
    opacity: 0
}

/* ---------------------------------------------------------------
 * 4. 答案面板
 *
 * 默认（无 .is-js）为展开态，禁用 JS 时全文可读。
 * JS 就绪后 .srs-product-faq__list.is-js 接管：面板收起，高度由脚本写内联值过渡。
 * --------------------------------------------------------------- */
.srs-pfaq-item__a {
    overflow: hidden
}

.srs-product-faq__list.is-js .srs-pfaq-item__a {
    height: 0;
    transition: height .3s ease
}

/* 首帧禁用过渡：脚本写入初始 height:0 时过渡已生效，
   不压掉的话载入瞬间会看到全部答案「收起」一次。脚本下一帧移除本类。 */
.srs-product-faq__list.is-init .srs-pfaq-item__a {
    transition: none
}

/* 左内边距 82px = 序号 34 + gap 20 + 行内 28，答案与问题正文左缘对齐 */
.srs-pfaq-item__inner {
    max-width: 860px;
    padding: 0 28px 32px 82px;
    color: #4b5565;
    font-size: 16px;
    line-height: 1.75
}

.srs-pfaq-item__inner> :first-child {
    margin-top: 0
}

.srs-pfaq-item__inner> :last-child {
    margin-bottom: 0
}

.srs-pfaq-item__inner p {
    margin: 0 0 12px
}

.srs-pfaq-item__inner ul,
.srs-pfaq-item__inner ol {
    margin: 0 0 12px;
    padding-left: 22px
}

.srs-pfaq-item__inner li {
    margin: 0 0 6px
}

.srs-pfaq-item__inner strong {
    color: #0a0a0a;
    font-weight: 600
}

.srs-pfaq-item__inner a {
    color: var(--product-blue);
    text-decoration: underline;
    text-underline-offset: 3px
}

/* ---------------------------------------------------------------
 * 5. 底部咨询行
 * --------------------------------------------------------------- */
.srs-product-faq__foot {
    max-width: 1040px;
    margin: 36px auto 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap
}

.srs-product-faq__foot p {
    margin: 0;
    color: var(--product-muted);
    font-size: 16px
}

.srs-product-faq__foot a {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: var(--product-blue);
    font-size: 17px;
    font-weight: 500;
    text-decoration: none
}

.srs-product-faq__foot a span {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: var(--product-blue);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: transform .25s
}

.srs-product-faq__foot a:hover span {
    transform: translateX(4px)
}

.srs-product-faq__foot a span img {
    width: 14px
}

/* ---------------------------------------------------------------
 * 6. 响应式（断点对齐 products.page.css 第 7 节）
 * --------------------------------------------------------------- */
@media (max-width:1440px) {
    .srs-product-faq .srs-product-heading h2 {
        font-size: 36px
    }

    .srs-product-faq .srs-product-heading p {
        font-size: 18px
    }

    .srs-pfaq-item__trigger {
        padding: 26px 24px;
        font-size: 18px
    }

    .srs-pfaq-item__inner {
        padding: 0 24px 26px 72px
    }
}

@media (max-width:1024px) {
    .srs-product-faq {
        padding: 80px 0 90px
    }

    .srs-product-faq__list {
        margin-top: 44px
    }

    .srs-product-faq__foot {
        justify-content: flex-start
    }
}

@media (max-width:768px) {
    .srs-product-faq {
        padding: 60px 0 70px
    }

    .srs-product-faq .srs-product-heading h2 {
        font-size: 28px
    }

    .srs-product-faq .srs-product-heading p {
        font-size: 15px;
        line-height: 1.7
    }

    .srs-product-faq__list {
        margin-top: 32px
    }

    .srs-pfaq-item__trigger {
        /* 12px 而不是 2px：展开时的左侧蓝条会压住文字首字 */
        padding: 20px 12px;
        gap: 12px;
        font-size: 17px
    }

    /* 窄屏去掉序号：只剩 300px 时，序号会把问题挤成三行 */
    .srs-pfaq-item__no {
        display: none
    }

    .srs-pfaq-item__icon {
        width: 16px;
        height: 16px;
        margin-top: 5px
    }

    .srs-pfaq-item__icon::before {
        width: 14px
    }

    .srs-pfaq-item__icon::after {
        height: 14px
    }

    .srs-pfaq-item__inner {
        padding: 0 12px 22px;
        font-size: 15px
    }

    .srs-product-faq__foot {
        margin-top: 28px
    }
}
