Then screw the top door hinge back in place over the cardboard like you did with the bottom hinge.
Wooden door hinge adjustment.
If you are working on an exterior door you want to see the article adjusting entry doors for instructions on how to do this.
Now that both door hinges are slightly raised by the pieces of cardboard the gap between your door and the frame should be smaller.
For interior doors see the article adjusting interior doors.
Unscrew the top door hinge and add the other 2 cardboard cutouts.