import { Link } from "react-router";
import { ArrowLeft, MessageCircle, Send, Mail, MapPin } from "lucide-react";

const contacts = [
  { icon: MessageCircle, label: "WhatsApp Support", value: "+91 7038146526", href: "https://wa.me/917038146526", desc: "24/7 support. Average response: 5 min" },
  { icon: Send, label: "Telegram Group", value: "@teamhydrashopC", href: "https://t.me/teamhydrashopC", desc: "Community + Support" },
  { icon: Mail, label: "Email", value: "contact@dealstacktools.shop", href: "mailto:contact@dealstacktools.shop", desc: "Business inquiries" },
  { icon: MessageCircle, label: "Telegram Direct", value: "@mfatool", href: "https://t.me/mfatool", desc: "Direct message" },
];

const socials = [
  { label: "WhatsApp Community", href: "https://chat.whatsapp.com/CAEgMqOlfcYLxv8ElniW0h" },
  { label: "WhatsApp Channel", href: "https://whatsapp.com/channel/0029Vb7dW7S6GcGJbE4TcC2o" },
  { label: "YouTube", href: "https://www.youtube.com/@teamhydrashops" },
  { label: "Instagram", href: "https://www.instagram.com/teamhydrashop/" },
];

export default function Contact() {
  return (
    <main className="min-h-screen bg-[#050505] pt-24 pb-16">
      <div className="max-w-4xl mx-auto px-4 sm:px-6 lg:px-8">
        <Link to="/" className="inline-flex items-center gap-2 text-sm text-[#a5a5a5] hover:text-white mb-6 transition-colors"><ArrowLeft className="w-4 h-4" /> Back to Home</Link>

        {/* Schema */}
        <script type="application/ld+json" dangerouslySetInnerHTML={{ __html: JSON.stringify({
          "@context": "https://schema.org", "@type": "ContactPage",
          name: "Contact Deal Stack Tools",
          description: "Contact Deal Stack Tools for support, inquiries, and business partnerships.",
          url: "https://dealstacktools.shop/contact",
          mainEntity: { "@type": "Organization", name: "Deal Stack Tools", contactPoint: { "@type": "ContactPoint", contactType: "customer support", telephone: "+91-7038146526", availableLanguage: ["English", "Hindi"] } }
        })}} />

        <div className="text-center mb-12">
          <h1 className="text-3xl sm:text-4xl font-bold text-white mb-3">Contact Us</h1>
          <p className="text-[#a5a5a5] max-w-lg mx-auto">We are here to help. Reach out through any of the channels below and we will get back to you quickly.</p>
        </div>

        <div className="grid grid-cols-1 md:grid-cols-2 gap-6 mb-12">
          {contacts.map((c) => (
            <a key={c.label} href={c.href} target="_blank" rel="noopener noreferrer" className="glass-card rounded-2xl p-6 hover:border-[#5b9aff]/30 transition-all group">
              <div className="flex items-start gap-4">
                <div className="w-12 h-12 rounded-xl bg-[#5b9aff]/10 flex items-center justify-center shrink-0 group-hover:bg-[#5b9aff]/20 transition-colors">
                  <c.icon className="w-5 h-5 text-[#5b9aff]" />
                </div>
                <div>
                  <p className="text-sm text-[#a5a5a5]">{c.label}</p>
                  <p className="text-lg font-semibold text-white group-hover:text-[#5b9aff] transition-colors">{c.value}</p>
                  <p className="text-xs text-[#a5a5a5] mt-1">{c.desc}</p>
                </div>
              </div>
            </a>
          ))}
        </div>

        <div className="glass-card rounded-2xl p-8">
          <h2 className="text-xl font-bold text-white mb-4">Our Communities</h2>
          <div className="flex flex-wrap gap-3">
            {socials.map((s) => (
              <a key={s.label} href={s.href} target="_blank" rel="noopener noreferrer" className="px-4 py-2 bg-[#141414] text-[#a5a5a5] rounded-full text-sm hover:text-[#5b9aff] hover:bg-[#5b9aff]/10 transition-all">{s.label}</a>
            ))}
          </div>
          <div className="mt-6 pt-6 border-t border-white/5">
            <div className="flex items-center gap-2 text-sm text-[#a5a5a5]">
              <MapPin className="w-4 h-4 text-[#5b9aff]" />
              <span>Website: dealstacktools.shop</span>
            </div>
          </div>
        </div>
      </div>
    </main>
  );
}
