Fix header gap and update write.html opactiy