{% load static %}
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="MISRY Lehyam is a premium Ayurvedic wellness formula crafted with rare herbs. Order Misry Lehyam 100g for ₹1,699 with free shipping.">
<meta name="theme-color" content="#08110D">
<title>MISRY AYUR | Premium Ayurvedic Wellness</title>
<link rel="icon" href="{% static 'orders/assets/icons/favicon.ico' %}" sizes="any">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Cormorant+Garamond:wght@500;600;700&family=Manrope:wght@400;500;600;700;800&display=swap" rel="stylesheet">
<style>
:root{
  --charcoal:#08110D;
  --charcoal-2:#0c1812;
  --emerald:#0E5F43;
  --emerald-soft:#1d7b59;
  --gold:#C9A24A;
  --cream:#FFF7E8;
  --beige:#E7D8B8;
  --brown:#6B4226;
  --glass:rgba(255,247,232,.08);
  --line:rgba(201,162,74,.18);
  --shadow:0 28px 90px rgba(0,0,0,.48);
  --radius:26px;
}
*{box-sizing:border-box}
html{scroll-behavior:smooth}
body{margin:0;background:var(--charcoal);color:var(--cream);font-family:Manrope,Inter,sans-serif;overflow-x:hidden}
body::before{content:"";position:fixed;inset:0;z-index:-3;background:radial-gradient(circle at 18% 8%,rgba(14,95,67,.42),transparent 34%),radial-gradient(circle at 78% 16%,rgba(201,162,74,.24),transparent 30%),radial-gradient(circle at 50% 82%,rgba(107,66,38,.24),transparent 34%),linear-gradient(180deg,#08110D,#0b1510 52%,#07100c);pointer-events:none}
body::after{content:"";position:fixed;inset:0;z-index:-2;background-image:linear-gradient(rgba(255,255,255,.025) 1px,transparent 1px),linear-gradient(90deg,rgba(255,255,255,.02) 1px,transparent 1px);background-size:80px 80px;mask-image:linear-gradient(to bottom,rgba(0,0,0,.5),transparent 78%);pointer-events:none}
img{max-width:100%;display:block}
a{color:inherit}
.container{width:min(1160px,calc(100% - 32px));margin-inline:auto}
.nav{position:sticky;top:0;z-index:30;border-bottom:1px solid rgba(201,162,74,.12);background:rgba(8,17,13,.72);backdrop-filter:blur(18px)}
.nav-inner{height:76px;display:flex;align-items:center;justify-content:space-between;gap:18px}
.logo{width:104px;filter:drop-shadow(0 0 20px rgba(201,162,74,.22))}
.nav-links{display:flex;gap:24px;list-style:none;padding:0;margin:0;color:rgba(255,247,232,.7);font-size:12px;font-weight:800;letter-spacing:.12em;text-transform:uppercase}
.nav-links a{text-decoration:none}.nav-links a:hover{color:var(--gold)}
.btn{border:0;border-radius:999px;padding:14px 22px;font:800 12px/1 Manrope,sans-serif;letter-spacing:.12em;text-transform:uppercase;cursor:pointer;text-decoration:none;display:inline-flex;align-items:center;justify-content:center;gap:8px;transition:.28s ease}
.btn-primary{color:#08110D;background:linear-gradient(135deg,#F6D98B,var(--gold));box-shadow:0 18px 42px rgba(201,162,74,.28)}
.btn-primary:hover{transform:translateY(-2px);box-shadow:0 24px 62px rgba(201,162,74,.36)}
.btn-ghost{border:1px solid var(--line);background:rgba(255,247,232,.06);color:var(--cream)}
.btn-ghost:hover{border-color:rgba(201,162,74,.42);background:rgba(201,162,74,.1)}
.hero{position:relative;min-height:calc(100vh - 76px);display:grid;align-items:center;padding:72px 0 54px;overflow:hidden}
.hero-grid{display:grid;grid-template-columns:minmax(0,1fr) minmax(320px,520px);gap:48px;align-items:center}
.eyebrow{display:inline-flex;align-items:center;gap:10px;color:var(--gold);font-size:12px;font-weight:800;letter-spacing:.18em;text-transform:uppercase}
.eyebrow::before{content:"";width:36px;height:1px;background:var(--gold)}
h1,h2,h3{font-family:"Cormorant Garamond",serif;margin:0;color:var(--cream)}
h1{font-size:clamp(56px,9vw,112px);line-height:.88;letter-spacing:-.03em;margin:18px 0}
.hero-copy{max-width:640px;color:rgba(255,247,232,.72);font-size:17px;line-height:1.9}
.hero-actions{display:flex;gap:14px;flex-wrap:wrap;margin-top:30px}
.hero-actions .btn{min-height:58px;padding:19px 30px;font-size:13px;letter-spacing:.1em}
.hero-meta{display:grid;grid-template-columns:repeat(3,1fr);gap:12px;margin-top:34px;max-width:620px}
.meta-card,.glass{border:1px solid var(--line);background:linear-gradient(145deg,rgba(255,247,232,.1),rgba(255,247,232,.035));box-shadow:var(--shadow);backdrop-filter:blur(18px);border-radius:var(--radius)}
.meta-card{padding:18px}.meta-card strong{display:block;color:var(--gold);font-size:20px}.meta-card span{display:block;color:rgba(255,247,232,.58);font-size:12px;margin-top:5px}
.spotlight{position:relative;min-height:580px;display:grid;place-items:center}
.spotlight::before{content:"";position:absolute;width:min(520px,82vw);aspect-ratio:1;border-radius:50%;background:radial-gradient(circle,rgba(201,162,74,.22),rgba(14,95,67,.16) 42%,transparent 70%);filter:blur(8px);animation:pulse 5s ease-in-out infinite}
.product-stage{position:relative;z-index:2;width:min(450px,86vw);padding:42px;border:1px solid rgba(201,162,74,.2);border-radius:42px;background:linear-gradient(145deg,rgba(255,247,232,.1),rgba(255,247,232,.02));box-shadow:0 42px 110px rgba(0,0,0,.54),inset 0 0 80px rgba(14,95,67,.18);backdrop-filter:blur(18px)}
.product-stage img{filter:drop-shadow(0 46px 64px rgba(0,0,0,.62));animation:float 6s ease-in-out infinite}
.ingredient-float{position:absolute;z-index:1;width:86px;opacity:.9;filter:drop-shadow(0 20px 32px rgba(0,0,0,.5));animation:orbit 8s ease-in-out infinite}
.float-1{left:4%;top:12%}.float-2{right:1%;top:22%;animation-delay:1.2s}.float-3{left:8%;bottom:14%;animation-delay:2.1s}.float-4{right:12%;bottom:8%;animation-delay:3s}
@keyframes float{50%{transform:translateY(-18px)}}@keyframes pulse{50%{transform:scale(1.06);opacity:.75}}@keyframes orbit{50%{transform:translateY(-18px) rotate(8deg)}}
section{padding:88px 0}.section-head{display:flex;justify-content:space-between;gap:28px;align-items:end;margin-bottom:34px}.section-head h2{font-size:clamp(38px,6vw,70px);line-height:.95}.section-head p{max-width:500px;color:rgba(255,247,232,.64);line-height:1.8}
.badges{display:grid;grid-template-columns:repeat(4,1fr);gap:14px}.badge{padding:22px;text-align:center}.badge b{display:block;color:var(--gold);margin-bottom:6px}.badge span{color:rgba(255,247,232,.62);font-size:13px}
.benefits{display:grid;grid-template-columns:repeat(3,1fr);gap:18px}.benefit{padding:28px;transition:.28s ease}.benefit:hover{transform:translateY(-6px);border-color:rgba(201,162,74,.42)}.benefit .icon{width:46px;height:46px;border-radius:16px;display:grid;place-items:center;background:rgba(201,162,74,.13);color:var(--gold);font-size:22px;margin-bottom:18px}.benefit h3{font-size:27px}.benefit p{color:rgba(255,247,232,.62);line-height:1.8}
.story{display:grid;grid-template-columns:.9fr 1.1fr;gap:24px;align-items:center}.story-visual{position:relative;min-height:460px;display:grid;place-items:center}.story-visual::before{content:"";position:absolute;inset:12%;border-radius:50%;border:1px solid rgba(201,162,74,.2);box-shadow:inset 0 0 80px rgba(14,95,67,.22)}.ingredient-orbit{position:absolute;width:104px}.story-visual .jar{width:310px;z-index:2;filter:drop-shadow(0 32px 52px rgba(0,0,0,.58))}
.ingredient-list{display:grid;grid-template-columns:repeat(2,1fr);gap:12px}.ingredient-pill{padding:14px 16px;border:1px solid var(--line);border-radius:18px;background:rgba(255,247,232,.055);color:rgba(255,247,232,.78)}.ingredient-pill b{color:var(--gold)}
.steps{display:grid;grid-template-columns:repeat(3,1fr);gap:18px}.step{padding:28px}.step-num{width:42px;height:42px;border-radius:50%;background:var(--gold);color:var(--charcoal);display:grid;place-items:center;font-weight:900;margin-bottom:16px}.step p{color:rgba(255,247,232,.62);line-height:1.8}
.offer-grid{display:grid;grid-template-columns:1fr 1fr;gap:22px;align-items:start}.price-card{padding:34px;position:sticky;top:96px}.price{font-family:"Cormorant Garamond",serif;font-size:74px;color:var(--gold);line-height:1}.price small{font-size:28px}.offer-list{list-style:none;padding:0;margin:24px 0;display:grid;gap:12px;color:rgba(255,247,232,.72)}.offer-list li::before{content:"✓";color:var(--gold);font-weight:900;margin-right:10px}
.order-card{padding:30px}.order-grid{display:grid;grid-template-columns:1fr 1fr;gap:14px}.field{display:grid;gap:7px}.field.full{grid-column:1/-1}.field label{font-size:11px;letter-spacing:.12em;text-transform:uppercase;color:rgba(255,247,232,.55);font-weight:800}.field input,.field textarea,.field select{width:100%;border:1px solid rgba(201,162,74,.18);border-radius:16px;background:rgba(8,17,13,.72);color:var(--cream);padding:14px 15px;font:500 15px Manrope,sans-serif}.field textarea{min-height:94px;resize:vertical}.qty-row{display:flex;align-items:center;gap:8px}.qty-btn{width:44px;height:44px;border-radius:50%;border:1px solid var(--line);background:rgba(255,247,232,.06);color:var(--cream);font-size:20px;cursor:pointer}.qty-row input{text-align:center}.total-line{margin:18px 0;padding:18px;border-radius:18px;background:linear-gradient(135deg,rgba(201,162,74,.16),rgba(14,95,67,.12));display:flex;justify-content:space-between;color:var(--gold);font-weight:900;font-size:20px}
.razorpay-note{font-size:12px;color:rgba(255,247,232,.5);line-height:1.7}.privacy{font-size:12px;color:rgba(255,247,232,.5);line-height:1.7}
.testimonials{overflow:hidden}.testimonial-track{display:flex;gap:18px;animation:slide 28s linear infinite}.quote{min-width:min(380px,86vw);padding:26px}.quote p{color:rgba(255,247,232,.72);line-height:1.8}.quote b{color:var(--gold)}@keyframes slide{to{transform:translateX(-50%)}}
.faq{display:grid;gap:12px;max-width:880px;margin:auto}.faq details{padding:20px 24px}.faq summary{cursor:pointer;font-weight:900;color:var(--cream);list-style:none}.faq summary::-webkit-details-marker{display:none}.faq p{color:rgba(255,247,232,.62);line-height:1.8;margin:14px 0 0}
.footer{padding:46px 0 92px;border-top:1px solid var(--line);background:rgba(0,0,0,.16)}.footer-grid{display:flex;align-items:center;justify-content:space-between;gap:22px}.footer p{color:rgba(255,247,232,.58);max-width:540px;line-height:1.7}
.whatsapp-float{position:fixed;right:18px;bottom:18px;z-index:40;width:58px;height:58px;border-radius:50%;display:grid;place-items:center;background:#25D366;color:white;text-decoration:none;font-weight:900;box-shadow:0 18px 48px rgba(37,211,102,.32)}
.sticky-order{position:fixed;left:12px;right:12px;bottom:12px;z-index:39;display:none}.sticky-order .btn{width:100%;padding:17px}
.reveal{opacity:0;transform:translateY(28px);transition:opacity .75s ease,transform .75s ease}.reveal.in{opacity:1;transform:none}
@media(max-width:900px){.nav-links{display:none}.hero{padding-top:42px}.hero-grid,.story,.offer-grid{grid-template-columns:1fr}.spotlight{min-height:470px;order:-1}.hero-meta,.badges,.benefits,.steps{grid-template-columns:1fr 1fr}.price-card{position:static}.section-head{display:block}.section-head p{margin-top:14px}.footer-grid{display:grid}.whatsapp-float{bottom:86px}.sticky-order{display:block}}
@media(max-width:620px){.container{width:min(100% - 22px,1160px)}.nav-inner{height:66px}.logo{width:88px}h1{font-size:58px}.hero-copy{font-size:15px}.hero-actions .btn{width:100%}.hero-meta,.badges,.benefits,.steps,.ingredient-list,.order-grid{grid-template-columns:1fr}.product-stage{padding:26px;border-radius:30px}.ingredient-float{width:64px}.section-head h2{font-size:44px}section{padding:66px 0}.price{font-size:58px}}
</style>
</head>
<body>
<nav class="nav">
  <div class="container nav-inner">
    <!-- <a href="#top" aria-label="MISRY AYUR home"><img class="logo" src="{% static 'orders/assets/misry-ayur-logo-gold.png' %}" alt="MISRY AYUR"></a> -->
    <ul class="nav-links">
      <li><a href="#benefits">Benefits</a></li>
      <li><a href="#ingredients">Ingredients</a></li>
      <li><a href="#ritual">How to Use</a></li>
      <li><a href="#order">Order</a></li>
    </ul>
    <a class="btn btn-primary" href="#order">Order Now</a>
  </div>
</nav>

<main id="top">
  <section class="hero">
    <div class="container hero-grid">
      <div class="reveal">
        <span class="eyebrow">Premium Ayurvedic Lehyam</span>
        <h1>Ancient Vitality. Modern Luxury.</h1>
        <p class="hero-copy">Misry Lehyam From Precious Ayurvedais a premium 100g Ayurvedic paste crafted with 13+ rare herbs for everyday wellness, vitality, stamina, and inner balance. A high-touch wellness ritual with free shipping across India.</p>
        <div class="hero-actions">
          <a class="btn btn-primary" href="#order">Buy Misry Lehyam ₹1,699</a>
          <a class="btn btn-ghost" href="https://wa.me/919526700143?text=Hello%2C%20I%20want%20to%20order%20Misry%20Lehyam." target="_blank" rel="noopener">WhatsApp 9526700143</a>
        </div>
        <div class="hero-meta">
          <div class="meta-card"><strong>100g</strong><span>Premium net weight</span></div>
          <div class="meta-card"><strong>₹1,699</strong><span>Inclusive offer price</span></div>
          <div class="meta-card"><strong>Free</strong><span>Shipping included</span></div>
        </div>
      </div>
      <div class="spotlight reveal">
        <img class="ingredient-float float-1" src="{% static 'orders/assets/products/png/Shatavari-removebg-preview.png' %}" alt="Shatavari">
        <img class="ingredient-float float-2" src="{% static 'orders/assets/products/Guda.svg' %}" alt="Guda">
        <img class="ingredient-float float-3" src="{% static 'orders/assets/products/png/Ashwagantha-removebg-preview.png' %}" alt="Ashwagandha">
        <img class="ingredient-float float-4" src="{% static 'orders/assets/products/Sunthi.svg' %}" alt="Sunthi">
        <div class="product-stage">
          <img src="{% static 'orders/assets/misry-lehyam-hero.png' %}" alt="Misry Lehyam premium Ayurvedic product jar">
        </div>
      </div>
    </div>
  </section>

  <section aria-label="Trust badges">
    <div class="container badges reveal">
      <div class="glass badge"><b>13+ Herbs</b><span>Rare Ayurvedic ingredients</span></div>
      <div class="glass badge"><b>Free Shipping</b><span>No shipping charge</span></div>
      <div class="glass badge"><b>No COD</b><span>UPI / Bank transfer only</span></div>
      <div class="glass badge"><b>Support</b><span> 9526700143</span></div>
    </div>
  </section>

  <section id="benefits">
    <div class="container">
      <div class="section-head reveal">
        <div><span class="eyebrow">Why MISRY</span><h2>Luxury wellness, rooted in Ayurveda.</h2></div>
        <p>A clean, premium daily ritual designed for people who want traditional Ayurvedic wisdom in a modern wellness format.</p>
      </div>
      <div class="benefits">
        <article class="glass benefit reveal"><div class="icon">✦</div><h3>Vitality Support</h3><p>Formulated to support energy, stamina, and a stronger daily wellness rhythm.</p></article>
        <article class="glass benefit reveal"><div class="icon">☿</div><h3>Herbal Balance</h3><p>Made with a thoughtful blend of traditional herbs selected for harmony and potency.</p></article>
        <article class="glass benefit reveal"><div class="icon">◐</div><h3>Daily Ritual</h3><p>Just 10g a day, taken directly or with warm milk or water for a smooth routine.</p></article>
      </div>
    </div>
  </section>

  <section id="ingredients">
    <div class="container story">
      <div class="story-visual reveal">
        <img class="ingredient-orbit" style="left:4%;top:10%" src="{% static 'orders/assets/products/png/Kapikachu-removebg-preview.png' %}" alt="Kapikachu">
        <img class="ingredient-orbit" style="right:4%;top:18%" src="{% static 'orders/assets/products/png/Ela.png' %}" alt="Ela">
        <img class="ingredient-orbit" style="left:9%;bottom:11%" src="{% static 'orders/assets/products/png/Vidari-removebg-preview.png' %}" alt="Vidari">
        <img class="ingredient-orbit" style="right:9%;bottom:8%" src="{% static 'orders/assets/products/Shalmali.svg' %}" alt="Shalmali">
        <img class="jar" src="{% static 'orders/assets/misry-lehyam-hero.png' %}" alt="Misry Lehyam jar">
      </div>
      <div class="reveal">
        <span class="eyebrow">Ingredient Story</span>
        <h2>13+ herbs. One refined formula.</h2>
        <p class="hero-copy">Each ingredient is presented as part of a premium Ayurvedic wellness experience, balancing heritage, craft, and everyday use.</p>
        <div class="ingredient-list">
          <div class="ingredient-pill"><b>Shatavari</b><br>Asparagus racemosus</div>
          <div class="ingredient-pill"><b>Kapikachu</b><br>Mucuna pruriens</div>
          <div class="ingredient-pill"><b>Ashwagandha</b><br>Withania somnifera</div>
          <div class="ingredient-pill"><b>Sunthi</b><br>Zingiber officinale</div>
          <div class="ingredient-pill"><b>Vidari</b><br>Pueraria tuberosa</div>
          <div class="ingredient-pill"><b>Yasthimadhu</b><br>Licorice Root</div>
        </div>
      </div>
    </div>
  </section>

  <section id="ritual">
    <div class="container">
      <div class="section-head reveal"><div><span class="eyebrow">Simple Ritual</span><h2>How to use.</h2></div></div>
      <div class="steps">
        <article class="glass step reveal"><div class="step-num">1</div><h3>Measure</h3><p>Take 1 level spoon, around 10g, of Misry Lehyam.</p></article>
        <article class="glass step reveal"><div class="step-num">2</div><h3>Consume</h3><p>Take directly, or mix with warm milk or water for a smoother experience.</p></article>
        <article class="glass step reveal"><div class="step-num">3</div><h3>Repeat</h3><p>Use daily as a premium wellness ritual. Store in a cool, dry place.</p></article>
      </div>
    </div>
  </section>

  <section id="order">
    <div class="container offer-grid">
      <aside class="glass price-card reveal">
        <span class="eyebrow">Limited Offer</span>
        <h2>Misry Lehyam</h2>
        <p class="hero-copy">Premium Ayurvedic Paste · Net Wt: 100g</p>
        <div class="price"><small>₹</small>1,699</div>
        <ul class="offer-list">
          <li>Free shipping</li>
          <li>UPI / Bank Transfer / WhatsApp Order</li>
          <li>COD not available</li>
          <li>Support WhatsApp: 9526700143</li>
        </ul>
        <a class="btn btn-ghost" href="https://wa.me/919526700143?text=Hello%2C%20I%20want%20to%20order%20Misry%20Lehyam." target="_blank" rel="noopener">Ask Before Ordering</a>
      </aside>

      <form class="glass order-card reveal" id="orderForm" method="post" action="{% url 'orders:create_order' %}">
        {% csrf_token %}
        <span class="eyebrow">Secure Order</span>
        <h2>Place your order.</h2>
        {% if messages %}{% for message in messages %}<p class="privacy">{{ message }}</p>{% endfor %}{% endif %}
        <div class="order-grid">
          <div class="field"><label for="fullName">Full Name</label><input id="fullName" name="full_name" autocomplete="name" required></div>
          <div class="field"><label for="phone">Phone Number</label><input id="phone" name="phone" inputmode="numeric" maxlength="10" pattern="[6-9][0-9]{9}" required></div>
          <div class="field"><label for="whatsapp">WhatsApp Optional</label><input id="whatsapp" name="whatsapp_number" inputmode="numeric" maxlength="10" pattern="[6-9][0-9]{9}"></div>
          <div class="field"><label for="quantity">Quantity</label><div class="qty-row"><button class="qty-btn" type="button" data-qty="-1">−</button><input id="quantity" name="quantity" type="number" min="1" max="99" value="1" required><button class="qty-btn" type="button" data-qty="1">+</button></div></div>
          <div class="field full"><label for="address">Full Address</label><textarea id="address" name="address" autocomplete="street-address" required></textarea></div>
          <div class="field"><label for="district">District</label><input id="district" name="district" required></div>
          <div class="field"><label for="state">State</label><input id="state" name="state" required></div>
          <div class="field"><label for="pincode">Pincode</label><input id="pincode" name="pincode" inputmode="numeric" maxlength="6" pattern="[0-9]{6}" required></div>
          <div class="field full"><label for="paymentMethod">Payment Method</label><select id="paymentMethod" name="payment_method" required><option>UPI / Bank Transfer</option><option>WhatsApp Order</option></select></div>
          <div class="field full"><label for="notes">Order Notes Optional</label><textarea id="notes" name="order_notes"></textarea></div>
        </div>
        <div class="total-line"><span>Total</span><strong id="liveTotal">₹1,699</strong></div>
        <button class="btn btn-primary" style="width:100%" type="submit">Confirm Order</button>
        <button class="btn btn-ghost" style="width:100%;margin-top:10px" type="button" id="razorpayBtn" data-product="Misry Lehyam" data-price="169900">Razorpay Ready</button>
        <p class="razorpay-note">Razorpay-ready structure is included. Connect this button to a backend order/payment creation endpoint before enabling live payments.</p>
        <p class="privacy">Customer details are only used for order confirmation and delivery.</p>
      </form>
    </div>
  </section>

  <section class="testimonials">
    <div class="container">
      <div class="section-head reveal"><div><span class="eyebrow">Customer Confidence</span><h2>Premium wellness, personal support.</h2></div></div>
      <div class="testimonial-track">
        <article class="glass quote"><p>“The product feels premium from the first impression. Ordering on WhatsApp was simple and personal.”</p><b>Verified Customer</b></article>
        <article class="glass quote"><p>“A refined Ayurvedic ritual with a luxury feel. The support team explained everything clearly.”</p><b>Wellness User</b></article>
        <article class="glass quote"><p>“Clean design, clear details, and a trustworthy order process.”</p><b>Repeat Buyer</b></article>
        <article class="glass quote"><p>“The product feels premium from the first impression. Ordering on WhatsApp was simple and personal.”</p><b>Verified Customer</b></article>
        <article class="glass quote"><p>“A refined Ayurvedic ritual with a luxury feel. The support team explained everything clearly.”</p><b>Wellness User</b></article>
      </div>
    </div>
  </section>

  <section id="faq">
    <div class="container">
      <div class="section-head reveal"><div><span class="eyebrow">FAQ</span><h2>Before you order.</h2></div></div>
      <div class="faq">
        <details class="glass reveal"><summary>What is the price of Misry Lehyam?</summary><p>Misry Lehyam is priced at ₹1,699 for a 100g jar.</p></details>
        <details class="glass reveal"><summary>Is shipping free?</summary><p>Yes, shipping is free.</p></details>
        <details class="glass reveal"><summary>Is COD available?</summary><p>No. COD is not available. Payment is by UPI, bank transfer, or WhatsApp order coordination.</p></details>
        <details class="glass reveal"><summary>How do I order on WhatsApp?</summary><p>Use the WhatsApp button on the page or message 9526700143 with your name, phone, address, quantity, and payment method.</p></details>
      </div>
    </div>
  </section>
</main>

<footer class="footer">
  <div class="container footer-grid">
    <div>
      <img class="logo" src="{% static 'orders/assets/misry-ayur-logo-gold.png' %}" alt="MISRY AYUR">
      <p>Premium Ayurvedic wellness by MISRY AYUR. Product support and orders are handled on WhatsApp at 9526700143.</p>
    </div>
    <a class="btn btn-primary" href="https://wa.me/919526700143?text=Hello%2C%20I%20want%20to%20order%20Misry%20Lehyam." target="_blank" rel="noopener">Order on WhatsApp</a>
  </div>
</footer>

<a class="whatsapp-float" id="whatsappFloat" href="https://wa.me/919526700143?text=Hello%2C%20I%20want%20to%20order%20Misry%20Lehyam." target="_blank" rel="noopener" aria-label="Order on WhatsApp">WA</a>
<div class="sticky-order"><a class="btn btn-primary" href="#order">Order Misry Lehyam · ₹1,699</a></div>

<script>
(function(){
  const price = 1699;
  const qty = document.getElementById('quantity');
  const total = document.getElementById('liveTotal');
  const form = document.getElementById('orderForm');
  const wa = document.getElementById('whatsappFloat');
  const format = value => new Intl.NumberFormat('en-IN',{style:'currency',currency:'INR',maximumFractionDigits:0}).format(value);
  function getQty(){ return Math.max(1, Math.min(99, parseInt(qty.value,10) || 1)); }
  function update(){
    qty.value = getQty();
    total.textContent = format(price * getQty());
    const data = new FormData(form);
    const address = [data.get('address'), data.get('district'), data.get('state'), data.get('pincode')].filter(Boolean).join(', ');
    const msg = ['Hello, I want to order Misry Lehyam.',`Name: ${data.get('full_name') || ''}`,`Phone: ${data.get('phone') || ''}`,`Address: ${address}`,`Quantity: ${getQty()}`,`Total Amount: ${format(price * getQty())}`,`Payment Method: ${data.get('payment_method') || 'UPI / Bank Transfer'}`,`Order ID:`].join('\n');
    wa.href = `https://wa.me/919526700143?text=${encodeURIComponent(msg)}`;
  }
  document.querySelectorAll('[data-qty]').forEach(btn => btn.addEventListener('click', () => { qty.value = getQty() + Number(btn.dataset.qty); update(); }));
  form.addEventListener('input', update);
  form.addEventListener('submit', event => {
    const phone = document.getElementById('phone').value.trim();
    const pin = document.getElementById('pincode').value.trim();
    if(!/^[6-9]\d{9}$/.test(phone) || !/^\d{6}$/.test(pin)){
      event.preventDefault();
      alert('Please enter a valid 10-digit phone number and 6-digit pincode.');
    }
  });
  document.getElementById('razorpayBtn').addEventListener('click', () => {
    const amount = price * getQty() * 100;
    const options = { key: 'RAZORPAY_KEY_ID', amount, currency: 'INR', name: 'MISRY AYUR', description: 'Misry Lehyam', prefill: { name: document.getElementById('fullName').value, contact: document.getElementById('phone').value } };
    console.info('Razorpay-ready options:', options);
    alert('Razorpay structure is ready. Add your backend payment order endpoint and live key to enable checkout.');
  });
  const observer = new IntersectionObserver(entries => entries.forEach(entry => { if(entry.isIntersecting) entry.target.classList.add('in'); }), { threshold:.16 });
  document.querySelectorAll('.reveal').forEach(el => observer.observe(el));
  update();
})();
</script>
</body>
</html>
