Navy, environmental groups settle lawsuit, limiting some training that harms whales in Pacific