Zagreb is the capital of Croatia, and does not close. Some restaurants may do, but bars and cafes hang up infra-rad heaters outside and give out blankets and hot drinks. My favourite winter drink in Zagreb is hot chocolate. Tolkien's House Cafe is famous for it. In the Advent period, there is a lot happening. They even have a website devoted to Advent in Zagreb. Check it out. Great place, anytime.
As for the coast, remember the further south you go, the warmer it is. But seasonal tourism closes down many of the summer places, and their staff go back home to the interior until the spring. To see what is open in Zadar, Split, Korcula or Dubrovnik look at their city websites, all in English - check the UK flag icon. If you need accommodation, private homes advertised on AirBnB or Booking.com may still be open when big hotels are closed Year-round tourism is the new push, however. There are major parties at New Year's in popular hotels, often booked months in advance. Then they close again for winter.
Buses and trains run in winter, and can be very atmospheric. The interior of Croatia can be bitterly cold, but not the coast. There are people who go the islands in winter specifically for peace and quiet and empty beaches . You will be welcomed.