Implemented stage D and fixed styling inconsistencies.