Every IPO is slightly different, depending on the terms (and of course the market -- I will deal with only US non-OTC market IPOs). In some cases, the company itself is offering shares in exchange for raising public capital to fund growth or expansion -- this is what most investors expect from an IPO. But, it is also possible that some or, in rarer cases, all of the shares being offered are resale of shares owned by insiders.
The % of the company being released to the public is also variable. Some IPOs only release a small percentage of total ownership to the public markets, reserving a portion of equity to a majority shareholder like a family who owned the company pre going public, or a parent company in the event of the IPO of a subsidiary. In these cases the other investors are not searching for liquidity of their shares necessarily right away. They may release more of those shares over time, or use the public market valuation to boost the NAV of an investment portfolio, or
To know what the source of the shares is, what % of the company is going public, and what the target offering price and implied valuation at that price is, as well as pre-IPO financials, you have to get a copy of the Prospectus. That will have all the details. If you can get a hold of the pitch deck as well or a video of the pitch, that will have more information or at least clarification of the information.
For the actual IPO event itself, it begins with the 'road show' pitch. During that pitch, investors from big firms are sold large blocks of shares in the company. On IPO day those sales are executed pre-market and those investors can then sell their shares on the open market, and the company itself can also sell shares it may have held and registered to be able to sell if it plans to raise additional capital that way (will be in the prospectus, but companies prefer the predictability of contract prices and not exposing themselves to the whim of the market when raising capital most times).
The initial prices on the open market are driven by the pre-market contract prices (margin to which will set the ask) and non-party-to-the-IPO investor demand (sets the bid). Fromt here on out it trades like any other public security. Once shares are held publicly and trades settled, things like options markets and short sales can begin. But, not until after the IPO event is concluded.
Many parties are involved in getting all the registrations and legal work done, as well as marketing the securities and underwriting of the deal. These lawyers, investment banks, etc. usually take fees for their services out of the proceeds of the IPO, though at times the firms will take some or (rarely) all of their compensation in allotments of shares -- direct or at a discounted pre-IPO price. The investment bank usually has a role with a support bid, or stabilizing bid as it is officially known, correct. The amount and quantity set by its bankers and negotiated as part of the underwriting deal. This support bid is registered with securities regulators and is meant to provide some price stabilization against insiders or traders doing quick flips of shares on the market.
Another stabilization technique is to lockout insiders from selling their shares for a period of time, commonly 6 months, after the IPO. This reduces the likelihood of a flood of unexpected sell orders that would hurt the price of the shares.
All of this obviously drastically simplifies what is a large and complex financial transaction with many parties, each incentivized differently (some to get the highest price, so the most price stability at release, etc.).