The trouble with quick fixes is that they only fix it for the time being and although it seems an easy approach to use a negative margin you are adding an extra layer of maintenance for the future.
You use a 'magic number" of 30px which is the amount needed to offset the padding-top on the header. However, as Sam pointed out, you have no padding-top in your code example so the logo will be cut off by 30px. Your fix failed at the first attempt.
Once you make an element dependent on what some other element has to be you create an inter-dependency that is easily broken in the future. Another designer comes along and decides that the header needs 20px padding-top instead and then your logo breaks. You then have top search through the document and change anything else that may have been basing it’s position assuming that there was 30px padding in place.
It is much better to allow elements to sit in the normal flow (where possible) and changing an unrelated element will not have adverse effects. Don’t make elements only work assuming that some other element is going to be there or have specific dimensions.
In some cases you may need to hard code values in order to make things match but these days with the tools available we can avoid fragile code.
There is no such thing as negative padding
I doubt you meant to add padding to your image either as that makes no sense. Use a margin to move images not padding.