import Link from "next/link";
import Header from "@/components/Header";
import Footer from "@/components/Footer";
import InnerBanner from "@/components/InnerBanner";
import { Metadata } from "next";

export const metadata: Metadata = {
    title: "Privacy Policy | Your Data, Security & Rights",
    description: "Understand how your personal information is collected, used, and protected. Our Privacy Policy ensures transparency and your data rights.",
};

export default function PrivacyPolicy() {
    return (
        <div className="min-h-screen bg-white dark:bg-black">
            {/* Header */}
            <Header />

            {/* Inner Banner */}
            <InnerBanner
                title="Privacy Policy"
                subtitle="Learn how we protect and manage your data"
                breadcrumbs={[
                    { label: "Home", href: "/" },
                    { label: "Privacy Policy" }
                ]}
                backgroundImage="/assets/images/about/privacy-banner.webp"
            />

            {/* Page Content */}
            <div className="max-w-4xl mx-auto px-6 py-20">
                <h1 className="text-4xl md:text-5xl font-bold text-foreground mb-8">
                    Privacy Policy
                </h1>

                <div className="prose prose-lg dark:prose-invert max-w-none">
                    <p className="text-gray-600 dark:text-gray-400 mb-6">
                        Last updated: {new Date().toLocaleDateString('en-US', { year: 'numeric', month: 'long', day: 'numeric' })}
                    </p>

                    <section className="mb-8">
                        <h2 className="text-2xl font-semibold text-foreground mb-4">1. Introduction</h2>
                        <p className="text-gray-600 dark:text-gray-400 mb-4">
                            Welcome to Sky and Soil. We respect your privacy and are committed to protecting your personal data.
                            This privacy policy will inform you about how we look after your personal data when you visit our website
                            and tell you about your privacy rights and how the law protects you.
                        </p>
                    </section>

                    <section className="mb-8">
                        <h2 className="text-2xl font-semibold text-foreground mb-4">2. Information We Collect</h2>
                        <p className="text-gray-600 dark:text-gray-400 mb-4">
                            We may collect, use, store and transfer different kinds of personal data about you which we have grouped together as follows:
                        </p>
                        <ul className="list-disc pl-6 text-gray-600 dark:text-gray-400 space-y-2">
                            <li><strong>Identity Data:</strong> includes first name, last name, username or similar identifier.</li>
                            <li><strong>Contact Data:</strong> includes email address, telephone numbers, and mailing address.</li>
                            <li><strong>Technical Data:</strong> includes internet protocol (IP) address, browser type and version, time zone setting and location, browser plug-in types and versions, operating system and platform.</li>
                            <li><strong>Usage Data:</strong> includes information about how you use our website and services.</li>
                            <li><strong>Marketing and Communications Data:</strong> includes your preferences in receiving marketing from us and your communication preferences.</li>
                        </ul>
                    </section>

                    <section className="mb-8">
                        <h2 className="text-2xl font-semibold text-foreground mb-4">3. How We Use Your Information</h2>
                        <p className="text-gray-600 dark:text-gray-400 mb-4">
                            We will only use your personal data when the law allows us to. Most commonly, we will use your personal data in the following circumstances:
                        </p>
                        <ul className="list-disc pl-6 text-gray-600 dark:text-gray-400 space-y-2">
                            <li>To provide and maintain our services</li>
                            <li>To notify you about changes to our services</li>
                            <li>To provide customer support</li>
                            <li>To gather analysis or valuable information so that we can improve our services</li>
                            <li>To monitor the usage of our services</li>
                            <li>To detect, prevent and address technical issues</li>
                            <li>To provide you with news, special offers and general information about other goods, services and events which we offer</li>
                        </ul>
                    </section>

                    <section className="mb-8">
                        <h2 className="text-2xl font-semibold text-foreground mb-4">4. Data Security</h2>
                        <p className="text-gray-600 dark:text-gray-400 mb-4">
                            We have put in place appropriate security measures to prevent your personal data from being accidentally lost,
                            used or accessed in an unauthorized way, altered or disclosed. In addition, we limit access to your personal data
                            to those employees, agents, contractors and other third parties who have a business need to know.
                        </p>
                    </section>

                    <section className="mb-8">
                        <h2 className="text-2xl font-semibold text-foreground mb-4">5. Data Retention</h2>
                        <p className="text-gray-600 dark:text-gray-400 mb-4">
                            We will only retain your personal data for as long as necessary to fulfil the purposes we collected it for,
                            including for the purposes of satisfying any legal, accounting, or reporting requirements.
                        </p>
                    </section>

                    <section className="mb-8">
                        <h2 className="text-2xl font-semibold text-foreground mb-4">6. Your Legal Rights</h2>
                        <p className="text-gray-600 dark:text-gray-400 mb-4">
                            Under certain circumstances, you have rights under data protection laws in relation to your personal data, including the right to:
                        </p>
                        <ul className="list-disc pl-6 text-gray-600 dark:text-gray-400 space-y-2">
                            <li>Request access to your personal data</li>
                            <li>Request correction of your personal data</li>
                            <li>Request erasure of your personal data</li>
                            <li>Object to processing of your personal data</li>
                            <li>Request restriction of processing your personal data</li>
                            <li>Request transfer of your personal data</li>
                            <li>Right to withdraw consent</li>
                        </ul>
                    </section>

                    <section className="mb-8">
                        <h2 className="text-2xl font-semibold text-foreground mb-4">7. Cookies</h2>
                        <p className="text-gray-600 dark:text-gray-400 mb-4">
                            Our website uses cookies to distinguish you from other users of our website. This helps us to provide you
                            with a good experience when you browse our website and also allows us to improve our site.
                        </p>
                    </section>

                    <section className="mb-8">
                        <h2 className="text-2xl font-semibold text-foreground mb-4">8. Third-Party Links</h2>
                        <p className="text-gray-600 dark:text-gray-400 mb-4">
                            Our website may include links to third-party websites, plug-ins and applications. Clicking on those links
                            or enabling those connections may allow third parties to collect or share data about you. We do not control
                            these third-party websites and are not responsible for their privacy statements.
                        </p>
                    </section>

                    <section className="mb-8">
                        <h2 className="text-2xl font-semibold text-foreground mb-4">9. Contact Us</h2>
                        <p className="text-gray-600 dark:text-gray-400 mb-4">
                            If you have any questions about this Privacy Policy, please contact us:
                        </p>
                        <ul className="list-none text-gray-600 dark:text-gray-400 space-y-2">
                            <li>Email: hello@skyandsoil.com</li>
                            <li>Phone: +91 80 1234 5678</li>
                            <li>Address: Bangalore, Karnataka</li>
                        </ul>
                    </section>
                </div>

                <div className="mt-12">
                    <Link
                        href="/"
                        className="inline-flex items-center text-primary hover:underline"
                    >
                        <svg
                            xmlns="http://www.w3.org/2000/svg"
                            fill="none"
                            viewBox="0 0 24 24"
                            strokeWidth={1.5}
                            stroke="currentColor"
                            className="w-5 h-5 mr-2"
                        >
                            <path strokeLinecap="round" strokeLinejoin="round" d="M10.5 19.5L3 12m0 0l7.5-7.5M3 12h18" />
                        </svg>
                        Back to Home
                    </Link>
                </div>
            </div>

            {/* Footer */}
            <Footer />
        </div>
    );
}
