flowchart TD
    %% ======== 样式定义 ========
    classDef roleHR fill:#fff7e6,stroke:#fa8c16,stroke-width:1px;
    classDef roleCandidate fill:#e6fffb,stroke:#13c2c2,stroke-width:1px;
    classDef roleSystem fill:#f0f5ff,stroke:#2f54eb,stroke-width:1px;

    %% ======== 开始与结束 ========
    Start([开始])
    End([结束])

    %% ======== HR 泳道 ========
    subgraph HRLane[招聘企业 HR]
        HR1[填写岗位需求<br/>与能力要求]:::roleHR
        HR2[配置试题策略]:::roleHR
        HR3[查看考试统计报表]:::roleHR
        HR4[评价试题质量与效果]:::roleHR
    end

    %% ======== 平台后端 泳道 ========
    subgraph SystemLane[平台后端]
        S1[解析岗位并抽取技能标签]:::roleSystem
        S2[生成试卷模板]:::roleSystem
        S3[为候选人实例化试卷]:::roleSystem
        S4[记录作答过程与答案]:::roleSystem
        S5[自动评分并生成结果]:::roleSystem
        S6[更新题目统计指标]:::roleSystem
        S7[判定题目是否进入淘汰池]:::roleSystem
    end

    %% ======== 应聘者 泳道 ========
    subgraph CandLane[应聘者 Candidate]
        C1[注册 / 登录]:::roleCandidate
        C2[选择岗位并领取试卷]:::roleCandidate
        C3[在线作答]:::roleCandidate
        C4[查看成绩与解析]:::roleCandidate
        C5[填写试题反馈]:::roleCandidate
    end

    %% ======== 活动流转 ========
    Start --> HR1 --> S1 --> S2 --> HR2 --> S3
    S3 --> C1 --> C2 --> C3 --> S4 --> S5 --> C4 --> C5 --> S6
    S6 --> HR3 --> HR4 --> S6
    S6 --> S7 --> End
