// AcceptableUseContent.jsx: Acceptable Use Policy for Skardi Cloud, part of
// the Terms of Service. Written around what is specific to Skardi: connecting
// other people's data to a shared workspace, credentials that agents hold, and
// agents acting on synced content. Not yet reviewed by counsel.
const AUP_UPDATED = 'October 13, 2026';

const AUP_SECTIONS = [
  {
    id: 'data', title: 'Connect only data you may use',
    body: <>
      <LUL>
        <LLI>Connect a source only if you are entitled to, under the source's own terms and any duty you owe your employer, customers or the people whose information it holds.</LLI>
        <LLI>Do not use Skardi Cloud to get around a source's permissions: for example, by connecting a mailbox, folder or channel to a workspace so that people who could not open it in the source can read it there.</LLI>
        <LLI>Do not use Skardi Cloud to collect personal information about people without a lawful basis, or to build profiles of individuals for surveillance, discrimination or harassment.</LLI>
        <LLI>Do not connect or upload health information regulated by HIPAA, payment card data, or government identification numbers unless we have agreed to it in writing.</LLI>
      </LUL>
    </>,
  },
  {
    id: 'credentials', title: 'Keep access to yourself',
    body: <>
      <LUL>
        <LLI>Each account is for one person. Do not share your sign-in, and do not publish signup codes or invitation links.</LLI>
        <LLI>Treat personal access tokens, agent tokens and signed-in command-line sessions like passwords. Do not commit them to code repositories or paste them into shared places, and revoke any that may have been exposed.</LLI>
        <LLI>Give an agent only the access it needs, and revoke its credentials when you stop using it.</LLI>
      </LUL>
    </>,
  },
  {
    id: 'service', title: 'Do not attack or overload the service',
    body: <>
      <LUL>
        <LLI>Do not try to access another customer's workspace, data or credentials, or to break the isolation between workspaces.</LLI>
        <LLI>Do not probe, scan or test Skardi Cloud for vulnerabilities except as described in section 6, and do not try to get around authentication, quotas or rate limits.</LLI>
        <LLI>Do not send traffic designed to degrade the service, including denial-of-service attacks and automated loops of agent or API calls that run without a useful purpose.</LLI>
        <LLI>Do not upload malware, or use Skardi Cloud to distribute it.</LLI>
      </LUL>
    </>,
  },
  {
    id: 'ai', title: 'Use AI and agents responsibly',
    body: <>
      <LUL>
        <LLI>Do not plant instructions in content (prompt injection) intended to manipulate someone else's agent, to extract data it should not reveal, or to make it act against its user.</LLI>
        <LLI>Do not use Skardi Cloud to make fully automated decisions that have legal or similarly significant effects on a person, such as decisions about employment, credit, housing or access to essential services, without meaningful human review.</LLI>
        <LLI>Supervise agents that act on their own. You are responsible for their actions, including what they do with content from your sources.</LLI>
        <LLI>Do not use Skardi Cloud for uses prohibited under the EU AI Act or comparable laws.</LLI>
      </LUL>
    </>,
  },
  {
    id: 'content', title: 'Prohibited content and activities',
    body: <>
      <LP>Do not use Skardi Cloud to store, process or act on content, or carry out activities, that:</LP>
      <LUL>
        <LLI>is illegal, or promotes or facilitates illegal activity;</LLI>
        <LLI>sexually exploits or endangers children;</LLI>
        <LLI>infringes intellectual property, privacy or other rights of others;</LLI>
        <LLI>is used for fraud, phishing, impersonation or deceptive practices;</LLI>
        <LLI>is used to send spam or unsolicited bulk messages;</LLI>
        <LLI>harasses, threatens or incites violence against anyone.</LLI>
      </LUL>
    </>,
  },
  {
    id: 'security-research', title: 'Security research',
    body: <>
      <LP>We welcome reports of vulnerabilities. You may test for them only against a workspace you own, without accessing other customers' data, without degrading the service, and without social engineering or physical attacks. Report what you find to <LLink href="mailto:info@skardi.ai">info@skardi.ai</LLink> and give us reasonable time to fix it before disclosing it. We will not pursue good-faith research that follows these rules.</LP>
    </>,
  },
  {
    id: 'enforcement', title: 'Enforcement and reporting',
    body: <>
      <LP>If we reasonably believe this policy has been breached, we may remove content, revoke tokens, restrict or suspend a workspace or account, or end the Terms, as described in the <LLink href="/terms">Terms of Service</LLink>. Where we can, we will tell you first and give you a chance to fix the problem. We may report illegal activity to the appropriate authorities.</LP>
      <LP>To report a breach of this policy, email <LLink href="mailto:info@skardi.ai">info@skardi.ai</LLink>.</LP>
    </>,
  },
];

const AcceptableUseContent = () => (
  <LegalLayout
    page="acceptable-use"
    title="Acceptable Use Policy"
    updated={AUP_UPDATED}
    intro={<>
      <LP>This policy describes what you may not do with <LStrong>Skardi Cloud</LStrong>. It is part of our <LLink href="/terms">Terms of Service</LLink> and applies to everyone who uses Skardi Cloud, including through an agent or a token. Organization admins are responsible for making sure their members follow it.</LP>
    </>}
    sections={AUP_SECTIONS}
  />
);

window.AcceptableUseContent = AcceptableUseContent;
