(CNN) Over a thousand kilometers separates Rostov-on-Don and the Russian capital Moscow -- but in terms of football pedigree, it might as well be light years.
So when FC Rostov, a team usually fighting to avoid relegation, finished just two points short of champion CSKA Moscow in the race for last season's Russian Premier League title, it sent shock waves through the country's soccer elite.
The fairytale story centers around a former Rostov player turned manager, Kurban Berdyev, who inspired his squad to overcome the club's crippling financial problems to finish above five-time Russian champion Zenit St. Petersburg and claim a place in Europe's lucrative top competition, the Champions League.
Rostov's achievement was somewhat overshadowed by the shock success of underdog Leicester City in the English Premier League; this week both clubs will compete against the continent's finest teams for the first time.
On Tuesday, Rostov -- whose sole post-Soviet-era trophy is the Russian Cup, won in 2014 -- will travel to Germany to face five-time European champion Bayern Munich in the opening round of the group stage.
So how did a team that was completely written off overcome so many odds?
Troubled times
Having won the Russian Cup, Rostov was soon embroiled in a legal battle against exclusion from the Europa League in the 2014-15 season after the Russian Football Union (RFU) claimed players had been improperly paid out of a government pension fund.
While the club was ultimately allowed to compete in the continent's second-tier competition, it lost in the first round.
Financial trouble continued to plague Rostov. The regional government, which owns the team, was stretched by recession and an influx of refugees from the conflict in eastern Ukraine.
More controversy followed in November 2014, when then coach Igor Gamula -- who led Rostov to the domestic cup title -- was suspended by the RFU for saying the club had "enough dark-skinned players" and would not sign another.
Daring to dream
Facing relegation and financial ruin, Rostov demoted Gamula to manage the under-21 team and turned to Berdyev -- a former midfielder who played one season for the club in 1979-1980.
Berdyev had enjoyed recent success, leading Rubin Kazan to the Russian title in 2008 and 2009 and a remarkable Champions League victory over Barcelona at Camp Nou.
It was a genius decision.
Not only did Berdyev ensure survival, he built a team which produced one of the most astonishing stories Russian football had seen -- not to mention a $14 million payout for Champions League qualification.
Read: Europe's top leagues to get four group-stage spots
"Rostov was fighting for the title until the end -- it was like Leicester last season," Artur Petrosyan, editor-in-chief of Sport-Express, told CNN.
"Towards the end of the season nearly all the neutral fans wanted it to go all the way. When it managed to beat Zenit 3-0 at the end of last season, every fan, outside St. Petersburg, just fell in love with the team."
Berdyev won two Russian league titles with Rubin Kazan.
Not only did Rostov give CSKA Moscow a run for its money, but it outclassed the so-called bigger teams such as Zenit, FC Krasnodar and Spartak Moscow.
The achievement was even more remarkable given the state of the club's finances and the drama unfolding behind the scenes.
By October 2015, some club employees were threatening to strike over unpaid wages, while some players discussed boycotting a game after their salaries went unpaid.
Rostov has not responded to CNN's request to comment for this article.
'Bankrupt'
"The funding has actually been a huge problem," Manuel Veth, editor of Futbolgrad, told CNN. "At some point last season the club was almost bankrupt, and players even boycotted a Russian Cup game.
"Players went without salary for months, yet Berdyev kept his team together, and managed to challenge for the Russian title last season. In any other league in Europe, the club would have been declared bankrupt and relegated."
Sardar Azmoun has been one of Rostov's most impressive performers.
While the off-field problems continued, there seemed to be little negative effect on the players.
Experienced Ecuador international Christian Noboa ran the midfield, while prolific Iran striker Sardar Azmoun -- on loan from Rubin Kazan, but now permanently signed -- provided the goals.
By April, Rostov was in first place and on course to pull off the most unlikely of triumphs.
Europe's biggest summer signings
Premier League spending during the European summer transfer window reached £1.165 billion ($1.544 billion) on deadline day, August 31. Brazilian defender David Luiz rejoined Chelsea from Paris St. Germain for a reported fee of £34 million ($44.7 million).
Luiz wasn't the only defender Chelsea signed on deadline day, after paying a reported £23 million ($30.5 million) to bring Marcos Alonso to Stamford Bridge from Italian club Fiorentina. It was the sixth consecutive year spending in England's top division has increased, breaking the £1 billion mark for the first time.
Going the other way was Chelsea's Colombia star Juan Cuadrado, who re-signed for Serie A champion Juventus on a three-year loan deal.
Tottenham Hotspur spent a club-record £30 million ($39.75 million) on deadline day to sign France midfielder Moussa Sissoko from relegated Newcastle United.
After failing to challenge for the Premier League title last season, Arsene Wenger was under pressure to further strengthen his squad with high-profile players -- but it took until August 30 for Arsenal to announce the signing of Lucas Perez from Deportivo la Coruna for a reported fee of £17 million ($22 million). The 27-year-old is uncapped by Spain, but scored 17 goals in La Liga last season.
Soon after the Perez deal, Arsenal also confirmed the signing of Germany defender Shkodran Mustafi (pictured right at Euro 2016) from Valencia. The fee was undisclosed but British media reported it to be above £30 million ($39 million).
Midfielder Jack Wilshere left Arsenal to join Bournemouth on a season-long loan, after manager Arsene Wenger couldn't guarantee the England international regular first team football.
Barcelona goalkeeper Claudio Bravo signed for Manchester City on August 25, joining former manager Pep Guardiola for a reported fee of £15.3 million ($20 million).
He replaced Joe Hart, who was deemed surplus to requirements by Pep Guardiola and promptly loaned out to Italian club Torino on August 31.
On June 30, Brazil forward Hulk became the Chinese Super League's most expensive signing, after joining Shanghai SIPG from Russian club Zenit St. Petersburg for €55.8 million ($60.8 million).
On June 28, Sadio Mane became
the most expensive African player when the Senegal forward joined Liverpool from Southampton in a deal worth a reported £34 million ($44.7 million).
It might have been a free transfer, but Zlatan Ibrahimovic's July 1 move to Manchester United is one of the biggest deals of the summer window. The free-scoring Swede joined Jose Mourinho after his contract at Paris Saint-Germain expired.
On July 6, Mourinho made Henrikh Mkhitaryan his second signing at the club, with Manchester United paying Borussia Dortmund a reported fee of $40 million for the Armenia midfielder.
Mourinho's first acquisition was Ivory Coast defender Eric Bailly. On June 8, Manchester United announced the 22-year-old's signing from Spanish team Villarreal for a reported £30 million ($39.2 million) fee.
John Stones didn't play a single minute in England's ill-fated Euro 2016 campaign, but on August 9 the 22-year-old joined Manchester City from Everton for a reported fee of $62.7 million -- which made him the world's second-most expensive defender.
A week earlier, Leroy Sane had become Pep Guardiola's fifth Manchester City signing, joining from Schalke for a reported fee of $49 million. The 20-year-old made one appearance at Euro 2016, as a substitute in Germany's semifinal defeat by France.
On July 1, Spain forward Nolito became Guardiola's second signing when Manchester City triggered the €18 million ($20 million) release clause in his Celta Vigo contract.
On June 2, Germany midfielder llkay Gundogan became Guardiola's first City signing, joining for a reported £20 million ($26 million) fee from Borussia Dortmund.
On July 21, Andre Gomes joined Barcelona from Valencia for an initial fee of €35 million ($39 million) after a successful Euro 2016 in which the midfielder helped Portugal win its first international title.
France defender Samuel Umtiti moved to the Spanish champion on July 30, signing a five-year deal after Barca paid French side Lyon €25 million ($27.9 million).
Barcelona also completed the €16.5 million ($18.4 million) signing of France international left-back Lucas Digne from Paris Saint-Germain on July 13.
Italy striker Graziano Pelle reportedly became the joint-sixth highest paid player in the world after he left English club Southampton to join Chinese Super League side Shandong Luneng in a £13 million ($17 million) deal on July 11. The 31-year-old will
reportedly earn that much in one season.
On July 30, Spanish club Atletico Madrid signed French forward Kevin Gameiro from La Liga rival Sevilla for a reported €32 million ($35.6 million).
On June 16, Champions League finalist Atletico also agreed a €25 million ($27.8 million) deal for Benfica's Argentinian midfielder Nicolas Gaitan.
World Cup winner Mario Goetze rejoined Borussia Dortmund on July 21 after an unsuccessful spell with Bayern Munich, which had made him Germany's most expensive player at the time when it paid €37 million for him in 2013.
The next day, Dortmund continued to bolster its squad by signing Andre Schurrle from Bundesliga rival Wolfsburg for a reported fee of $33 million.
On July 16, France midfielder N'Golo Kante was the first star name to be sold from Leicester City's Premier League-winning side, signing for English rival Chelsea in a $42 million deal.
On July 3, former Juventus and Italy coach Antonio Conte started his Chelsea revolution by signing 22-year-old Belgium striker Michy Batshuayi from French club Marseille for a reported €40 million ($44.5 million).
On June 13, Juventus paid Italian rival Roma €32 million ($35.6 million) for Bosnia and Herzegovina midfielder Miralem Pjanic.
On July 15, Juventus completed the signing of Morocco defender Medhi Benatia from Bayern Munich on a season-long loan costing €3 million ($3.45 million), with an option to buy for an extra €17 million ($19 million).
Juventus signed Brazilian defender Dani Alves on a free transfer from Barcelona on June 27 after his contract at the Spanish club expired.
On June 21, Real Madrid activated the €30 million ($34 million) buy-back clause for Spain striker Alvaro Morata -- who it had sold to Juventus for €20 million ($22.3 million) in 2014.
Granit Xhaka made headlines at Euro 2016
when his shirt ripped -- before the tournament the Switzerland midfielder had already secured a move to English club Arsenal from Borussia Monchengladbach in a deal worth a reported £30 million ($39.2 million).
Bayern Munich started the big-money moves in May, when the German champion announced a €35 million deal for Benfica's teenage midfielder Renato Sanches, who would help Portugal win Euro 2016.
At the same time, Bayern also revealed it had agreed a deal to buy Germany's World Cup-winning defender Mats Hummels for reportedly a similar initial fee from Bundesliga rival Borussia Dortmund.
Only in the final weeks did it stutter, drawing too many games and allowing CSKA -- the official team of the Soviet army during the communist era -- to win its 13th national title.
Despite the heartbreaking near miss, a place in the Champions League -- and the potential cash bonanza to follow -- was much more important to the club's survival than a trophy.
"Berdyev is a very good coach and motivator," Veth said. "Champions League football was the only way to keep the club alive, hence the players knew what to do."
Who will win the Champions League? Tell us on our Facebook page
Setback
Azmoun scored against Anderlecht and Ajax in the Champions League qualifying rounds.
If this was a Hollywood story, the script would have ended with there. But success only brought about more drama.
Berdyev wanted assurances over the club's finances and promises that the situation would improve.
Read: Guardiola set for Barca reunion
In June, he met with Rostov's regional governor Vasily Golubev and signed a new two-year deal.
But salaries remained unpaid, money was not forthcoming for new signings, and players bolted to other clubs.
Berdyev eventually had enough, quitting after victory over Anderlecht in August's Champions League third-round qualifier secured a place in the playoffs -- the last step before reaching the group stage.
Assistant coach Dmitri Kirichenko took temporary charge after Berdyev's departure.
Rostov was left rudderless, and handed the reins to an assistant while Berdyev shopped himself around to bigger teams.
But nothing materialized for the 64-year-old who, in a bizarre U-turn, headed back to Rostov in a consultant role. He is now listed as a team vice-president and assistant.
"It doesn't matter what he's called, he's just doing what he did before," clarified Russian journalist Petrosyan.
Read: Champions League final vs. Super Bowl
Which club will be crowned European champion?
Gareth Bale's Real Madrid is hoping to make history by becoming the first club to successfully defend the Champions League title. No team has managed the feat since Europe's top tournament was revamped in 1992.
Last season, Lionel Messi and co.'s title defense ended at the semifinal stage. The Spanish champion will be one of the favorites again this time. Luis Suarez, Neymar and Ivan Rakitic were all outstanding last season -- and don't forget a certain Andres Iniesta.
Always in the mix, the German champion will hope to improve on last season's semifinal performance. New manager Carlo Ancelotti, who has won the competition three times as a coach, has added to his squad with the acquisition of teen midfield star Renato Sanches -- who helped Portugal win the Euro 2016 title.
The Spanish club suffered heartbreak in May's final -- losing out to rival Real on penalties after a 1-1 draw in Milan. It was the second time in three years that Diego Simeone's side had gone close to winning the competition. He'll be hoping France star Antoine Griezmann returns from Euro 2016 all fired up.
It might have lost Paul Pogba to Manchester United, but Italy's "Old Lady" is still a team to be feared. The perennial Serie A champion splashed out
$99 million on Napoli striker Gonzalo Higuain in the off-season, while its impressive defensive core remains. It will be a tough nut to crack under coach Massimiliano Allegri.
The French champion reached the quarterfinal stage last season before being beaten by Manchester City. Its iconic striker Zlatan Ibrahimovic has left to join Manchester United, but new coach Unai Emery has brought in Real Madrid's Jese and Poland midfielder Grzegorz Krychowiak from his former club Sevilla.
Back in the competition after spending last year in the Europa League, Dortmund will be one of the teams to fear. Its style of fast, free-flowing football has been one of the most exciting on the continent over the past year and, led by the likes of Marco Reus and top scorer Pierre-Emerick Aubameyang, it could reach the knockout stages.
The English team reached the last four for the first time in its history before somewhat meekly losing to Real Madrid. New coach's Pep Guardiola first task was to bring the club through the qualifying stages. The former Bayern and Barcelona coach has already spent big on signing Ilkay Gundogan, Nolito, Leroy Sane and John Stones.
Destiny
On Tuesday, Berdyev will be in attendance at the 75,000-capacity Allianz Arena to see his side, led by newly-appointed coach Ivan Daniliant, face a star-studded Bayern team that has won its national league 26 times.
Rostov will then host last season's losing finalist Atletico Madrid and Dutch champion PSV Eindhoven at its aging, 16,000-capacity home ground, but the club is awaiting the completion of its new stadium. Being built for the 2018 World Cup in Russia, the $310 million, 45,000-seat facility is due to be finished by the end of this year.
Such an upgrade elicits a feeling in Rostov that this is what everyone has been waiting for.
Visit cnn.com football for more news and features
"The home games will be a big thrill for everyone," Rostov assistant coach Dmitri Kirichenko told reporters after the draw.
"The excitement will be incredible. I am sure the fans will help us to get positive results. We have a really lively atmosphere at the stadium in Rostov-on-Don, and the fans deserved this."