local aligned triplanar with 3D rotation

nailed everything except rotation. combining “rotate about axis” drives me nuts(
also shader seems heavy. Any ideas?