import React from 'react';
import { Head, Link, usePage } from '@inertiajs/react';
import MarketingLayout from '@/layouts/MarketingLayout';
import { useLocalizedRoutes } from '@/hooks/useLocalizedRoutes';

const Datenschutz: React.FC = () => {
  const { props } = usePage();
  const { __ } = props as any; // Für i18n
  const { localizedPath } = useLocalizedRoutes();

  return (
    <MarketingLayout title={__('legal.datenschutz_title')}>
      <Head title={__('legal.datenschutz_title')} />
      <div className="container mx-auto px-4 py-8">
        <h1 className="text-2xl font-bold mb-4 font-display">{__('legal.datenschutz')}</h1>
        <p className="mb-4 font-sans-marketing">{__('legal.datenschutz_intro')}</p>
        <p className="mb-4 font-sans-marketing">{__('legal.responsible')}</p>
        <p className="mb-4 font-sans-marketing">{__('legal.data_collection')}</p>
        <h2 className="text-xl font-semibold mb-2 font-display">{__('legal.payments')}</h2>
        <p className="mb-4 font-sans-marketing">
          {__('legal.payments_desc')} <a href="https://stripe.com/de/privacy" target="_blank" rel="noopener noreferrer">{__('legal.stripe_privacy')}</a> {__('legal.and')} <a href="https://www.paypal.com/de/webapps/mpp/ua/privacy-full" target="_blank" rel="noopener noreferrer">{__('legal.paypal_privacy')}</a>.
        </p>
        <p className="mb-4 font-sans-marketing">{__('legal.data_retention')}</p>
        <p className="mb-4 font-sans-marketing">
          {__('legal.rights')} <Link href={localizedPath('/kontakt')}>{__('legal.contact')}</Link>.
        </p>
        <p className="mb-4 font-sans-marketing">{__('legal.cookies')}</p>
        
        <h2 className="text-xl font-semibold mb-2 font-display">{__('legal.personal_data')}</h2>
        <p className="mb-4 font-sans-marketing">{__('legal.personal_data_desc')}</p>
        
        <h2 className="text-xl font-semibold mb-2 font-display">{__('legal.account_deletion')}</h2>
        <p className="mb-4 font-sans-marketing">{__('legal.account_deletion_desc')}</p>
        
        <h2 className="text-xl font-semibold mb-2 font-display">{__('legal.data_security')}</h2>
        <p className="mb-4 font-sans-marketing">{__('legal.data_security_desc')}</p>
      </div>
    </MarketingLayout>
  );
};

export default Datenschutz;