Why can't magnets be used to create perpetual motion?

I think I've just discovered the answer to all our energy needs. Just align magnets in a certain way so that they keep moving, using the magnetism as a fuel. Tell me why I'm stupid.