Prep your pans and oven: Heat oven to 350°F (175°C). Grease and line two 8-inch round cake pans with parchment on the bottom.
Lightly flour the sides.
Mix the dry ingredients: In a large bowl, whisk flour, cocoa, granulated sugar, brown sugar, baking powder, baking soda, and salt until evenly combined.
Add the wet ingredients: Whisk in eggs, buttermilk, oil, and vanilla until smooth. The batter will be thick.
Thin with hot liquid: Slowly pour in the hot coffee (or water), whisking until the batter is glossy and pourable. Don’t overmix.
Bake: Divide the batter between pans. Bake 28–33 minutes, or until a toothpick comes out with a few moist crumbs.
Cool in pans 10 minutes, then turn out onto racks to cool completely.
Make the raspberry filling: In a small pot, combine raspberries, sugar, lemon juice, and salt over medium heat. Cook, stirring, until the berries break down and release juices, 4–6 minutes. Stir in the cornstarch slurry and simmer 1–2 minutes until thick and jammy.
Cool completely. If you prefer it seedless, press through a fine strainer.
Make the ganache: Place chopped chocolate in a heatproof bowl. Warm cream in a small pot until steaming (not boiling).
Pour over the chocolate and let sit 2 minutes. Add butter and salt, then whisk gently until smooth and glossy. Let cool to a spreadable consistency, about 20–30 minutes. If it gets too firm, warm it briefly over a water bath or in short microwave bursts.
Level and layer: If your cakes domed, trim the tops with a serrated knife.
Place the first layer on a serving plate. Pipe or spread a ring of ganache around the edge to create a dam. Spoon the raspberry filling inside the ring and spread evenly.
Top and crumb coat: Set the second cake layer on top.
Spread a thin layer of ganache over the cake to trap crumbs. Chill 15–20 minutes.
Finish with ganache: Apply the remaining ganache, smoothing the sides and top. For a drip effect, warm the ganache slightly and spoon around the edges before smoothing the top.
Garnish: Top with fresh raspberries.
Add powdered sugar or shaved chocolate if you like. Chill 15 minutes to set, then slice with a warm, clean knife.