Shadow isn’t better at 40 for leveling. The downtime is awful. You can do a disc/holy/shadow and do as much damage as shadow (easily) with little to no downtime. Key talents are wand spec, spirit tap, imp shadow word pain. Eventually you want to work down the disc tree to the spirit buff. Go for gear with Stam/spirit. Int has a very low impact early on.
As mentioned you only really need Shadow word pain, holy fire or smite (don’t need both), power word shield, renew, heal/greater heal (use down ranked heal when you get greater heal) POH is great and all but you can honestly heal to 60 without it, especially if you are stacking spirit gear.
Talents, water, and buying spirit gear is what makes leveling a priest so expensive. That’s why the tri-build excels saving you huge amounts of gold along the way. Buying only certain spells helps as well. As far as gear my best advice is to research which dungeons srop spirit gear and focus on them. You can absolutely get by without buying spirit gear, some slots you’ll have 10+ levels lower at times.