systemctl edit always writes to override.conf. Over time that one file collects resource limits, environment lines and hardening experiments all mixed up.
The --drop-in= option picks the file name instead:
sudo systemctl edit --drop-in=limits myapp.service
sudo systemctl edit --drop-in=hardening myapp.service
Each one opens your editor on its own file, limits.conf and hardening.conf in /etc/systemd/system/myapp.service.d/. After saving, systemctl prints a line like Successfully installed edited file '/etc/systemd/system/demo.service.d/nice.conf', reloads the unit, and the new setting is live.
I like small named files, because they make the history readable. You see what each file is for, you can delete one experiment without touching the rest, and config management can own one file while you test with another. systemctl cat myapp.service still shows everything merged in order.
The files are applied in alphabetical order, and for settings that take one value the last file wins. If two drop-ins set the same thing, name them with number prefixes, such as 50-limits and 90-local, so you know which one wins. The option is not in very old systemd; Ubuntu 24.04 has it.
Further reading: systemctl man page, systemd.unit man page