Cyprus reached an agreement early Monday with the International Monetary Fund, European Central Bank and European Union on a plan to rescue the tiny debt-choked euro-zone member from financial ruin, according to the Eurogroup.

But the plan -- unprecedented in its severity -- will economically handicap the island nation for years.

Just hours from a deadline for accepting severe bailout terms set by the IMF, ECB and EU -- or the troika, as they are known collectively -- Cyprus President Nicos Anastasiades and troika leaders meeting in Brussels agreed to close the Popular Bank of Cyprus, aka Laiki, Cyprus' second-largest bank, and move deposits of less than €100,000 ($$129,830) from that bank to Bank of Cyprus, the island's largest bank, where those balances will be protected.

However, bank balances in Laiki that are greater than €100,000 will be frozen, and the government will take an as-yet undisclosed percentage of each of those accounts, something euphemistically called a “haircut.” The percentages of those haircuts, or levies, that have been discussed over the weekend range from 20 percent to 40 percent.

The money raised from that levy will be applied toward a €5.8 billion ($7.5 billion) contribution the troika is demanding Cyprus make to qualify for a €10 billion loan. In its previous financial rescues of four countries -- Greece, Ireland, Portugal and Spain -- the troika never required private depositors to directly bear some of the burden of a rescue. Without the rescue, however, the island's banks would collapse, the nation would default on its sovereign debt and the euro zone would lose a member.

Euro-zone finance ministers were meeting Monday before dawn to consider the deal.

Numerous details of the plan remain undisclosed, and perhaps unsettled. One of the most critical details will be what happens to bank balances of more than €100,000 in the Bank of Cyprus. That question is of intense interest to the many wealthy Russians who keep their fortunes in Cyprus because of its lax bank regulation.

The bailout plan is not expected to require the OK of the Cypriot Parliament, Reuters reported.

No matter the details and no matter how the current crisis finally plays out, analysts expect life in Cyprus will become dramatically more grim for years.

“The haircuts will have a calamitous impact on Cypriot output, leading to a decline in gross domestic product of 10 percent this year and 8 percent in 2014,” Gabriel Sterne at Exotix, a hedge-fund advisory firm, told the Wall Street Journal. “We think the peak-to-trough decline in annual real [gross domestic product] will be in the order of 23 percent, similar to Greece, but we see risks more on the downside than the upside.”

The runup to the predawn deal was filled with tension and at one point Cypriot's head of government and state appeared ready to walk away from the marathon talks.

The Cyprus News Agency reported that Anastasiades asked the international lenders: “Do you want to force me to quit? If this is what you want, then just tell me so.” Sources at the presidential palace in Nicosia told the news agency that Anastasiades said he had presented “one proposal after another” to the international lenders, but that they wouldn’t accept any of them.