Here's how "but" is used in the sentence:
* It connects two contrasting ideas. The first idea is that the speaker loves pizza. The second idea is that they are trying to eat healthier.
* It creates a sense of opposition. Eating pizza and eating healthy are generally considered opposites.
* It shows a change in direction or thought. The speaker is acknowledging their love for pizza, but then shifts to talking about their efforts to eat healthier.
Let me know if you'd like to see more examples or have other questions!