def restore_needed_space(css: str) -> str:
    """Fix CSS for some specific cases where a white space is needed.
    """
    return css\
        .replace('!important', ' !important')\
        .replace('@media(', '@media (')\
        .replace('data:image/jpeg;base64,', 'data:image/jpg;base64,')\
        .rstrip('\n;')