Transitioning from experimental to theoretical research after masters
This depends strongly on the branch of physics. For theoretical PhD work in high energy physics you need a very profound theoretical and mathematical background. A purely experimental master work would make me suspicious if you can catch up the lost time to learn by yourself this necessary background.

In branches like nano and quantum physics due to the size and nature of the investigated objects, a strong collaboration of theorists and experimentalists is very common and practiced and even within a master or PhD work project these systems/objects can be and are often modeled/simulated/calculated additionally to experimental measurements by single students.

Your question is very valid, for PhD positions in top universities and groups the group leader will take an in-depth look on your background. Switching form theoretical nanophysics in the master work to theoretical high-energy physics PhD is much less troublesome than from applied physics, but also not easy. The likelihood for tenure is in the bigger branches like condensed matter physics much higher than in small niche branches. The smaller and more competitive your aimed branch is, the earlier you should work towards it. And in addition to computer science or math, even if you decide to become a pure theoretical physicist, you still have to have a good overview and understanding of experimental methods.

Many physics students know before starting to study that they want to work later in hep or astrophysics or ... and specialize over their studies by attending special lectures and seminars ("Sheldon-Nerd-syndrome"). Promising that you will catch up this content will not help you a lot, as it can take years to understand, apply and further develop some physical theories. 

Speak to professors in the field you are interested in or look simply on some faculty homepages, if the field is split up into experimental/theoretical/computational groups. As said, for some fields experimentalists and theorists work within one group, for other both types rather and only interact in big collaborative projects or over publications and the single research groups are purely theory/experiment oriented.