How does Kafka guarantee message ordering within a partition, and what happens to consumer lag during a rebalance?