This book starts you off with NAND gates and then has you build an ALU, CPU, assembler, and finally a Java-like-language compiler.
The Elements of Computing Systems / From NAND to Tetris https://www.nand2tetris.org/
The first six textbook chapters (all the hardware stuff) are available on the website in the 'Projects' tab, you should buy the book for the other six. All 12 chapter assignments are available on the website. The Software section has a hardware simulator to test your designs.