Preheat the oven to 350 degrees F. Grease and line two 6-inch round cake pans.
In a large bowl, whisk together the flour, granulated sugar, cocoa powder, baking soda, and salt.
In a separate bowl, mix the buttermilk, vegetable oil, egg, red food coloring, white vinegar, and vanilla extract until smooth.
Pour the wet ingredients into the dry ingredients and stir until just combined. Divide the batter evenly between the prepared pans.
Bake for 22 to 25 minutes, or until a toothpick inserted in the center comes out clean. Let the layers cool in the pans for 10 minutes, then remove to a wire rack to cool completely.
Beat the cream cheese and butter together until creamy. Gradually add the powdered sugar and mix until smooth to make the frosting.
Place one cooled cake layer on a plate. Spread the raspberry preserves over the top. Add the second layer and frost the top and sides with the cream cheese frosting.
Garnish with fresh raspberries before serving.