Every account runs on a handful of core resources (commonly Iron, Food, Coins/Cash, and Oil once you're far enough along) plus whatever season-exclusive resource is active. The single most reliable way to avoid resource problems is to never let your production buildings, storage capacity, or gathering queues sit idle - each hour of idle production is value that never comes back.
Protect your resources during vulnerable windows: use resource-protection items or shields when you're offline for long stretches or holding a large stockpile, since raids from other players are a normal part of the game once you're past the earliest protection period. Spend down resources regularly rather than hoarding past your storage cap, since anything over cap is wasted the moment it's produced.
Alliance-shared resources (gifting, alliance help requests, and Alliance Tech donations) are also worth using daily even if the individual amounts feel small - the value compounds significantly over a season when everyone participates consistently.