Peace be upon you. According to Grand Ayatollah Sayyid Sistani (may Allah protect him), it is permissible for a non-related man to look into a woman's mouth in itself, as long as it does not lead to another prohibition, such as forbidden touching. However, Grand Ayatollah Sayyid Khamenei (may Allah protect him) states that it is obligatory to avoid a non-related man looking into a woman's mouth, except in cases of medical necessity, where it is allowed only to the extent of necessity while avoiding any intention of indecency. If paying the higher fee causes harm, hardship, or difficulty that is usually unbearable, such as if the person is poor and unable to pay the female dentist's fee, then the examination and touching should be limited to what is necessary. However, if the only reason for considering the male dentist is the higher fee, and the patient can afford it, even through borrowing that does not cause hardship, it is not permissible to go to the male dentist as a precaution. May you be successful in all good deeds.