---
import BaseLayout from '../../layouts/BaseLayout.astro';
import Header from '../../components/Header.astro';
import Footer from '../../components/Footer.astro';
import { ui, languages, defaultLang } from '../../i18n/ui';

// Get language from the URL
export async function getStaticPaths() {
  return Object.keys(languages).map(lang => {
    return { params: { lang } };
  });
}

const { lang = defaultLang } = Astro.params;
const t = ui[lang as keyof typeof ui];
---

<BaseLayout>
  <Header />
  
  <!-- Hero Section -->
  <section class="relative pt-32 pb-12 overflow-hidden">
    <!-- Background elements -->
    <div class="absolute inset-0 -z-10">
      <div class="absolute inset-0 bg-gradient-to-b from-black-deep via-black-medium to-black-deep"></div>
      <div class="absolute inset-0 opacity-10 bg-[radial-gradient(circle_at_center,_var(--tw-gradient-stops))] from-silver-metallic/20 to-transparent"></div>
    </div>
    
    <!-- Content -->
    <div class="container mx-auto px-4 relative z-10">
      <h1 class="text-4xl md:text-6xl font-bold text-transparent bg-clip-text bg-gradient-to-r from-silver-metallic to-silver-light mb-6">
        Privacy Policy
      </h1>
    </div>
  </section>

  <!-- Main Content Section -->
  <section class="relative py-12 px-4">
    <div class="absolute inset-0 bg-gradient-to-br from-black-deep to-black-medium"></div>
    
    <div class="max-w-4xl mx-auto relative z-10">
      <div class="bg-gradient-to-br from-black-deep/90 to-black-medium/90 backdrop-blur-sm rounded-2xl border border-silver-dark/20 shadow-xl overflow-hidden">
        <div class="p-8 md:p-10">
          <div class="prose prose-invert max-w-none text-silver-light/90">
            <p class="mb-6">Last updated: {new Date().toISOString().split('T')[0]}</p>
            
            <h2 class="text-2xl text-silver-metallic font-semibold mb-4">1. Introduction</h2>
            <p class="mb-4">This Privacy Policy explains how JPM Security & Services ("we," "our," or "us") collects, uses, shares, and protects your personal information when you visit our website, use our services, or interact with us in any way.</p>
            <p class="mb-6">We are committed to protecting your privacy and complying with applicable data protection laws, including the General Data Protection Regulation (GDPR).</p>
            
            <h2 class="text-2xl text-silver-metallic font-semibold mb-4">2. Information We Collect</h2>
            <p class="mb-4">We may collect the following types of information:</p>
            <ul class="list-disc pl-6 mb-6 space-y-2">
              <li><strong>Personal Information:</strong> Name, email address, phone number, and other contact details when you contact us through our website or sign up for our services.</li>
              <li><strong>Usage Data:</strong> Information about how you interact with our website, including IP address, browser type, pages visited, time spent on pages, and other browsing data.</li>
              <li><strong>Communication Data:</strong> Any information you provide when communicating with us via email, phone, or through our contact forms.</li>
            </ul>
            
            <h2 class="text-2xl text-silver-metallic font-semibold mb-4">3. How We Use Your Information</h2>
            <p class="mb-4">We use your information for the following purposes:</p>
            <ul class="list-disc pl-6 mb-6 space-y-2">
              <li>To provide and improve our services</li>
              <li>To respond to your inquiries and communications</li>
              <li>To send you information about our services (with your consent)</li>
              <li>To ensure the security and functionality of our website</li>
              <li>To comply with legal obligations</li>
            </ul>
            
            <h2 class="text-2xl text-silver-metallic font-semibold mb-4">4. Legal Basis for Processing</h2>
            <p class="mb-4">We process your personal data on the following legal grounds:</p>
            <ul class="list-disc pl-6 mb-6 space-y-2">
              <li><strong>Consent:</strong> Where you have given clear consent for us to process your personal data for a specific purpose.</li>
              <li><strong>Contract:</strong> Where processing is necessary for the performance of a contract with you or to take steps at your request before entering into a contract.</li>
              <li><strong>Legitimate Interests:</strong> Where processing is necessary for our legitimate interests or those of a third party, except where such interests are overridden by your interests or fundamental rights.</li>
              <li><strong>Legal Obligation:</strong> Where processing is necessary for compliance with a legal obligation to which we are subject.</li>
            </ul>
            
            <h2 class="text-2xl text-silver-metallic font-semibold mb-4">5. Data Sharing and Disclosure</h2>
            <p class="mb-4">We may share your personal information with:</p>
            <ul class="list-disc pl-6 mb-6 space-y-2">
              <li>Service providers who help us operate our business and website</li>
              <li>Legal authorities when required by law or to protect our rights</li>
              <li>Business partners with your consent or when necessary to provide services</li>
            </ul>
            <p class="mb-6">We do not sell your personal information to third parties.</p>
            
            <h2 class="text-2xl text-silver-metallic font-semibold mb-4">6. Data Retention</h2>
            <p class="mb-6">We retain your personal information only for as long as necessary to fulfill the purposes for which we collected it, including for the purposes of satisfying any legal, accounting, or reporting requirements. To determine the appropriate retention period, we consider the amount, nature, and sensitivity of the data, the potential risk of harm from unauthorized use or disclosure, and applicable legal requirements.</p>
            
            <h2 class="text-2xl text-silver-metallic font-semibold mb-4">7. Your Data Protection Rights</h2>
            <p class="mb-4">Under the GDPR and other applicable data protection laws, you have the following rights:</p>
            <ul class="list-disc pl-6 mb-6 space-y-2">
              <li><strong>Right to Access:</strong> You can request a copy of the personal information we hold about you.</li>
              <li><strong>Right to Rectification:</strong> You can request that we correct any inaccurate or incomplete information.</li>
              <li><strong>Right to Erasure:</strong> You can request that we delete your personal information in certain circumstances.</li>
              <li><strong>Right to Restrict Processing:</strong> You can request that we restrict the processing of your information in certain circumstances.</li>
              <li><strong>Right to Data Portability:</strong> You can request to receive your personal information in a structured, machine-readable format.</li>
              <li><strong>Right to Object:</strong> You can object to our processing of your personal information in certain circumstances.</li>
              <li><strong>Right to Withdraw Consent:</strong> Where we rely on your consent to process your personal information, you have the right to withdraw that consent at any time.</li>
            </ul>
            <p class="mb-6">To exercise any of these rights, please contact us using the information provided in the "Contact Us" section below.</p>
            
            <h2 class="text-2xl text-silver-metallic font-semibold mb-4">8. Cookies and Similar Technologies</h2>
            <p class="mb-6">Our website uses cookies and similar technologies to enhance your browsing experience, analyze site traffic, and understand where our visitors are coming from. You can control cookies through your browser settings and other tools. For more information about our use of cookies, please see our Cookie Policy.</p>
            
            <h2 class="text-2xl text-silver-metallic font-semibold mb-4">9. Data Security</h2>
            <p class="mb-6">We implement appropriate technical and organizational measures to protect your personal information from unauthorized access, disclosure, alteration, or destruction. However, no method of transmission over the Internet or electronic storage is 100% secure, so we cannot guarantee absolute security.</p>
            
            <h2 class="text-2xl text-silver-metallic font-semibold mb-4">10. International Data Transfers</h2>
            <p class="mb-6">Your personal information may be transferred to, and processed in, countries other than the country in which you reside. These countries may have data protection laws that are different from the laws of your country. We ensure that appropriate safeguards are in place to protect your personal information when it is transferred internationally.</p>
            
            <h2 class="text-2xl text-silver-metallic font-semibold mb-4">11. Children's Privacy</h2>
            <p class="mb-6">Our services are not directed to individuals under the age of 16. We do not knowingly collect personal information from children. If we become aware that we have collected personal information from a child without parental consent, we will take steps to delete that information.</p>
            
            <h2 class="text-2xl text-silver-metallic font-semibold mb-4">12. Changes to This Privacy Policy</h2>
            <p class="mb-6">We may update this Privacy Policy from time to time to reflect changes in our practices or for other operational, legal, or regulatory reasons. We will notify you of any material changes by posting the updated policy on our website or by other means as required by law.</p>
            
            <h2 class="text-2xl text-silver-metallic font-semibold mb-4">13. Contact Us</h2>
            <p class="mb-6">If you have any questions, concerns, or requests regarding this Privacy Policy or our data practices, please contact us at:</p>
            <p class="mb-2">JPM Security & Services</p>
            <p class="mb-2">Email: privacy@jpmsecurityservices.com</p>
            <p class="mb-6">Phone: [Your phone number]</p>
            
            <h2 class="text-2xl text-silver-metallic font-semibold mb-4">14. Data Protection Authority</h2>
            <p class="mb-6">If you are located in the European Economic Area (EEA) and believe we are unlawfully processing your personal information, you also have the right to complain to your local data protection supervisory authority.</p>
          </div>
        </div>
      </div>
    </div>
  </section>

  <Footer />
</BaseLayout> 