Survival rates of farmed salmon in Scotland have hit record highs, driven by more than £1 billion of investment in technology and fish health.