UPDATES! Can my company fire me or reduce the size of my grant just before the vesting of my stock options or restricted stock/RSUs?
In short, yes, assuming this termination is made for good-faith reasons, such as business downsizing or poor work performance. Most employees are "at will," which means you are hired and fired at the company's discretion without a contract. An employer is free to terminate "at will" employees at any time. As reported by The Wall Street Journal and The myStockOptions.com Blog, instead of firing someone before vesting, the company can restructure the stock grant in a way that returns some unvested stock or options to the company for reuse in grants to others.
Some state courts have implied covenants of good faith and fair dealing by employers when a bad-faith termination results in employees losing benefits almost earned by past services. Your stock plan and grant agreements, or perhaps any severance arrangement, may also cover this situation. Also failing in the courts are arguments that unvested options are protected by state laws that require all wages to be paid for work before employment termination. (See a decision made in 2010 by the Maryland Court of Appeals.)
In general, to avoid costly lawsuits, companies consider future vesting dates when terminating employees. They may delay the termination date, extend it by using "paid time off" days, or accelerate the upcoming vesting to avoid appearing to terminate an employee merely to forfeit soon-to-be vested shares.
In Suzuki v. Abiomed Inc. (2017), a federal district court in Massachusetts allowed a covenant of good faith and fair dealing to be applied to potentially protect someone with unvested performance-based grants. This decision, which concerned the company's motion to dismiss the case, does not mean that employees who have grants with individualized performance goals cannot be terminated. The ruling means only that a termination made in bad faith cannot cancel the payout when the compensation "is connected to work already performed." The case is further discussed by a commentary from Sherin & Lodgen.