Fill a water balloon In this challenge, you must display ASCII art of a water balloon given the
amount of water that the balloon is filled with:

|  __||__  |
| / #   #\ |
| |######| |
| |######| |
| |######| |
| |######| |
| |######| |
| \######/ |
|          |
|          |
+----------+


How to draw the balloon

To display a balloon of size n, follow the following steps (note: whenever
the division symbol (/) is used, it represents integer division, rounding
down):


Draw a container consisting of ten vertical bars (|) on the left and right,
ten dashes (-) on the bottom, and a plus sign (+) in the bottom left and
bottom right corner. This makes the whole thing 12x11, and the "inside"
10x10.

|          |
|          |
|          |
|          |
|          |
|          |
|          |
|          |
|          |
|          |
+----------+

Draw two vertical bars (the opening of the balloon) centered in the middle
of the top row, with n/2 underscores (_) on either side (for this example,
n will be 5):

|  __||__  |
|          |
|          |
|          |
|          |
|          |
|          |
|          |
|          |
|          |
+----------+

Draw one slash (/) and one backslash (\) surrounding this top row, one
row below:

|  __||__  |
| /      \ |
|          |
|          |
|          |
|          |
|          |
|          |
|          |
|          |
+----------+

Draw n rows of identically-spaced vertical bars, and then one row of a
pair of (still identically-spaced) backslash and slash:

|  __||__  |
| /      \ |
| |      | |
| |      | |
| |      | |
| |      | |
| |      | |
| \      / |
|          |
|          |
+----------+

"Fill" the balloon with water, represented by a hash sign (#). Start at
the lowest row, and work upwards. If a row is not entirely filled, you may
place the hash marks wherever you want (in the below example, they are
placed randomly, but you could put them, say, all on the left side if you
want).

|  __||__  |
| / #   #\ |
| |######| |
| |######| |
| |######| |
| |######| |
| |######| |
| \######/ |
|          |
|          |
+----------+



The maximum n is 7, and the minimum is 0.

Input

The input will be an integer i, which is the amount of hash marks (water)
that must be drawn.

It will never be less than 2, or greater than 100.

Output

The output should be a balloon of size n containing i hash marks (units of
water), where n is the lowest possible size that can hold i units of water.
Since i will always be 2 or greater, n will always be 0 or greater.

The maximum possible size a balloon can be drawn at is n = 7. If a size 7
balloon cannot fit the amount of water specified, the balloon pops:

|          |
|          |
|##  #  ###|
|##########|
|##########|
|##########|
|##########|
|##########|
|##########|
|##########|
+----------+


(The above should be the output for input i = 76. Just like the unpopped
balloon, the six extra units of water on the top row may be arranged however
you please.)

Test cases

Why have one test case, when you can have all of them?

Here's an animated GIF of all inputs i from 2 to 100:



Scoring

This is code-golf, so the shortest code in bytes wins.
Python 2, 591 bytes

Took me some time and it probably could be golfed much more.

Hope there aren't any major errors.

r=[list(x)for x in ("|          |!"*10+"+----------+").split('!')]
s,t=[0]*4+[1]*2+[2]*10+[3]*4+[4]*16+[5]*6+[6]*22+[7]*8+[8]*29,[(4,2,2),(4,3,2),(3,4,4),(3,5,4),(2,6,6),(2,7,6),(1,8,8),(1,9,8),(0,9,10)]
a,b,c,d,e='|','/','\\','_','#'
def p(x,y,w):r[y][x]=w
def q(l):
 h,j,u=l
 p(5,0,a);p(6,0,a)
 for o in range(4-h):p(h+o+1,0,d);p(h+u-o,0,d)
 p(h,1,b);p(h+u+1,1,c)
 for o in range(j-2):p(h,o+2,a);p(h+u+1,o+2,a)
 p(h,j,c);p(h+u+1,j,b)
def w(i,l):
 h,j,u=l
 for o in range(i):x,y=o%u,o/u;p(h+x+1,j-y,e)
def f(i):
 n=s[i]
 l=t[n]
 if n&lt;8:q(l)
 w(i,l)
 print "\n".join(["".join(x)for x in r])


Example run:

f(34)


gives:

|  __||__  |
| /####  \ |
| |######| |
| |######| |
| |######| |
| |######| |
| \######/ |
|          |
|          |
|          |
+----------+