Answered by Shaykh Amjad Rasheed
Is it permitted to look at a teacher of the opposite sex because of the need to study and learn?
The relied upon position in the Shafi`i school is that it is prohibited (haram) for the man to look at an unrelated woman’s face, and vice versa, regardless of whether there is any desire or not.
However, there is a position within the school that permits looking at the face when there is no desire. This is also the Hanafi position.
Imam Bajuri (Allah have mercy on him) indicated in his Hashiya that it is permitted to follow this position because of how common it has become for women to uncover their faces in these times.
Note, however, that this difference of opinion relates only to looking at the face. As for looking at the rest of the head, hands, or feet, it is not covered by the dispensation and remains prohibited, whether there is desire or not.