Virtual power and thermodynamics for electromagnetic continua with interfaces