Self-assembly of amorphous biophotonic nanostructures by phase separation