What do these calories mean?

I just got the Fenix 7 this week. Can someone explain the calorie calculations to me?  How does it get my resting calories and how does it calculate what it thinks my active calorie burn rate is? The pics below show Calorie details for today and one of my rounds of DG.

Thanks in advance!