Underpayment penalty for uneven capital gains

I am working on the Annualized Income Method for calculating underpayment. I am confused with what TT is asking. It first asks to enter in my AGI over the 4 quarters (which includes Capital Gains).

 

Then the next question it asks is what my (LT/ST) Capital Gains were over those 4 periods. I know it's asking for because the taxes are different for capital gains... but it's also included in the AGI, so is it going to double count the income (AGI+Capital Gains) for penalty calculations?