"De Lijn" is the Flemish public transport company. They serve Flanders, and have very basic services in Brussels (busses from Flanders to the main railway stations in Brussels and vice versa). De lijn offers bus, tram and metro. They do not offer trains! Trains are provided by the NMBS/SNCB.
When buying a prepaid card (10 journeys for around 14 euros), it's valid on all their vehicles in all cities. A day pass also offers unlimited use of all their services, except some express services in Limburg. Looking at your question, this doesn't matter for you, since you'll be visiting Ghent and Bruges.
If I were you, I'd travel to Ghent and Bruges by train (30 minutes and 60 minutes from Brussels). You can't get from Brussels to Bruges by bus, or it'd take you a while (read: 4 hours or more). In Ghent and Bruges, De Lijn has an extensive network of busses (both cities) and trams (Ghent) which will allow you to get around wherever you want.
About NMBS/SNCB tickets: If you are less than 26 years old you can get cheaper railway tickets (go pass or go pass one). During weekends there are often special "weekend tickets" with a return price of about 14 euros.
About transport inside Brussels:
As I told earlier, De Lijn doesn't cover Brussels except for some routes to the stations. For extensive travel in Brussels, you can use the MIVB. They also offer 10-journey cards, which are (or should) also be accepted by de lijn in Brussels. These tickets are called "JUMP". I don't know the exact terms and conditions of using a JUMP card on De Lijn.
Tl;dr: get a (multi)day pass for transport inside and around cities, use the train in between.
More info: https://www.delijn.be/en/vervoerbewijzen/ritkaarten-dagpassen/dagpas.html?vertaling=true
Sources: De lijn website, MIVB website, I'm a Belgian resident