EXCLUSIVE: It’s a happy Fourth of July in Hollywood. After nearly two months of talks and three last-minute 24-hour extensions, a tentative agreement has been reached on a new three-year SAG-AFTRA film and television contract. Terms were not announced.

Here is the sides’ verbose joint statement: “Screen Actors Guild – American Federation of Television and Radio Artists (SAG-AFTRA) and Alliance of Motion Picture and Television Producers (AMPTP) today reached tentative agreement for motion picture production. Negotiations, which began on May 5th, resulted in a new 2014 Producers-SAG-AFTRA Codified Basic Agreement and an industry-wide 2014 SAG-AFTRA Television Agreement as the successor agreement to Screen Actors Guild Television Agreement, Exhibit A of the AFTRA National Code of Fair Practice for Network Television Broadcasting, The CW Supplement, and the basic cable agreements. The terms of the new agreements will be presented to the SAG-AFTRA National Board of Directors at its July 12 meeting.”

The deal still must be ratified by the guild’s members. It replaces the old contract, which had been set to expire on June 30 but was extended to allow bargaining to continue. The ratification process will take several weeks to complete, during which time the terms of the old contract will remain in effect.

The talks went much longer than either of the recent DGA or WGA contract negotiations. While that was expected, few anticipated that negotiations would go past the expiration of the current contract. The DGA reached an agreement after just a few weeks of talks late last year. And while the WGA’s negotiations took longer and were more tense, the writers also reached an agreement with the studios and networks after less than a month. Both unions hammered out and ratified their deals before the expiration of their current contracts.

This is the first film and TV agreement the actors union has negotiated since the 2012 merger of SAG and AFTRA. It was complicated by the union’s attempt to merge its two separate TV contracts and by the fact that the guild still has two different pension and health plans.