ALTER TABLE bookings ADD COLUMN rescheduled_at TEXT;
ALTER TABLE bookings ADD COLUMN reschedule_count INTEGER NOT NULL DEFAULT 0;
ALTER TABLE bookings ADD COLUMN proposed_start_time TEXT;
ALTER TABLE bookings ADD COLUMN proposed_end_time TEXT;
ALTER TABLE bookings ADD COLUMN proposed_at TEXT;
ALTER TABLE bookings ADD COLUMN proposal_status TEXT;
ALTER TABLE bookings ADD COLUMN proposal_token_hash TEXT;
ALTER TABLE bookings ADD COLUMN refund_status TEXT NOT NULL DEFAULT 'not_requested';
ALTER TABLE bookings ADD COLUMN stripe_refund_id TEXT;
ALTER TABLE bookings ADD COLUMN refunded_amount INTEGER;
ALTER TABLE bookings ADD COLUMN refunded_at TEXT;

CREATE INDEX IF NOT EXISTS idx_bookings_proposal_token_hash ON bookings(proposal_token_hash);
CREATE INDEX IF NOT EXISTS idx_bookings_refund_status ON bookings(refund_status);
