New Customer Detector
Checks if the logged-in customer has ever placed an order; if not, shows the offer—if yes, redirects to your main shop.
{% if customer %}
{% if customer.orders_count == 0 %}
<!-- New customer: show the offer page -->
<div class="offer-container">
<h1>Exclusive First-Time Offer</h1>
<!-- Your landing page content here -->
</div>
{% else %}
<!-- Returning customer: redirect -->
<script>
window.location.href = '/';
</script>
{% endif %}
{% else %}
<!-- Not logged in: show offer (they may buy as guest or log in) -->
<div class="offer-container">
<h1>Exclusive First-Time Offer</h1>
</div>
{% endif %}