*651When 14-year-old E.A. and her 11-year old sister, M.A. (together minors or children), came to the attention of the San Diego County Health and Human Services Agency (Agency), they had been living in what the Agency describes as "deplorable" conditions. Minors, who are United States citizens, were living with their parents in Tijuana in an abandoned home with no electricity, no potable water, and with cockroaches crawling near minors' bed. The children had not been to school for over a year. They looked anorexic because J.A. (Mother) and Z.A. (Father) (together parents) fed them only one meal a day.
When ruling in dependency proceedings, " 'the welfare of the minor is the paramount concern of the court.' " ( In re B.D. (2007) 156 Cal.App.4th 975, 983, 67 Cal.Rptr.3d 810.) At the time of the dispositive hearing in this case, there was no evidence that the above-described conditions had changed.
However, misinterpreting Welfare and Institutions Code 1 section 300, subdivision (g), and misapplying Allen M. v. Superior Court (1992) 6 Cal.App.4th 1069, 8 Cal.Rptr.2d 259 ( Allen M. ), the juvenile court dismissed the dependency petitions. Minors appeal.
On appeal, the Agency concedes the court erred, but claims we should affirm because the errors are harmless. We conclude the court's errors are prejudicial and, therefore, we reverse with directions to deny the Agency's motion to dismiss the petitions.
FACTUAL AND PROCEDURAL BACKGROUND
A. Proceedings in Mexico
E.A. and M.A. are United States citizens. In 2016 minors and their parents were living in Tijuana when their parents' neglect came to the attention of the Mexican Department of Integrity of Families (DIF).
They lived in an abandoned home with no potable water, no hot water, and no *349running water for the toilet. Minors told DIF their parents hardly worked, Father used marijuana and drank alcohol, and he taught E.A. to smoke *652marijuana. M.A. told DIF that Mother slept all day, used marijuana, and drank alcohol. Minors had not attended school for over a year. They asked their parents to enroll them in school, but parents refused.
DIF determined that parents were "addicted" to marijuana and removed minors from parents' custody "due to general neglect." Minors lived at a DIF shelter in Tijuana until March 2017.2 During that time, DIF informed parents about the process for reunification. Parents acknowledged they had been made aware of dates and times for a DIF psychological evaluation and socioeconomic study, but they did not show up for either. Parents did not contact, visit, obtain updates, or reunify with the children-"thus abandoning them in the DIF shelter" for seven months. DIF asked the Agency to become involved because minors were United States citizens who were abandoned by parents.
B. Initial Proceedings in the United States
The Agency brought the children to San Diego and filed a dependency petition for each under section 300, subdivision (g) (hereafter section 300(g) ).3 E.A. told the social worker that she did not want to return home and be hungry again. M.A., who had been cutting herself, told the social worker "parents were addicts and she was afraid" of going hungry again. She told the social worker that parents "would use the money they made to buy their marijuana, alcohol, and cigarettes."
The social worker also spoke with minors' 17-year-old brother, who said that parents had allowed M.A. to be cared for by unrelated men, one of whom was a child molester. One of those men tried "to do things" with M.A., but when E.A. told parents the next day, "they blew her off, they said don't say stuff like that, it's not funny."
During its investigation, the Agency learned that in May 2014 Mother had been released from jail for drug trafficking, and both parents were "working for the cartel." Father's criminal history includes a 2009 conviction for possessing marijuana for sale.
*653The Agency searched for parents but could not locate them. The Agency also unsuccessfully tried to reach parents by telephone. The social worker contacted the children's maternal grandmother, who was living in Southern California (Grandmother), as someone who might be a caregiver.
At the detention hearing, the juvenile court found a prima facie showing had been made that minors were persons described in section 300(g). The court gave the Agency discretion to detain minors *350with an approved relative or nonrelative extended family member. Addressing minors, the court said, "I know you guys have been through a lot, and that's going to change." The court promised, "Things are going to get better."
In early April parents' whereabouts were still unknown. The Agency detained minors with Grandmother. Both children "voiced their strong opinion about not wanting to return to their parents." They were also "adamant about not wanting to talk to or see their parents." The social worker stated that under parents' care, minors' "medical, dental, educational, and developmental needs were neglected." Parents had not inquired about minors' well-being since August 2016 and had failed to return the social worker's voice mail messages.
On April 24 parents were located in Tijuana. Meanwhile, Grandmother had taken minors to the dentist, library, and had a meeting with a school counselor to enroll them in summer school. Minors enjoyed living with Grandmother and stated they did not want any communication with parents.
On May 23 the social worker informed Father, who was in Tijuana, of the proceedings and that minors were living with Grandmother. The children were doing well in school and were now interested in speaking to their parents, but not living with them. The social worker scheduled a time for Father to call the children, but he did not call.
At the June 14 jurisdictional hearing, parents appeared in court by telephone. The court appointed separate counsel for each, ordered parents to have supervised visits, and continued the hearing to July 5.
In preparation for the July 5 hearing, the social worker scheduled interviews with parents. Mother did not show for her appointment, but Father attended his. Father said the allegations in the dependency petition were "all lies." He said there was always food and the house was messy only because they had recently moved. Father claimed that he had tried to communicate with minors while they were in DIF's custody, but DIF did not allow him to visit. Father denied having any criminal history. When the social worker confronted him with his conviction for possessing marijuana for sale, Father stated he did not know about the conviction.
*654In June the social worker called Mother three times regarding her missed appointment, but Father answered each call, giving different excuses why Mother was unavailable. The social worker also scheduled parental phone calls with minors-but parents did not call at the appointed times.
The social worker also arranged to have DIF evaluate parents' home. At the July 5 hearing, the Agency requested a continuance to give DIF time to do so. Father's lawyer said his client wanted custody. The juvenile court continued the hearing to "get to the bottom of this."
Meanwhile, Father still had not called minors, claiming he had lost the contact information. On July 18, the social worker reminded Father of the call-in procedure. She also asked him to drug test and to inform Mother she also had to drug test. Father did not show up for the drug test. Mother failed to show up for appointments with the social worker and also failed to drug test.
Minors were thriving with Grandmother. E.A. was attending summer school, and the children were also being tutored. Minors were taking swimming lessons, and M.A. was learning guitar.
Grandmother told the social worker that parents were not calling as scheduled. M.A. said she was "tired of always waiting *351for them [to call] when they don't even call." E.A. stated "the parents don't care about them so she doesn't want to have any contact." Both girls "expressed their feelings about not wanting to reunify with their parents, and instead, would want to remain with ... [G]randmother." Grandmother was willing to adopt or have guardianship.
By August 15 parents still had not called minors and had not drug tested. The Agency still waited for DIF's home evaluation. At the August 22 hearing, parents appeared by telephone. Father's lawyer requested a trial on the section 300(g) petition-advising everyone that Father "is requesting custody of the girls."
As the pretrial conference approached, parents called minors, but not at the scheduled times. Father told the social worker that DIF had not contacted him for the home evaluation. He also said he has two part-time jobs. Again, the social worker asked Father to drug test; however, Father said he could not get time off work to go to the testing facility. Mother promised to drug test the next day. But both parents failed to drug test and did not call minors as scheduled.
At the pretrial conference, the Agency's attorney stated she was still waiting for the results of DIF's home evaluation. Minors' attorney said, "I
*655would like to put all parties on notice that at the trial I will be requesting the Court to confirm [sic ] [the petitions] to proof to a [ section 300, subdivision] (b) count."4 The Agency's attorney said she was "looking into the option of filing an amended petition" alleging jurisdiction under section 300, subdivision (b)(1), but was waiting for more information from DIF before making that decision. The court continued trial for two weeks.
C. Trial
On September 26 DIF reported that parents failed to show up for the home evaluation appointment and that parents were "upset" that DIF was looking for them at their home. DIF reported that parents did not show any interest in doing anything for minors and Mother looked like "a drug addict."
Despite parents' repeated refusal to drug test, failure to call minors as scheduled, and refusal to allow DIF into the home, in an addendum report filed October 2, the social worker, Yezenia Vargas, asked the juvenile court to dismiss the dependency petitions, stating:
"Despite the Agency's concerns that the parents have not had communication with the Agency since 9/13/2017 and they have not followed through with four drug tests or any appointments with DIF for a home evaluation, there is no evidence that the children will be at any risk under the parents ' care. Furthermore, the parents had previously communicated that they would like their children returned to their care and that the mother had expressed that she would have a plan to pick up the children from maternal grandmother." (Italics added.)
Consistent with this recommendation, the Agency's lawyer asked the court to dismiss the section 300(g) petitions. She explained that because parents were requesting *352custody and DIF had not furnished results of the home evaluation, there was insufficient evidence to support findings of abandonment under section 300(g). The Mother's lawyer stated her client and Father were "ready and willing to come and pick up the children."
Minors' lawyer said he had planned to ask the court to amend the petitions to conform to proof under section 300, subdivision (b) -however, because *656the Agency was now requesting dismissal, instead he wanted an " Allen M . hearing."5 The court continued the matter.
D. The Allen M. Hearing
At the hearing the court received the Agency's reports into evidence without objection. E.A. testified that parents' home was an abandoned house with no doors, locks, sinks, or showerheads. There was no hot water and no electricity. To bathe, she used electricity from a neighbor, heated water in a coffee pot, put the water in a bucket and bathed "like a birdbath." E.A testified she would usually eat only once a day, "rarely twice." That one meal usually consisted of "tortillas with cheese, sometimes soup or tortillas with mayonnaise."
E.A. had not been enrolled in school since February 2016. She testified parents spent money "[o]n alcohol and drugs." E.A. testified that Father supplied her with marijuana beginning when she was 11 years old. Parents sell drugs at the house.
With the exception of one telephone call, E.A. has not had any contact with parents since July 2016. While she was living at the DIF shelter for seven months, parents did not call or visit. Recently, a therapist diagnosed E.A. as having post-traumatic stress disorder.
E.A. testified that now living with Grandmother, she was well cared for and was attending school. She feels safe there and M.A. is doing well too.
Vargas testified that parents do not want children to remain with Grandmother, but want them in Tijuana. Vargas had no reason to disbelieve DIF's assessment that parents neglected minors. However, she could not make a "complete assessment" because she lacked information about the conditions of the home, drug test results, and she needed more information from parents. Vargas acknowledged, however, that parents were residing at the same address where they were living when the children left in 2016. Vargas testified there was no evidence that current conditions in parents' home are different from what E.A. described. She stated that parents have not visited children, have never come to court in person, have missed all but one scheduled telephone calls with children, are unwilling to meet with her, and have refused to drug test and allow DIF to evaluate their home.
Despite all this, Vargas testified that the Agency had "no proof" that parents were presently unable or unwilling to care for the children. Vargas *657testified there was no "proof" parents were using drugs "since they have not drug tested." She also testified there was no "proof that the home is safe or unsafe at this time for the minors to return to" because parents had not allowed DIF to evaluate the home. She did concede, however, the Agency had "concerns" that parents were "unwilling to care for their children."6 *353Vargas testified that if the court were to dismiss the petitions, the Agency "would work with [Grandmother] and the parents to facilitate a release to the parents." If necessary, that could include the Agency transporting the children to the border. Vargas stated that once the court dismissed the petitions, the Agency could not be involved in the children's care.
In closing argument, minors' attorney asserted it was not in the children's best interest and welfare to return to their parents. He stated parents "abandoned" the children and "still to this day the parents have not come to visit them, have not called them when they were scheduled." Counsel stated, "[I]t's not in the best interest to send children to a home where it's likely that they will be without food, they will be neglected, where they will be put around parents who are often drunk, who offer them alcohol, offer them marijuana, and generally neglect their needs." Counsel said it was "unreasonable to believe that [the parents' pattern of neglect] is somehow fixed just because of the mere passage of time when we know that they have not gotten any services, they have not gotten any classes, and they are living in the same home that they were in without a shower, without electricity ...."
In response, Mother's lawyer argued there is an "exception[ ]" under section 300(g) where parents "provided appropriate care with a relative who is willing to continue that." Because Grandmother was willing and able to continue supporting minors, the Mother's attorney argued, "it is actually in the welfare of these minors and the interest of justice to dismiss this [p]etition as the Agency is requesting." Father's lawyer agreed.
*658The Agency's lawyer asked the court to dismiss the petitions, stating, "[I]t is always in the interest of justice, if we don't have facts to support a particular count, for that count to disappear and for us to leave this family's life."7
The juvenile court ruled from the bench. First, the court rejected Vargas's testimony that there was no proof parents have abandoned the children. Stating that E.A.'s testimony was "very credible," the court found that parents abandoned the children and left them without any provision for support. The court stated the "only evidence I have ... that disputes that is [Father] telling the social worker that the kids are lying. When given the opportunity to prove that they're lying, he did not cooperate with the DIF evaluation. So we're basically trying to reward him for not cooperating with DIF." The court stated that Father "is hiding something" by not cooperating with DIF and that E.A. "was, in fact, telling the truth."
After making these factual determinations, the court turned to section 300(g), which provides that a child may be declared a dependent of the juvenile court where, among other things, "[t]he child has *354been left without any provision for support ... or a relative or other adult custodian with whom the child resides or has been left is unwilling or unable to provide care or support for the child, the whereabouts of the parent are unknown, and reasonable efforts to locate the parent have been unsuccessful." (Italics added.)
The court stated, "Now, looking at [ section 300(g) ] section by section, I think is very important. It starts out, 'The child has been left without provision, any provision for support,' and then there's a semicolon. What that tells this court is that that's the section in and of itself that can be considered. [¶] I do think that applies in this case." However, the court did not stop there. Instead, adopting the interpretation urged by Mother's attorney, the court construed the last sentence in section 300(g) ("or a relative or other adult custodian with whom the child resides or has been left is unwilling or unable to provide care or support for the child") as an exception "that trumps the first part." Because the children were residing with Grandmother, who was willing and able to provide for them, the court found this "exception" to section 300(g) jurisdiction applied.
In sum, because Grandmother was providing minors good care, the court dismissed the petitions so the children could be returned to parents, who the court had just a minute earlier determined to have abandoned them. Understandably perplexed by the court's statutory interpretation, minors' lawyer asked the court for clarification, and the following discussion ensued:
*659"[Minors' attorney]: Your Honor, for the record, do you believe that the (g), the first section of [ section 300 ](g) applies in this case?
"The Court: Yes, I do.
"[Minors' attorney]: That the child has been left without any provision for support?
"The Court: Yes, I believe that. But the problem is they are currently living with a relative who's willing and able to provide care and support for them.
"[Minors' attorney]: The thing is that-
"The Court: That's in the disjunctive.
"[Minors' attorney]: -the last section says 'or' before it begins.
"The Court: Yes.
"[Minors' attorney]: So I believe only one of these need to apply in order for [ section 300 ](g) to apply.
"The Court: That's not the way I read it.
"[Minors' attorney]: Okay.
"The Court: I think if there is a relative that's able to provide for their care and support, then I think [ section 300 ](g) is no longer relative. I think that trumps the first section, the way I read it. And I could be wrong on that.
"But I want the record to reflect that I do find that they were left in a situation where the parents did not provide for their support, but now that they're with the grandma and she's providing for their support, I think that trumps the first section."
After determining that section 300(g) did not apply, the court granted the Agency's motion to dismiss the petitions. Because the petitions alleged jurisdiction only under section 300(g), the court ruled it would only consider whether dismissal was in minors' best interests "based on that section."
DISCUSSION
I. THE COURT MISINTERPRETED SECTION 300 (g )
A. The Court Erred in Interpreting Section 300 (g )
Section 300(g) provides:
*355*660"A child who comes within any of the following descriptions is within the jurisdiction of the juvenile court which may adjudge that person to be a dependent child of the court: [¶] ...
"(g) The child has been left without any provision for support; physical custody of the child has been voluntarily surrendered pursuant to Section 1255.7 of the Health and Safety Code and the child has not been reclaimed within the 14-day period specified in subdivision (g) of that section; the child's parent has been incarcerated or institutionalized and cannot arrange for the care of the child; or a relative or other adult custodian with whom the child resides or has been left is unwilling or unable to provide care or support for the child, the whereabouts of the parent are unknown, and reasonable efforts to locate the parent have been unsuccessful."
On appeal, the Agency now concedes that the court erred in interpreting section 300(g). The Agency asserts this statute "contains four separate criteria" for adjudicating dependency, each of which is separated in the statute's text by a semicolon. The Agency contends that where, as here, parents' whereabouts are known, the last provision of section 300(g) (that applies where "the whereabouts of the parent are unknown") is simply inapplicable. Accordingly, the Agency asserts that provision does not trump the first part of section 300(g) and, in concluding that it did, the juvenile court erred.
Minors essentially make the same argument, asserting the juvenile court erred by dismissing the petition despite finding they had been left without any provision for support. However, Father contends the juvenile court's interpretation of section 300(g) is correct.8
Interpreting a statute is a legal issue, which we review de novo. ( In re M.W. (2008) 169 Cal.App.4th 1, 4, 86 Cal.Rptr.3d 545.) " 'As in any case involving statutory interpretation, our fundamental task here is to determine the Legislature's intent so as to effectuate the law's purpose.' [Citation.] We begin by examining the statutory language because the words of a statute are generally the most reliable indicator of legislative intent. [Citations.] We give the words of the statute their ordinary and usual meaning and view them in their statutory context." ( In re C.H. (2011) 53 Cal.4th 94, 100, 133 Cal.Rptr.3d 573, 264 P.3d 357, superseded by statute on other grounds as stated in In re Edward C. (2014) 223 Cal.App.4th 813, 824, 167 Cal.Rptr.3d 536.) If the text has an " 'unmistakable plain meaning, we need go no further.' " ( C.H. , at p. 100, 133 Cal.Rptr.3d 573, 264 P.3d 357.)
*661Interpreting section 300(g) logically begins with the first sentence of section 300 itself, which provides, "A child who comes within any of the following descriptions" may be adjudicated a dependent child. " 'The word "any" is not ambiguous. "[T]he ordinary meaning of the word 'any' is clear, and its use in a statute unambiguously reflects a legislative intent for that statute to have a broad application." ' " ( Kurz v. Syrus Systems, LLC (2013) 221 Cal.App.4th 748, 762, 164 Cal.Rptr.3d 554.) "[T]he word 'any' means without limit and no matter what kind." ( Delaney v. Superior Court (1990) 50 Cal.3d 785, 798, 268 Cal.Rptr. 753, 789 P.2d 934.) The plain meaning of "any" in the context of section 300(g) is that dependency jurisdiction may exist if "any" of the *356four separate criteria stated in subdivision (g) of that statute are found to exist.
Moreover, "[w]hile not of controlling importance, punctuation is part of a statute and should be considered in its interpretation ...." ( Roland v. Superior Court (2004) 124 Cal.App.4th 154, 163, 21 Cal.Rptr.3d 151.) Punctuation by a semicolon "is indicative of a complete thought in one clause separate from the other clauses of the statute." ( United States ex rel. Palermo v. Smith (2d. Cir. 1927) 17 F.2d 534, 535.) Additionally, the plain and ordinary meaning of the word "or," when used in a statute, is to designate separate, disjunctive categories. ( People v. Vasquez (2016) 247 Cal.App.4th 513, 519, 202 Cal.Rptr.3d 200.) The word "or" suggests alternatives. ( Rubio v. Superior Court (2016) 244 Cal.App.4th 459, 473, 197 Cal.Rptr.3d 891.) In its ordinary sense in a statute, " ' "the function of the word 'or' is to mark an alternative such as 'either this or that.' " ' " ( California Correctional Peace Officers Assn. v. Tilton (2011) 196 Cal.App.4th 91, 96, 126 Cal.Rptr.3d 623.)
Here, the four criteria for dependency in section 300(g) are separated from each other by a semicolon, and additionally the last one is separated by both a semicolon and the word "or." Accordingly, the plain meaning of the words, when read in the context of the punctuation, is that each of the four criteria is an alternative basis for adjudicating dependency.
Thus, we agree with the Agency that under section 300(g), "a child may be adjudicated a dependent child of the juvenile court under any of the following circumstances:
"(a) The child has been left without provision for his or her support.
"(b) Physical custody has been voluntarily surrendered under [ Health and Safety Code section 1255.7, subdivision (g) ] (parents or others surrendering physical custody of newborn) and the child has not been reclaimed within the 14-day period specified in the statute.
"(c) The child's parent has been incarcerated or institutionalized and cannot arrange for the child's care.
*662"(d) The child has been left with a relative or other adult custodian who is unwilling or unable to provide for the child's care or support, the whereabouts of the parent is unknown, and reasonable efforts to locate the parent have been unsuccessful." ( 16 Witkin, Summary of Cal. Law (11th ed. 2017) Juvenile Court Law, § 200, p. 314 ; see also D.M. v. Superior Court (2009) 173 Cal.App.4th 1117, 1128 [93 Cal.Rptr.3d 418] [ section 300(g) contains "alternative" basis for dependency jurisdiction]; In re Aaron S. (1991) 228 Cal.App.3d 202, 210 [278 Cal.Rptr. 861] ( Aaron S. ) ["[t]he statute is written in the disjunctive"].)
Contrary to the juvenile court's interpretation, none of the four statutory criteria for establishing dependency under section 300(g) trumps any other. Pertinent here, Grandmother's willingness to provide for minors' care, a relevant fact if dependency jurisdiction was sought under the last criteria, is not an exception to, and does not trump, a finding that "the child has been left without provision for his or her support" when dependency jurisdiction is asserted under the first clause of section 300(g).
Citing In re Anthony G. (2011) 194 Cal.App.4th 1060, 123 Cal.Rptr.3d 660 ( Anthony G. ) and Aaron S., supra, 228 Cal.App.3d 202, 278 Cal.Rptr. 861, Father asserts the juvenile court was correct-where the record shows that at the time of the jurisdictional hearing the child is living in a stable home with a caretaker, exercising jurisdiction under section 300(g) is unwarranted. Father is right that *357section 300(g) is inapplicable when a parent arranges for the child to be cared for by a relative or a friend without financial recompense. In that situation, the child has not "been left" without provision for his or her support within the meaning of the first clause in section 300(g). For example, in Anthony G. , before any dependency petition was filed, the mother arranged for the child to live with her and the child's grandmother. ( Anthony G. , supra , 194 Cal.App.4th at p. 1062, 123 Cal.Rptr.3d 660.) Likewise, in Aaron S. , the court held that an incarcerated parent can avoid jurisdiction under section 300(g) by arranging for his or her child's care. ( Aaron S. , supra , 228 Cal.App.3d at p. 212, 278 Cal.Rptr. 861.)
However, in sharp contrast here, parents did not arrange for minors' care with Grandmother. To the contrary, after parents abandoned the children in Tijuana, it was the juvenile court that ordered them detained with Grandmother. Indeed, at the Allen M. hearing, Vargas testified that parents did not want the children to live with Grandmother and had not made arrangements for them to stay with her.
The cases upon which Father relies are distinguishable because here parents made no arrangements for minors' care with Grandmother or anyone else. The facts are more analogous to those in Rosa S. v. Superior Court (2002) 100 Cal.App.4th 1181, 1185, 122 Cal.Rptr.2d 866 [rejecting contention that *663child was not "really abandoned" where child was living with grandparents] and In re Athena P. (2002) 103 Cal.App.4th 617, 630, 127 Cal.Rptr.2d 46 [child left with grandparents was without provision for support because parents did not give grandparents legal custody].)
Father also contends the juvenile court correctly applied section 300(g) because dependency jurisdiction under the first clause of section 300(g) applies only where the parent is unable to provide or arrange care at the time of the hearing . (See In re J.O. (2009) 178 Cal.App.4th 139, 154, 100 Cal.Rptr.3d 276, abrogated on other grounds by In re R.T. (2017) 3 Cal.5th 622, 628, 220 Cal.Rptr.3d 770, 399 P.3d 1.) We agree that is the law; however, there was substantial evidence showing that at time of the Allen M . hearing, parents were not interested in the welfare of children-parents never visited the children in person, were unwilling to meet with the social worker, persistently failed to call minors when scheduled, and stubbornly refused to demonstrate sobriety (by repeatedly refusing to drug test without adequate explanation). Moreover, evidence of a past inability to provide care or support is probative of parents' current ability. ( In re J.O. , at p. 154, 100 Cal.Rptr.3d 276.) Vargas testified there was no evidence that anything had changed from the deplorable conditions E.A. described in her testimony. Thus, contrary to Father's contention, ample evidence supports the juvenile court's determination that at the time of the Allen M. hearing, children were still abandoned by parents, albeit now at Grandmother's home rather than at DIF's Tijuana shelter.
B. The Error Was Prejudicial
The Agency, Father, and Mother contend the juvenile court's erroneous statutory interpretation is harmless error because (1) the children are well cared for by Grandmother, and (2) parents showed no interest or ability to take the children from Grandmother's custody. We disagree for two reasons.
First and foremost, the juvenile court expressly found "the first section of [ section 300 ](g) applies in this case" and "the child[ren] ha[ve] been left without any provision for support." The record clearly *358shows the court dismissed the petitions only because the court erroneously concluded the last clause in section 300(g)"trumps the first section." Thus, the record affirmatively shows that absent the error, the court would not have dismissed the petitions.
Moreover, the record belies respondents' assertions that parents showed no interest or ability in taking the minors from Grandmother. Vargas testified that parents do not plan on having the children stay with Grandmother. To the contrary, parents told Vargas they want the children home with them in Tijuana. Vargas also testified that if the court dismissed the petitions, the *664Agency would have no authority to stop parents from taking the children from Grandmother. Moreover, Vargas testified that upon dismissal, the Agency would "facilitate a release to the parents" and "if necessary" could even transport them to the Mexican border. Additionally, the social worker stated, "[Mother] reported if the girls were to be released to her care she would be able to make arrangements to pick them up from the maternal grandmother." Mother told Vargas that she had "a plan" to take children from Grandmother. Likewise, Father's attorney unequivocally stated, "My client and his wife want the kids returned to them."
Furthermore, the court did not issue a stay of its orders of dismissal, nor did the court order the Agency to refrain from assisting parents in taking the children from Grandmother. The court stated, "I don't think the Agency should go out of the way ... to take these children away from the safe home they're currently in"-but then added, "but that's just my personal opinion."
Thus, the court's erroneous dismissal of the petitions exposes the children to a substantial risk of being returned to the same neglect and abandonment that triggered these proceedings in the first place. The error is prejudicial.
Moreover, because the juvenile court has already determined, on substantial evidence, that minors were left without provision for their support, it is unnecessary to remand for further proceedings other than to enter an order denying the Agency's motion to dismiss the petitions.9
II. ALLEN M. ERROR
In Allen M. , supra , 6 Cal.App.4th 1069, 8 Cal.Rptr.2d 259, this court held that when the department of social services wishes to dismiss a dependency petition over the child's objection, "the juvenile court must determine whether dismissal is in the interests of justice and the welfare of the minor." ( Id . at p. 1071, 8 Cal.Rptr.2d 259.)
Minors contend that there is substantial evidence showing they had been harmed and would be placed at significant risk of future harm in parents' custody. Thus, although the petitions only alleged under section 300(g) that children had been left without any provision for support, the evidence presented at the Allen M. hearing showed neglect, which is a basis for dependency under section 300, subdivision (b)(1).
However, in granting the Agency's motion to dismiss the petitions, the court refused to consider whether dismissal was in the interests of justice or *665in the children's welfare under section 300, subdivision (b)(1). Rather, because the petition *359was brought only under section 300(g), the court believed it was required to determine whether the petition should be dismissed in accordance with the minor's welfare "based on that section "-i.e. section 300(g). (Italics added.) The court exclusively focused on section 300(g) and, after finding that subdivision inapplicable, dismissed the petitions.
On appeal, minors, the Agency, and Mother all contend the juvenile court erred by not considering whether dismissal was in the interests of justice and the welfare of the minors under any basis for dependency jurisdiction enumerated in section 300. The Agency states, "Without considering the totality of the child's circumstances, a juvenile court is not making decisions to protect the child or in the child's best interests."
We agree. In Allen M. , supra , 6 Cal.App.4th 1069, 8 Cal.Rptr.2d 259 we held, "[T]he primary focus of the court is the determination of whether dismissal is in the interests of justice and the welfare of the minor." ( Id . at p. 1074, 8 Cal.Rptr.2d 259.) We added that "judicial review of a dismissal is critical to protect the welfare of the minor." ( Id . at p. 1075, 8 Cal.Rptr.2d 259.) Nothing in Allen M . restricts such determinations to the specific basis for dependency jurisdiction alleged in the particular petition. Moreover, section 390 authorizes dismissal of a petition "if the court finds that the interests of justice and the welfare of the minor require the dismissal ...." Nothing in section 390 limits the appropriate inquiry to the four corners of the petition. As the Agency rightly states-in a case alleging, for example, a "dirty home," the juvenile court cannot ignore evidence coming to the light for the first time in the Allen M . proceeding that a parent has also physically abused the child. Without considering the totality of the circumstances, a juvenile court cannot properly determine whether dismissal promotes the child's welfare.
Accordingly, here the children had the right to present evidence and require the court to determine whether they are described under section 300, including subdivision (b)(1) of that statute, because, if so, dismissal would clearly not be in the interests of justice or consistent with their welfare.10
Disagreeing with this result, Father contends that dismissing the petitions was in minors' interest because "the evidence was quite clear that the *666children were at no risk of harm in the care of their grandmother" and "Father conceded he would not try to remove them from [G]randmother's care." The Agency and Mother make essentially the same argument, but frame it slightly differently. They contend Grandmother's good care demonstrates the court's Allen M. error is harmless.
These assertions are untenable. As discussed ante , dismissing the petitions puts minors at a very substantial risk of being taken from Grandmother and returned to the same abominable conditions that led to these proceedings.11
*360DISPOSITION
The orders dismissing E.A.'s and M.A.'s dependency petitions are reversed with directions to enter orders denying the Agency's motion to dismiss each petition. The matters are remanded to the juvenile court for further proceedings consistent with this opinion.
WE CONCUR:
HUFFMAN, Acting P.J.
AARON, J.
Hereafter all dates are in 2017 unless otherwise indicated.
Section 300(g) provides in part:
"A child who comes within any of the following descriptions is within the jurisdiction of the juvenile court which may adjudge that person to be a dependent child of the court: [¶] ...
"(g) The child has been left without any provision for support; physical custody of the child has been voluntarily surrendered pursuant to Section 1255.7 of the Health and Safety Code and the child has not been reclaimed within the 14-day period specified in subdivision (g) of that section; the child's parent has been incarcerated or institutionalized and cannot arrange for the care of the child; or a relative or other adult custodian with whom the child resides or has been left is unwilling or unable to provide care or support for the child, the whereabouts of the parent are unknown, and reasonable efforts to locate the parent have been unsuccessful."
Under section 300, subdivision (b)(1), dependency jurisdiction exists where "[t]he child has suffered, or there is a substantial risk that the child will suffer, serious physical harm or illness, as a result of the failure or inability of his or her parent ... to adequately supervise or protect the child ... or by the willful or negligent failure of the parent or guardian to provide the child with adequate food, clothing, shelter, or medical treatment ...."
Under Allen M. , supra , 6 Cal.App.4th 1069, 8 Cal.Rptr.2d 259, when the department of social services seeks to dismiss a dependency petition over the child's objection, the juvenile court must determine whether dismissal is in the interests of justice and the minor's welfare. (Id. at p. 1071, 8 Cal.Rptr.2d 259.)
Vargas's conclusion that there was no "proof" to support dependency jurisdiction is very troubling. Common sense suggests that a parent who consistently refuses to drug test without an adequate explanation does so because he or she knows the results will show substance abuse. (In re Noah G. (2016) 247 Cal.App.4th 1292, 1304, 203 Cal.Rptr.3d 91 ; In re Christopher R. (2014) 225 Cal.App.4th 1210, 1217, 171 Cal.Rptr.3d 14 [each missed drug test is properly considered the equivalent of a positive test result].) Similarly, the obvious and compelling inference from parents' refusal to allow a home evaluation is the home remains in the deplorable conditions that led to the minors' removal in the first place. But Vargas drew the exact opposite inferences, concluding that as a result of parents' stonewalling she had no "proof" to support dependency jurisdiction, and thus the petitions should be dismissed.
On appeal the Agency is represented by a different deputy county counsel and has disavowed this argument.
Mother's position on this issue is unclear. She joins in the briefs submitted by "her Co-Respondents;" however, the Agency and Father disagree on the proper interpretation of section 300(g).
Because we reverse on this ground, it is unnecessary to consider minors' contention that the juvenile court also erred in refusing to permit evidence of E.A.'s post-traumatic stress disorder.
Section 348 states that the provisions of Code of Civil Procedure on variance and amendment of pleadings in civil actions apply in juvenile dependency proceedings and petitions. Under those statutes, a court may allow amendments to conform to proof so long as those amendments do not "mislead a party to his or her prejudice." (See In re Andrew S. (2016) 2 Cal.App.5th 536, 544, fn. 4, 206 Cal.Rptr.3d 304.) In this case, evidence of minors' neglect was no surprise. On August 22-nearly two months before the Allen M. hearing-minors' attorney stated, "I do believe that a [section 300, subdivision] (b) petition should be looked into", and Father's lawyer replied, "I anticipate there is going to be a new petition filed."
Our disposition of the statutory interpretation issue in part I makes it unnecessary to remand for the juvenile court to exercise its discretion in determining whether dismissal is in the interests of justice and the welfare of the minor.