The second phrase is correct.
In this case, “everyone” is second person because these people are being directly addressed by the speaker. It’s fine to use “everyone” as the subject of an imperative clause, and this is a similar case. Note that no capitalization is required for “everyone.”
Everyone, everybody, everything, everywhere – English Grammar Today – Cambridge Dictionary
In any case, whether it is formally correct or not, “thank you to everyone” is commonly used, especially when speaking to a room of people. Although both are correct, I recommend the second phrase because it is almost always more powerful to be direct and concise.