Our head baker gets this question every week, so here is the short version: feed your starter on a schedule, use a warm spot for the first rise, and be patient with the second.
Weigh your flour instead of using cups, keep notes of every bake, and do not be discouraged by a flat loaf. It still makes excellent toast.