Volokh commented on this. There is no 2nd Amendment issue, nor does federal law. It may be illegal in some states, depending on whether age is included in public accommodation anti-discrimination laws. For instance, Conn. Gen. Stat. §§46a-64 says
(a) It shall be a discriminatory practice in violation of this
section: (1) To deny any person within the jurisdiction of this state
full and equal accommodations in any place of public accommodation,
resort or amusement because of race, creed, color, national origin,
ancestry, sex, gender identity or expression, marital status, age,
lawful source of income, intellectual disability, mental disability or
physical disability, including, but not limited to, blindness or
deafness of the applicant, subject only to the conditions and
limitations established by law and applicable alike to all persons;
§46a-63 defines "public accommodation"
(1) “Place of public accommodation, resort or amusement” means any
establishment which caters or offers its services or facilities or
goods to the general public, including, but not limited to, any
commercial property or building lot, on which it is intended that a
commercial building will be constructed or offered for sale or rent
Public accomodation laws are how states deal with discrimination in sales, such as selling wedding cakes
Illinois 775 ILCS 5/1-103 likewise prohibits age discrimination in public accomodations, but defines "age" as "the chronological age of a person who is at least 40 years old". Connecticut used to define "age" as "any age between forty and sixty-five, inclusive", but that clause was deleted.
Lousiana also prohibits age discrimination (La. Rev. Stat. §51:2247). Their statement about age likewise limits anti-discrimination protection to "individuals who are at least forty years of age". Maryland in MD State Govt Code § 20-304 also bans age discrimination, and does not redefine "age" or limit the scope of those ages that are protected.
So while it is generally legal to refuse to sell goods to the young (and sometimes mandatory, e.g. alcohol, firearms, tobacco), there are a few states where such a policy would violate state anti-discrimination laws. There can also be city laws (Seattle has very broad anti-discrimination laws), but they exclude age from the Public Accommodation subset of discrimination.