Interface exciton modes and superconducting transition temperature of a metal in contact with a semiconductor