The issue of airfare is quite the task to answer. When I worked for AA (and latter ATUSA) I learned about "yield management". On each flight a dedicated number (always kept a secret) of seats were allocated at a particular fare with its own particular rules - called a fare basis code. When those fares sell out the other seats are sold at a different fare. There can be many different fares [each with its own annoying rules] for the same flight. Fares can also change for a particular flight. The yield management team watch the flight loads and "update" the fares as needed. Changes are brought on by sales from competitors, how many seats are being sold or not sold (supply and demand), the fluctuating price of fuel, holidays, and the list goes on. This is why we were taught to always state "no fare is guaranteed until purchased".
To complicate things further, travel / tour operators and .com travel websites set up contracts with airlines and have their own fares. They pay the airline the contracted fare, adjust it and then sell it to you. This I learned at ATUSA. The contracted fares have different rules and are subject to yield management from the airline. The contracted fares are simply that, not contracted seats; meaning the agency is not (sometimes it can, bur rarely) allocated a number of seats on a particular flight. This can be arranged with smaller airlines, called public charters. When it comes to the major airlines the yield management team will allocate some seats for the agencies. This number can change at anytime depending on the flight load.
Another way of looking at this is, you are buying a fare, not a seat. Fares are subject to change and are not guaranteed until purchased. Welcome to yield management.