The Secretary shall reduce allocations to State agencies qualifying for an allocation under paragraph (1)(B), in a manner determined by the Secretary, to the extent necessary to ensure that the total amount of funds allocated under paragraph (1) is not greater than the amount appropriated under subsection (g).