Styled and refactored flash code.