Preheat the oven to 350°F (175°C) and line two baking sheets with parchment paper.
Pulse the pistachios in a food processor until they are finely ground, almost forming a paste, then set aside.
In a medium bowl, whisk together the flour, baking powder, baking soda, and salt, and set aside.
In a large bowl, use a hand mixer (or a stand mixer with a paddle attachment) to cream the butter, brown sugar, and granulated sugar on high speed for 2-3 minutes until light and fluffy.
Add the egg yolks, vanilla extract, and ground pistachios to the creamed butter mixture, mixing on medium speed for 1-2 minutes until the mixture turns pale and fluffy. Scrape down the bowl as needed.
Gradually add the dry ingredients to the wet mixture, mixing on low speed until just combined.
Fold in the chopped dark chocolate and roughly chopped pistachios with a spatula.
Scoop the dough using a cookie scoop (about 2 tablespoons per cookie) and place them 2 inches apart on the prepared baking sheets.
Bake for 10-12 minutes, depending on your desired cookie texture (10 minutes for chewy cookies, 12 for a crispier texture).
Let the cookies rest on the baking sheet for 5 minutes, then transfer them to a wire rack to cool completely.
While the cookies are cooling, you can gently press additional chocolate chunks, chopped pistachios, and a sprinkle of flaky sea salt onto each cookie for extra texture and flavor. Use a large round cookie cutter to shape the cookies while they’re still warm for a more uniform look.