Unix time is the number of non-leap seconds since January 1, 1970, but the rotation of the Earth is slowing down.
The second is defined in terms of the oscillations of light waves, specifically the radiation corresponding to the transition between the hyperfine levels of the ground state of the caesium-133 atom.
Cesium was chosen for atomic clocks due to its ease of isolation, and 9,192,631,770 periods of radiation were chosen for backward compatibility with the historical definition of a second.
The length of a year and the historical definition are no longer relevant, as the current definition of a second is based on the number of radiation periods.