How does ordering a new car work?

If you want to factory order certain trim and color, how does it work?

Do you agree on a price beforehand and the dealership has to sell you the car at that price when it comes in?

Can you negotiate after the car comes in if the auto market crashes?

Are deposits typically refundable?

(This isn't about buying used vs. new... I know the math. Just wondering what the process is with ordering cars in Canada).