Continuum Thermodynamics of Contact Friction and Wear