Child custody is decided based on the best interests of the child, with considerations such as the child’s needs, parental roles, and the stability each parent can provide.