def args_to_seconds(args: list) -> int:
    """Converts command line args to total seconds

    Min return is 0, defaults to this on any issues.
    Max seconds is 359,999 (99 hours, 59 minutes, 59 seconds)
    If minutes are provided, seconds are limited to max 59
    if hours are provided, minutes and seconds are limited to max 59
    """
    args_list = [
        0,
        0,
        0,
    ] + args

    hours = args_list[-3] * 3600 if 0 < args_list[-3] < 100 else 0

    max_minutes = 60 if hours else 6000
    minutes = args_list[-2] * 60 if 0 < args_list[-2] < max_minutes else 0

    max_seconds = 60 if hours or minutes else 360_000
    seconds = args_list[-1] if 0 < args_list[-1] < max_seconds else 0

    return hours + minutes + seconds