When do you mark the last day of your period?

Co
I've always been a bit confused as to exactly which day I should mark as the last day of my period? I tend to have a few days of light/brownish discharge at the end of my cycle. So should I mark my last day when the red flow stops or when all discharge is completely gone? Any thoughts?? Thanks ladies!