As Dave mentioned, switching to a loop should save you some zig zagging. Really the only thing that changes is the order.
Now, you can start by heading down the coast. After LA, then you head toward Vegas possibly via places like Joshua Tree or the Grand Canyon. After Vegas, you head back to San Francisco via Death Valley, Tioga Pass, and Yosemite.