import type { Metadata } from 'next';

export const metadata: Metadata = {
  title: 'Terms of Service — DashCaddy',
  description: 'DashCaddy terms of service.',
};

export default function TermsPage() {
  return (
    <div className="min-h-screen bg-surface-950 text-surface-100">
      <div className="mx-auto max-w-3xl px-4 sm:px-6 lg:px-8 py-20">
        <h1 className="text-4xl font-bold mb-8 text-white">Terms of Service</h1>
        <p className="text-surface-400 mb-8">Last updated: August 2026</p>

        <div className="prose prose-invert max-w-none space-y-6 text-surface-300 leading-relaxed">
          <section>
            <h2 className="text-2xl font-semibold text-white mb-4">1. Acceptance of Terms</h2>
            <p>By installing and using DashCaddy, you agree to these terms. If you don&apos;t agree, don&apos;t use it.</p>
          </section>

          <section>
            <h2 className="text-2xl font-semibold text-white mb-4">2. What DashCaddy Is</h2>
            <p>
              DashCaddy is self-hosted software that helps you deploy and manage Docker containers, reverse proxy
              configuration, SSL certificates, and DNS records. It runs entirely on your hardware.
            </p>
          </section>

          <section>
            <h2 className="text-2xl font-semibold text-white mb-4">3. User Responsibility</h2>
            <p>
              You are solely responsible for what you deploy using DashCaddy. DashCaddy provides deployment tools — 
              it does not monitor, screen, or control what applications you choose to run.
            </p>
            <p className="mt-4">
              <strong className="text-brand-400">You must comply with all applicable laws, including copyright and intellectual property laws.</strong> 
              Always stream and access content that you own or have legal rights to. DashCaddy does not condone or 
              support piracy of any kind.
            </p>
          </section>

          <section>
            <h2 className="text-2xl font-semibold text-white mb-4">4. No Warranty</h2>
            <p>
              DashCaddy is provided &quot;as is&quot; without warranty of any kind. We are not liable for data loss, 
              service interruptions, security issues, or any damages arising from the use of DashCaddy.
            </p>
          </section>

          <section>
            <h2 className="text-2xl font-semibold text-white mb-4">5. Premium License</h2>
            <p>
              Premium features require a paid license. Licenses are validated locally. Refunds are available within 
              14 days of purchase. Contact support@dashcaddy.net.
            </p>
          </section>

          <section>
            <h2 className="text-2xl font-semibold text-white mb-4">6. Privacy</h2>
            <p>
              We collect no data. See our{' '}
              <a href="/policies/privacy" className="text-brand-400 hover:text-brand-300 font-medium">Privacy Policy</a>{' '}
              for details.
            </p>
          </section>

          <section>
            <h2 className="text-2xl font-semibold text-white mb-4">7. Contact</h2>
            <p>
              Questions? Email{' '}
              <a href="mailto:support@dashcaddy.net" className="text-brand-400 hover:text-brand-300 font-medium">
                support@dashcaddy.net
              </a>
            </p>
          </section>
        </div>
      </div>
    </div>
  );
}
