I have a somewhat complicated DAG that looks like this:
where Y is the outcome variable. To give some context, X and Y could be two diseases with X being the precursor to disease Y. A is age, and B is treatment. Age affects both (1) how likely a person is to take the treatment, (2) how likely a person is to suffer from disease X, and (3) how likely disease X will progress to disease Y (an effect modifier). Treatment B affects both (1) how likely the person being treated will suffer from disease X and also (2) how likely disease X will progress to disease Y (an effect modifier).
The question I am interested in answering is (1) what is the effect of treatment B on the risk of getting disease X, and (2) how does treatment B affect the risk of disease X progressing into disease Y (the two red arrows).
What is the correct strategy in estimating these two effects?