For much of its existence, Mexico has been a Federal Republic in much the same way China is a "People's Republic". Functionally, the government is federalist with a strong central government but states have near complete autonomy and discretionality (this last is a contested sore spot). From bottom to top: Municipal government is handled with mayoral elections and síndicos, or councilmen. This level of government usually shows the a good thermometer for national party preferences. On the state level, each state has a constitution which can be as different from one to another as it pleases the residents, so long as it does not contradict the federal constitution (there's been some brouhaha over the state of Coahuila and Mexico City legalizing gay marriage, with opponents seeking to amend the constitution to force the issue). Each state has a governor and a unicameral legislative. The Supreme Court in Mexico is made up of 11 judges. At the federal level, the system is similar to that of the US (not coincidentally, post revolutionary governments the world over love to cheat off of the US constitution). On the legislative side there's a bicameral legislature. During the government of the PRI, both were pretty much rubber stamps to presidential initiatives but have gained considerable power over the last two decades after the PRI majority in congress disappeared. Congress is the lower house, and is generally the "rowdy" bunch (with occasional—mind you, occasional—fisticuffs), a bunch of 300 elected congressmen and 200 "plurinominales" or "plural votes", these last are accorded to each party proportionally to their share of votes in the latest popular election. The party fills these seats as they like. Attempts to winnow this ungainly number have been... difficult. The Senate or upper house is much smaller at 128 and generally more serious (which isn't saying much; it's distressingly common for legislators in either house to seize the tribune). After the Mexican Revolution, for much of Mexico's 20th century history, any real power rested with the President, a six year virtual dictator with supreme power over the PRI (the main political party from 1920-2000) and the government. Nowadays, the president still has a great deal of power... but it's the legislative who's boss. The thing about the six year dictators is that most of their power was never codified, and in fact it's the legislative that holds a lot of the weight. This is something the legislative is just figuring out in its adolescence, and the result looks rather like the US in the period between independence and the Civil War (you know, when brawls on the House floor broke out every now and again, and a Senator was beaten within an inch of his life, but the legislature controlled all). Presidents, Governors and Senators are elected for six year terms. Every incumbent holding a Government executive office in the country (Mayors, Governors, the President) is barred from reelection once his/her term is up. And in the President's case, his office is strictly a one-term affair (Majors for example can be reelected to non-consecutive terms).
PartiesMexico is a multi-party democracy, and since 1997 (when the PRI weakened) no party has held a majority in either house, so most legislation has to go through on a case-by-case basis. So far, all presidents were either from the PRI (including the current one) or most recently from the PAN (previous two). Parties are supposed to be funded by the taxpayer. The three major parties below are listed by 2012 voting preference.
The PRI - (Partido Revolucionario Institucional - Institutional Revolucionary Party) The only political party in Mexico without a clear platform. Although technically founded in 1946, PRI is the immediate reboot and direct heir (membership and whatever they called a "platform") of the PNR, a party first started by military men in The Twenties to control the violent excesses leftover from the Mexican Revolution by forcing every important politician and leader in Mexico at the time to join and line-up or else. The organization has a deliberately ambiguous philosophy and platform, accepting people from any political viewpoint as a means to broaden its appeal. For most of the 20th century, the PRI and its previous incarnations were the party in power through all of Mexico, winning every presidential election since the 1920's until 1994. To achieve this control the party was not above resorting to dirty tacticts to manipulate the results. However PRI would allow itself to lose occasional mayor or governor race to give the outward appearace of democracy. After 1994 with the economic crash, the party was floundering without strong leadership and internal divisions making unified candidacies difficult, which led to the unprecedented and catastrophical (for the PRI) defeat against the PAN in the 2000 presidential elections. Unable to take a hint, the party kept up its outdated authoritarian image and inner squabbling and in the presidential elections of 2006 suffered a terribly poor showing (to date the only time they came up third in such elections) because the Party president forced himself as candidate and earned the ire of all the other pre-candidates. Finally straightening up their act, their fortunes improved: after the 2009 midterms, they gained a plurality in the lower house, made into a de facto majority via their alliance with the PVEM. This same alliance made it possible to eventually win the 2012 national elections and hence, currently hold the presidency once more after twelve years out of office. Though explanations for this startling comeback are many, it's mainly attributed to the 2007 electoral reform, anger at the world economic crisis, a very poor performance by presidents from the PAN, and several PRI state governors using decades old and brand new vote buying techniques that the authorities can't or won't stop. Current president and PRI member Enrique Peña Nieto went full tilt into deep economic, energy, communications, labor and educational reforms that many find too much too soon and even controversial. Others argue that Mexico has been in dire need of these changes for at least 25 years and that the speed of change is just an inevitable catching up to date.
The PRD - (Partido de la Revolución Democrática - Party of the Democratic Revolution) A moderate left to extreme left party. Founded in the late eighties, they are the only one of the big three parties to have never won a presidential election as of this writing. PRD split from the PRI over their inability to provide actual democracy and the then recent shift to the right in the PRI. Cuauhtemoc Cardenas, the PRD's founder, left because the tradition that the outgoing president picked his successor both cost him a shot at the presidency and disgusted him. Those not idealistic enough will tell you that the PRD was originated by PRI members discontent with their meager lot in the old party's distribution of power, money and corruption. The PRD has its most powerful bastion in Mexico City, where they have won every single election for mayor since 1997. Other strongholds tend to be in the southern part of the country. Nowadays they're a hodgepodge of "tribes" ranging all over the left. This internal division has grown particularly nasty, since the two largest tribes basically accused each other of stealing the internal elections. The 2006 runner-up presidential candidate Lopez Obrador had firm control over half the party, despite having alienated most of the middle class with his messianic, sometimes confrontational style, causing a reduction in voting preferences to 14% of the electorate. He was opposed by the more traditional "Chuchos", and together they divided the party with no clear reconciliation in sight. Lopez Obrador was PRD's candidate for president again in 2012, but after also losing that election, he definitely broke away from the PRD forming with his followers yet another left-wing party called Morena (Movimiento de Regeneración Nacional or National Renewal Movement). By making the split official, it further hampers the left's chances to win the Mexican presidency in the near future.
The PAN - (Partido Acción Nacional - National Action Party) Officially the oldest of the surviving Mexican parties, PAN is a conservative party with Christian roots, it started sometime in the 40's as an elitist party formed by doctors, lawyers and other 'moral individuals'. Nowadays they're much more mainstream and Center-Right in affiliation. Those who support them cite a Catholic inspiration as well as traditional moral values. To those who don't subscribe to this view, this is just a hypocritical facade to secretly do nasty business in the background, as well as a perceived lack of concern for the lower classes. PAN is traditionally strongest in the northern and western states of Mexico. In 2000, the PAN made history and headlines around the world by winning the Mexican presidential elections, making it the first time in over a century that an opposition party candidate (Vicente Fox) installed himself in the Mexican presidency with due process (that is, not resorting to a coup). Tha fact that it was against an incumbent PRI famous for its formidable electoral machine and its resources embezzled from the state to fund its campaigns among other irregularities made the victory against a party that had won every presidential election since The Twenties all the more astounding. Unfortunately a lack of experience, an unwillingness to excercise authority, and the colorful behaviour of Fox often stained this genuine triumph for democracy. In 2006 PAN won again the presidential elections, but this time, since its candidate (Felipe Calderón) won by a ridiculously narrow margin in the last minute after trailing in the polls the rest of the time, many suspected the PAN of resorting to the same election rigging methods that the party had so hardly fought against for most of its existence when it wasn't the incumbent party. Calderon's authoritarian and aloof style, along with a poor economic showing due in no small part to the 2008 world crisis and the ramping up of street violence and crime due to the start of the 2006 drug war in Mexico did very little to improve the party's image. All this led to its candidate (Josefina Vazquez, the first female presidential candidate fielded by any of the major parties, i.e. the first woman with any realistic chance of winning) being relegated to a third place in the 2012 presidential election which went to the PRI candidate. Other parties - There's a sundry list of smaller parties, including the PVEM (Green Party, which is the ecologist party of Mexico but is ironically promoting the legalization of death penalty, and has been criticized as being the front of a family mafia), PT (Workers party), etc. None of these have yet gotten a governorship; however they have attained several seats in Congress and the Senate both at state and federal level. Normally they're too small to even act as kingmakers in congress, but these "stooge" parties practically exist only to keep the minimum share of popular votes necessary to keep their right to receive federal funding (i.e. pocket the money).