I’m thinking of two reasons as to why those who make, legislate, and enforce the laws should be prayed for.
Firstly, whether they know it or not, they are serving in a capacity ordained by God. Their authority doesn’t come from themselves or from we the people. Authority in this world derives itself from ultimate, divine authority. In other words, all that is, including earthly authority, is because of God’s authority as Supreme Ruler of reality (John 19: 10, 11). It is God who instituted and established the concept of governance (Romans 13: 1).
Whether governments are good or bad are beside the point. God is a God of order and justice. Governance was established by God and given to us with the intention of reflecting those two of His godly attributes. That sin has caused His governing idea to be corrupted doesn’t negate the goodness of the concept.
So we want to pray that God’s will be done in the lives of our civil leaders. We want to pray for these servants of God (Romans 13: 6) to accept Jesus as Lord; to submit to His wisdom; to rule unselfishly. For the salvation of their souls and that they govern from His righteousness is why we pray for our fellow servants of the Lord.
Lastly, we pray for our civil leaders because, naturally, their decisions affect our lives. After all, we’re commanded to submit ourselves to their decisions, be they good or bad (Romans 13: 2, 7; 1 Peter 2: 13, 14). Of course, the exception to this command is when governmental decisions are evil and contrary to God’s laws (Acts 5: 27-29). So we pray to have our leaders rule in a way that would make for an environment in which we can freely and peacefully live the ways of God (1Timothy 2: 1, 2).