Heat butter in a small saucepan over medium heat, stirring occasionally, until melted and brown solids begin to form, 5 to 8 minutes. Remove from heat and set aside to cool slightly.
Whisk gluten-free flour, almond flour, baking powder, baking soda and 1/2 teaspoon salt in a medium bowl; set aside.
Whisk butter, brown sugar and granulated sugar in a large bowl until combined. Add eggs, one at a time, whisking until smooth. Whisk in vanilla.
Fold the dry ingredients into the wet ingredients a third at a time until fully incorporated. Fold in chocolate.
Scoop dough into 1 1/2 tablespoon balls onto a parchment paper- or silicone baking mat-lined baking sheet. Sprinkle with flaky sea salt, if desired. Cover with plastic wrap and refrigerate until firm, at least 1 hour and up to overnight (you can also transfer them to a zip top bag at this point and stash in the freezer to bake whenever a craving strikes).
When you're ready to bake: Preheat oven to 350°F. Line another baking sheet with parchment paper or a silicone baking mat.
Place the dough balls at least two inches apart on the sheet and bake, in batches, until brown around the edges, about 14 minutes. If the cookies are too puffy for your preference when you remove them from the oven, immediately “bang” the pan once or twice on the stovetop or other heat-proof surface to flatten lightly.