Turn the oven on to 325 degrees. Using a nonstick spray, coat a 9-by-13-inch baking dish. Place aside.
Cream the butter, granulated sugar, and powdered sugar together for 2 minutes in the bowl of a stand mixer fitted with the paddle attachment. Mix in the vanilla extract thoroughly. To make a soft dough, add the flour while the mixer is on low speed and mix until combined.
Spread out a third of the dough at the bottom of the dish. Don't worry about the leftover dough; just wrap it in plastic and put it in the fridge.
Bake till the edges are light gold, 20 minutes. Then, put the dish on a cooling rack and wait for 15 minutes.
For the Filling:
Make the caramel filling while the bottom crust bakes and the leftover dough rest in the fridge. Unwrap the caramels and place them in a microwave-safe dish. Pour in the milk/cream. Put in the microwave and heat for a full minute at the highest setting. Take it out of the microwave and whisk it until it's completely smooth. If the caramels are not entirely melted, microwave in 30-second increments on high, stirring after each interval, until smooth.
Stir in half a teaspoon of vanilla extract once the caramel has melted.
Once the crust has cooled, pour the caramel filling on top. Sprinkle the salt on the caramel layer now if desired.
Take the leftover dough from the fridge and crumble it all over the caramel.
Put the dish back in the oven and bake for another 25-30 minutes, until the filling is bubbling and the shortbread topping is firm and faintly brown.
Wait until thoroughly cooled, then cut into squares.
Notes
This can be kept for up to 5 days if stored properly.How To Make it Gluten freeSubstitute regular flour with gluten-free all-purpose baking flour such as Bob's Red Mill.