(c) Sentence the juvenile offender to detention pursuant to this act for a period not to exceed thirty (30) days for each act, omission, or status that is prohibited by the federal, state, local, or municipal law or ordinance by reason of minority only. The sentence shall not be executed unless the act, omission, or status is in violation of 18 U.S.C. 922(x) or the court finds that the juvenile offender has violated the court's decree imposing the sentence as provided in this subsection. If the court, after notice and hearing, finds that a juvenile offender has violated the court's decree imposing the sentence under circumstances that bring the violation under the valid court order exception of the federal juvenile justice and delinquency prevention act of 1974, as amended, the court may commit the juvenile offender to detention for the period of detention previously imposed at sentencing;