after ~1900, common practice rules no longer apply because tonality does not exist in any meaningful sense. pop songs may use chords and progressions borrowed from traditional tonality, but they are as likely to employ modality and arbitrary chord progressions for purely colouristic purposes. trying to analyse a progression like that in functional terms is missing the point.
the progression is in G-ish with an ascending bass up until the part with the repeating chords, which is in a G/E-flat-ish region.