Preheat the oven to 350°F. Spray a 9×13-inch baking pan with cooking spray. Line with parchment paper if desired.
Make the shortbread crust: In the bowl of a stand mixer, or using a hand mixer, beat the butter until well creamed, about 2 minutes. Add the granulated sugar and brown sugar until mix light and fluffy, about 2-3 minutes.
Add the egg yolk, vanilla extract and salt. Mix until well-combined, scraping down the bottom and sides of the bowl halfway through.
With the mixer running on low, slowly add the gluten-free flour. Mix until just combined.
Press the dough into an even layer into the prepared pan. Bake for 25-27 minutes until golden brown.
Let the shortbread cool completely before topping it with the caramel.
Make the caramel: In a medium saucepan, combine butter, brown sugar, sweetened condensed milk, corn syrup and salt over medium heat.
Whisk constantly until the butter is melted and everything is well-combined. Continue whisking constantly until the mixture starts to boil—this might take a few minutes, but don’t rush by increasing the heat.
Once the mixture reaches a boil, reduce the heat to a simmer and keep stirring. Continue cooking and stirring for about 10-15 minutes, until the caramel turns a rich golden color and thickens. It should start to pull away from the sides of the pan as you stir. If using a candy thermometer, the temperature should reach about 225°F. Remove from heat and stir in vanilla extract.
Pour the caramel over the shortbread crust, using a knife or spatula to spread it evenly if needed.
Allow to cool at room temperature for several hours or in the refrigerator for 1 hour before topping with chocolate.
For the ganache: Place the semi-sweet chocolate in a bowl. Microwave the heavy cream until simmering, about 1 minute. Pour the hot heavy cream over the chocolate and let sit for 30 seconds. Mix until smooth. If the chocolate still isn’t melted, microwave the ganache for 20-second increments at 50% power, stirring after each increment until completely melted and smooth. Pour the chocolate over the caramel and smooth into an even layer.
Chill for at least 1 hour before slicing. Top with flaky salt once the chocolate has set.