Normally when you're online, your home and resource bases cannot be attacked. However, to prevent players from staying online 24/7 (to avoid ever being attacked), we allow other players to attack you even if you're online, if you've been online for several hours during one day.
We will notify you before this goes into effect. After the grace period, an enemy attack can interrupt your game at any time!
NOTE: If you start an attack on another player, your attack can still get interrupted until you deploy troops. As soon as you have deployed troops, your attack can not get interrupted anymore.
The reason for handling it this way is to prevent players from gaining an extra "shield" by starting attacks without ever deploying troops and just keeping the timer running.