Pick a new-to-you technology you're interested in, do File/New Project... on it, and just build something. Give yourself permission to be a beginner again. Build something that no one else will see, but that you'll regain your confidence with by proving to yourself that you're still capable of learning and growing. You'll see that something that took you 20 hours to do in week 1-2 will take you 20 minutes in week 8.
And remember: this is art, not science. We all make artistic decisions about how to do things in programming all day (we pretend it's science or engineering... it's not) and you will, too. Give yourself permission to do things how you want to, it's all just a learning opportunity.
I did this when I turned 40 after years of being an architect... it refreshed my love for coding.