Try one of approaches:
;
with Q as
(
select *,
LAST_VALUE(col2) over (partition by col1 order by iif(col2 is null, 0, 1), col4 range between unbounded preceding and unbounded following) as lv,
FIRST_VALUE(col3) over (partition by col1 order by iif(col3 is null, 1, 0), col4 range between unbounded preceding and unbounded following) as fv,
row_number() over (partition by col1 order by col4) as rn1,
dense_rank() over (order by col1) as rn2,
max(col4) over () as mx
from atable
)
select
col1,
lv as col2,
fv as col3,
dateadd(minute, rn2, mx) as col4
from Q
where rn1 = 1
order by col1