Preheat the oven to 350°F. Spray a 9x13-inch baking pan with cooking spray.
In a medium bowl, whisk together the gluten-free flour, cocoa powder, baking soda, baking powder and salt.
In the bowl of a stand mixer, or using a hand mixer, beat together sugar, oil, eggs, sour cream, buttermilk and vanilla on medium-high speed until well-combined.
With the mixer running on low, slowly add the dry ingredients in 3 additions, mixing after each addition.
Slowly pour in the hot water. Mix on medium speed for 2-3 minutes, scraping down the sides halfway through, until smooth and incorporated.
Pour the batter into the prepared pan. Bake for 35-40 minutes, until a toothpick inserted into the center of the cake comes out clean. Allow the cake to cool completely before frosting.
For the frosting: In the bowl of a stand mixer, or using a hand mixer, beat the butter on medium-high speed until creamy, about 2 minutes. Add 3 cups powdered sugar along with the cocoa powder, cream/milk, vanilla extract, almond extract and salt. Mix on low speed for 30 seconds, then increase to medium-high speed and whip for a full 2 minutes.
If the frosting is too thick, add a little more cream/milk. If the frosting is too thin, add more powdered sugar to get a spreadable consistency. Frost the cake as desired.