I assume you're using Bitcoin-Qt, i.e. the reference implementation.
Bitcoin-Qt works with accounts, not addresses. The balance of your wallet is the sum of each account balance. The purpose of accounts is to compartmentalize payments in labels such as "Savings", "Salary", "Friends", etc. for your own convenience.
Each account has many Bitcoin addresses associated with it, though you'll only see one at a time (the last one). As soon as you get a payment in the displayed address, its address will change. You can still receive payments at that address, though that is considered bad practice due to anonimity issues.
Now to answer your question: "I read that when I buy something [...] I must then spend the rest to another unused address [...] as the first address becomes unsafe or the change is lost in mining fees or something."
Bitcoin works a bit different than money. A payment is:
- References to earlier payments you received (i.e. the sources of money)
- A list of pairs of (address + amount) (i.e. destinations)
When you reference an earlier payment you must spend it as a whole. You can't split it, like you wouldn't be able to split a 10€ bill in two 5€ bills.
For example: let's say you receive 10BTC payment. If you want to spend 1BTC you can't split it in 1BTC (paid) + 9BTC (left in address). You have to spend it all!
On the other hand, that's pretty much like paying 1BTC to someone else and sending 9BTC back to yourself. You could pay yourself to your original address, but Bitcoin-QT is smart enough to create a new (invisible to you) address which receives this change. The advantage of this "change address" is that I can no longer link your payment back to yourself:
Did you spend 1BTC and sent 9BTC as change, or perhaps spent 9BTC and sent 1BTC back as change? If you reused the same address, the change is obviously the one with the same address. If you let Bitcoin-Qt take care of it both will be new addresses and the money can't be traced back to you. This is what you meant with "the address becomes unsafe".
The key is: don't worry about this! Bitcoin-Qt will take care of all this for you! As long as you understand your accounts, addresses are disposable.
Now... what happens if Bitcoin-Qt somehow didn't send the change back to you? Imagine you just said "I want to send 1BTC out of this 10BTC" but Bitcoin-Qt forgets to send the change (this WON'T happen using Bitcoin-Qt, it's just a thought experiment).
Transaction fees are the difference between input and output, i.e.
input - output. If somehow you only send 1BTC but forget to send back 9BTC of change to yourself, whoever mines this block will get the leftovers!