The House passed a bill that would “repurpose” $500 million meant for cleaning up environmental and safety hazards caused by decades of coal mining.