-- Clean up and insert all messages from the user's list
TRUNCATE TABLE `app_messages`;

INSERT INTO `app_messages` (`message_key`, `message_value`, `category`) VALUES
-- Errors
('auth_login_required', 'Please login first Test message', 'error'),
('product_not_found', 'Product not found', 'error'),
('min_rental_duration', 'Minimum rental duration is {min} days', 'error'),
('booking_conflict', 'Product already booked for selected dates', 'error'),
('offer_not_found', 'Invalid offer', 'error'),
('already_rated_seller', 'You have already rated this seller', 'error'),
('rating_window_expired', 'Rating window has expired', 'error'),
('order_not_found', 'Order not found', 'error'),
('auth_not_logged_in', 'Not logged in', 'error'),
('access_denied_msg', 'Access denied', 'error'),
('missing_product_id', 'Missing product id', 'error'),
('product_image_required', 'Product must have at least one image', 'error'),
('product_delete_failed', 'Failed to delete product', 'error'),
('offer_acceptance_limit_exceeded', 'Offer Acceptance Window has closed. You can no longer accept this offer.', 'error'),
('product_already_sold', 'Product already sold! Cannot accept more offers.', 'error'),
('offer_rejection_limit_exceeded', 'Cannot reject: Rejection window expired (must reject within 1 day of acceptance OR 1 day before pickup)', 'error'),
('offer_rejection_denied_order_status', 'Cannot reject: The linked order is already {status}.', 'error'),
('brand_create_denied', 'You need a reliability score of at least 25 to create a brand', 'error'),
('brand_not_found', 'Invalid brand', 'error'),
('brand_delete_denied_products', 'Cannot delete brand with existing products. Remove products first.', 'error'),
('order_dispatch_denied', 'Order cannot be dispatched', 'error'),
('select_both_dates', 'Please provide both dates', 'error'),
('request_not_found', 'Request not found', 'error'),
('otp_send_failed_msg', 'Failed to send OTP. Please try again.', 'error'),
('registration_failed_msg', 'Registration failed. Please try again.', 'error'),
('enter_email_msg', 'Please enter your email.', 'error'),
('email_not_registered_msg', 'Email not registered. Please register first.', 'error'),
('enter_credentials_msg', 'Please enter email and password.', 'error'),
('invalid_credentials_msg', 'Invalid email or password.', 'error'),
('invalid_request_msg', 'Invalid request.', 'error'),
('invalid_otp_msg', 'Invalid or expired OTP.', 'error'),
('rejection_reason_required_msg', 'Please provide a reason for rejection', 'error'),
('delivery_assign_denied_status', 'Only confirmed orders can be assigned to delivery persons', 'error'),
('invalid_delivery_person_msg', 'Invalid delivery person', 'error'),
('delivery_not_available', 'Delivery request not available', 'error'),
('delivery_pickup_time_range_error', 'Pickup time must be at least 4-5 hours before rental start', 'error'),
('delivery_drop_time_range_error', 'Drop time must be at least 4-5 hours before rental start', 'error'),
('delivery_sell_drop_range_error', 'Drop time must be at least 1 day before max delivery date', 'error'),
('delivery_cancel_rent_limit_error', 'Cannot cancel within 3 days of rental start', 'error'),
('delivery_cancel_sell_limit_error', 'Cannot cancel within 3 days of max delivery date', 'error'),

-- Success
('offer_sent_success', 'Offer sent successfully!', 'success'),
('offer_cancelled_success', 'Offer cancelled successfully', 'success'),
('review_submit_success', 'Review submitted successfully!', 'success'),
('order_cancel_success', 'Order cancelled successfully', 'success'),
('payment_success', 'Payment successful! Order confirmed.', 'success'),
('dates_update_success', 'Rental dates updated successfully!', 'success'),
('product_update_success', 'Product updated successfully', 'success'),
('product_delete_success', 'Product deleted successfully', 'success'),
('date_change_requested_success', 'Date change requested from buyer.', 'success'),
('offer_accepted_success', 'Offer accepted successfully', 'success'),
('offer_rejected_success', 'Offer rejected successfully', 'success'),
('buyer_rated_success', 'Buyer rated successfully!', 'success'),
('brand_create_success', 'Brand created successfully', 'success'),
('brand_update_success', 'Brand updated successfully', 'success'),
('brand_delete_success', 'Brand deleted successfully', 'success'),
('order_dispatched_success', 'Order marked as dispatched', 'success'),
('notifications_mark_read_success', 'All notifications marked as read', 'success'),
('date_change_sent_success', 'Date change request sent to buyer.', 'success'),
('response_sent_success', 'Response sent successfully', 'success'),
('rental_return_confirmed_success', 'Rental return confirmed successfully', 'success'),
('order_delivered_success', 'Order marked as delivered successfully', 'success'),
('return_confirmed_buyer_rate', 'Return confirmed! Buyer can now rate you.', 'success'),
('otp_sent_verify_msg', 'OTP sent to your email. Please verify.', 'success'),
('otp_sent_login_msg', 'OTP sent to your email.', 'success'),
('welcome_super_admin_msg', 'Welcome Super Admin!', 'success'),
('welcome_admin_msg', 'Welcome Admin!', 'success'),
('welcome_delivery_msg', 'Welcome Delivery!', 'success'),
('welcome_seller_msg', 'Welcome Seller!', 'success'),
('welcome_buyer_msg', 'Welcome!', 'success'),
('login_success_msg', 'Login successful!', 'success'),
('logout_success_msg', 'Logged out successfully.', 'success'),
('product_approved_success', 'Product approved successfully', 'success'),
('product_rejected_success', 'Product rejected', 'success'),
('user_blocked_success', 'User blocked successfully', 'success'),
('user_unblocked_success', 'User unblocked successfully', 'success'),
('delivery_assigned_success', 'Delivery person assigned successfully', 'success'),
('bgv_cleared_success', 'BGV cleared successfully', 'success'),
('order_status_updated_success', 'Order status updated', 'success'),
('rental_extended_success', 'Rental date extended successfully', 'success'),
('profile_updated_success', 'Profile updated successfully', 'success'),
('kyc_submitted_success', 'KYC details submitted for verification', 'success'),
('delivery_cancelled_success', 'Delivery request cancelled. It has been returned to the pool.', 'success');
