The Architecture of Flow