Per customer, at each PAID order, return the SUM of paid amount_usd from the trailing 7 days INCLUDING that order (i.e. order_ts in [current_ts − 7 days, current_ts]).
This is a time-based window, not a row-based one. Use a RANGE frame with an INTERVAL so the boundary is wall-clock time, not row count.
Sort by customer_id then order_ts ascending.