Monopoly hotel sell to pay debt to opponent
The rules clearly state that houses and hotels are a finite resource: 


  BUILDING SHORTAGES: When the Bank has no houses to sell, players wishing to build must wait for some player to return or sell his/her houses to the Bank before building. If there are a limited number of houses and hotels available and two or more players wish to buy more than the Bank has, the houses or hotels must be sold at auction to the highest bidder.


Furthermore, the rules for selling houses and hotels are clear:


  Houses and hotels may be sold back to the Bank at any time for one-half the price paid for them.
  All houses on one color-group must be sold one by one, evenly, in reverse of the manner in which they were erected.
  All hotels on one color-group may be sold at once, or they may be sold one house at a time (one hotel equals five houses), evenly, in reverse of the manner in which they were erected.


The rules do not clearly cover the situation you describe, but I think they implicitly force you into selling more than you need to cover your debts.

Specifically, if there are only two houses left on the board, you would have to sell your hotels and houses in the reverse order you build them until there are enough house and hotel pieces available on the board to accurately reflect what you've done. In your case this means selling from a full set of hotels down to two houses.

Strategically I'd recommend a different play. If the hotels are the only improvements you have on the entire board you're probably screwed anyway, but if not I'd consider selling houses you own on other properties first.