The factor to focus on is the fertility and the fraction of working adults. Germany has a very traditional view of the labour market and women often have to stop working for years when having children. This means that a large group of women don't work, or (equally bad for the economy), a large group of women chose not to have kids.
The only proven solution is subsidized childcare, longer parental leave, individual taxation.
This is an interesting comment to me, because I'm trying to think of example country pairs in which a country with subsidized childcare, longer parental leave, and individual taxation has a higher fertility rate than an otherwise similar country that lacks those things. The United States continues to have a higher fertility rate than many countries in Europe that have more subsidized childcare and longer mandated parental leave than the United States, for example, so I'm not sure that these public policy factors outdo the effect of other cultural and economic factors in either raising or lowering the country-wide fertility rate.
I've noticed countries that have huge immigration can offset any birthrate.
Japan is in trouble cause they don't have any immigration laws.
The fertility rate among founders in Silicon Valley is probably even lower, but that group of people is creating an immense amount of value for society in return for not creating as many kids.