About midnight (kata de mesonuktion). Middle of the night, old adjective seen already in Mar 13:35; Luk 11:5 which see.
Were praying and singing (proseuchomenoi humnoun). Present middle participle and imperfect active indicative: Praying they were singing (simultaneously, blending together petition and praise). Humneō is an old verb from humnos (cf. Isa 12:4; Dan 3:23). Paul and Silas probably used portions of the Psalms (cf. Luk 1:39., Luk 1:67.; Luk 2:28) with occasional original outbursts of praise.
Were listening to them (epēkroōnto autōn). Imperfect middle of epakroaomai. Rare verb to listen with pleasure as to a recitation or music (Page). It was a new experience for the prisoners and wondrously attractive entertainment to them.