Ruling the Republic was the Galactic Senate, a governing body comprising elected or appointed representatives from across the galaxy. From within that Senate, a Supreme Chancellor was elected. Justice and peace in the Republic was protected by the Jedi Knights, a noble order of Force-sensitives.
As the Republic grew more and more powerful, many of the bureaucrats and Senators that ran the government grew increasingly corrupt or complacent. The bureaucracy that had grown and festered over millennia choked any attempt at proactive government. Furthermore, partisan politics and personal agendas also hampered effective governing.
Into this mire stepped the ambitious Senator Palpatine from Naboo. His homeworld was under siege by the greedy Neimoidian Trade Federation, as protest to increased tariffs and taxation to outlying trade routes. Despite the full-scale invasion of the planet, the call to react was tied up in procedure. When Queen Amidala -- the elected leader of the sovereign system of Naboo -- spoke before the Senate, calling for action, she also called for a Vote of No Confidence in the leadership of the Republic.
The well-meaning but politically clumsy Chancellor Valorum was voted out of office. In his place, Palpatine was elected Supreme Chancellor. Despite promises of bringing order and compassion back to the Republic, the first decade of his term was blighted by great political upheaval. A separatist movement, led by the charismatic Count Dooku, began splitting the Republic, and it was all the Jedi could do to maintain order.
This chaotic political climate precipitated the dark times that overcame the galaxy. The Republic crumbled and was rebuilt in the guise of the New Order.