Place the shrimp in the prepared baking dish in an even layer. Drizzle with the olive oil, then sprinkle with the kosher salt, black pepper, and red pepper flakes if using. Toss gently to coat and spread the shrimp back into a single layer.
If using, pour the white wine or chicken broth around the shrimp in the dish; this will mingle with the butter to form a slightly more saucy base.
In a small saucepan over low heat (or in a microwave-safe bowl in short bursts), melt the butter just until liquid. Remove from the heat and stir in the minced garlic, lemon zest, and lemon juice. Let it sit for 1–2 minutes so the garlic softens slightly in the warm butter.
Pour the warm lemon-garlic butter evenly over the shrimp, making sure each one gets a bit of the mixture. Use a spoon to nudge any stray garlic pieces so they’re distributed across the shrimp rather than pooling in one spot.