Preheat oven to 350°F (175°C) and grease a 9x13 inch baking pan. Line with parchment paper for easy removal.
In a large bowl, whisk together flour, sugar, and salt until evenly distributed.
Cut in cold butter using a pastry cutter or fingers until mixture resembles coarse crumbs with pea-sized pieces.
Add egg yolk and 2 tablespoons ice water, mixing with fork until dough begins to come together. Add more water 1 tablespoon at a time if needed.
Press crust mixture firmly and evenly into bottom of prepared pan. Pre-bake for 15-20 minutes until lightly golden. Remove and cool slightly.
In a medium saucepan, combine blackberries and sugar over medium heat. Cook for 5-7 minutes, stirring frequently, until berries break down and release juices.
Stir in lemon juice and cornstarch. Cook for another 1-2 minutes until mixture thickens and becomes glossy.
Remove from heat and let cool slightly before assembling.
In a separate bowl, whisk together brown sugar, baking powder, and flour for topping.
Cut in cold butter until mixture becomes crumbly.
Mix in egg and vanilla extract until just combined. Do not overmix.
Gently fold in pistachios until distributed throughout the crumbly mixture.
Pour slightly cooled blackberry filling over pre-baked crust, spreading evenly with spatula.
Sprinkle pistachio topping across entire surface, pressing down gently to adhere without squishing filling.
Bake for 30-35 minutes until topping is golden brown and filling is bubbling around edges.
Let bars cool completely in pan for at least 1-2 hours before cutting to allow filling to set properly.