49ers bid 'Stick farewell with dramatic playoff-clinching win