Continental Airlines and its mechanics are down to the wire in a contract dispute that has the potential either to bankrupt the company or to reduce union power all across the newly deregulated industry.

For most airlines deregulation has meant new fare competition and lower revenues. At issue now is whether the unions will help bail out the airlines by taking pay cuts or risk seeing the companies founder and disappear.

At midnight tonight a federally ordered 30-day cooling-off period involving Continental and the International Association of Machinists (IAM) expires. If there is no agreement in last-minute bargaining with the National Mediation Board here, the IAM has vowed to strike and Continental has vowed to post new work rules and fly most of its schedule. Almost everyone familiar with the situation is predicting that the strike will occur.

Continental management has made extensive preparations to keep operating, which no airline has ever done before when struck. Continental officials say they have had to take this hard line because of competition from nonunion carriers that have come with deregulation.

It is a risky strategy, which will require the cooperation of the pilots' union and which assumes that the public will continue to think it safe to fly despite the mechanics' being on strike.

Continental says it will maintain its planes with federally licensed nonunion contractor mechanics and supervisors. Eight hundred flight attendants have been trained in case, as expected, unionized flight attendants honor an IAM picket line.

Continental is in stiff competition throughout its predominantly western network. For example, one primary competitor between Dallas and Houston is something called Muse Air, which pays mechanics $10 an hour. Under the contract expiring at midnight, Continental pays either $13.45 or $16 an hour, depending on which of two predecessor airlines originally employed the mechanic. Continental claims that the IAM is seeking $19.20 an hour in its demands.

This is the same issue faced earlier this summer by both Eastern and Republic airlines, but there is a difference. Both those airlines settled with the IAM at the last minute.

Eastern then immediately laid off 1,600 employes and Republic went to all of its employes and said it had to have a 15 percent reduction in labor costs by Sept. 1 to stay in business. Negotiations on that are continuing favorably for the airline, Republic's Walter Hellman said yesterday.

"We're seeing new competitors crop up all the time whose operating costs are one-half to two-thirds those of the established carriers," Hellman said. "For an airline to continue to operate in the face of that competition, something has got to change. One place you can cut operating costs is in personnel."

Continental, in the private view of some industry observers, may be seeking to break the union, not just drive down costs. Continental is a subsidiary of Texas Air Corp., which also owns nonunion New York Air. The corporation is presided over by Chairman Francisco A. Lorenzo, who is not usually known to blink.

Neither is the IAM, traditionally militant and well-disciplined. It has a tradition of sacrificing jobs for salaries, which is what it did in the Eastern case.

"IAM's philosophy . . . has been to maintain the quality of the work place of those who are working. They will give up jobs," an industry labor source said. Furthermore, the IAM's contract with industry giant United Airlines is due for renegotiation in November, and industry observers say the union cannot afford to lose to Continental with those stakes on the table.

"Philosophically there is a major gap between the views of the airlines, who are facing up to deregulation, and the unions. The gap is not being closed rationally but irrationally, by force," an airline labor expert said.

Continental, the eighth largest U.S. airline in terms of passengers carried, has major bases in Houston, Denver and Los Angeles. It serves several points from all three Washington-area airports.

As with many airlines, price-cutting competition and the recession have combined to bathe Continental in red ink. In a letter to employes, the airline claims to have lost $165 million in the last nine months and "well over $450 million" in the preceding 4 1/2 years.

The Continental strategy will not work without the cooperation of its pilots, members of the Air Line Pilots Association (ALPA). "We have no reason to believe our pilots aren't going to work," Continental spokesman Bruce Hicks said.

But Henry A. Duffy, ALPA president, said yesterday, "We don't say what we're going to do until the time of the strike . . . . Our first concern is how safe is the operation, and that's difficult to assess because we don't know what the actions of the IAM will be."

ALPA's Continental members voluntarily reopened their contract last year and permitted substantial changes, a tactic ALPA has used to save jobs and salaries at several airlines. At Continental, according to Hicks, the ALPA concessions will be worth $90 million. ALPA members feel, Duffy said, that they have done their share.

If the pilots fly, the Continental strategy also will depend on travel agents, according to industry experts. Travel agents traditionally book their clients away from airlines that have pending labor or existing cash flow problems.

It might even be to the IAM's advantage, one source suggested, for Continental to operate a nearly full schedule without union mechanics and let the travel agents do the dirty work by keeping the passengers away. A Continental official said there is no evidence so far that travel agents are booking away from Continental.

In addition to the hassle over salaries, apparently the key issue, Continental management is seeking productivity improvements from the mechanics union, which represents about 2,000 of Continental's 13,000 employes.