reworking and fixing bugs introduced by the first responsive pass