The actual mechanics of constructing an index portfolio are quite simple in theory. Whilst not practical, you could do it yourself. Lets say you have $10m to invest.
If a stock makes up 5% of an index, you will need to buy $500k worth of that stock. If a stock is 0.25% you buy $25,000 worth of shares. Just carry on in this manner until you buy every stock in the index.
Your portfolio revalues in line with the change in value of all the stocks in the index. There's no further buying and selling required. However, if you wish to add to your portfolio, you need to buy all stocks in proportion to the number you currently hold in all them. Should a stock crash, it will be replaced, but not necessarily straight away.
See attached excel doc for a quick and hopefully not too complicated example of building an index portfolio.
Regarding your specific question, indexes are typically "rebalanced" every quarter. You do actually lose, because if a very large stock crashes it gets replaced eventually by one that is coming in at the tail end, all else being equal, so the overall market capitalisation of the index is still smaller. You may wonder why re-balancing doesn't occur more frequently (even daily perhaps) but you can easily see that index funds would have to buy and sell stock daily on companies that are on the margin of inclusion/exclusion. It's going to fall apart quite quickly and trading in those stocks will be very volatile, thus causing more index problems.
This actually presents a bit of an opportunity for a canny investor to trade stocks on the margins because as soon as a stock is added to/removed from an index, ETFs and other tracking funds have no choice but to buy & sell quite heavily in those stocks shortly after. You can take advantage if you really know what you are doing.