// Stashly Privacy Policy page. window.StashlyPrivacy.
const { SectionLabel, Card, Icon } = window.StashlyDesignSystem_821802;
const PH = ({ children }) => <span style={{ background: 'var(--orange-50)', color: 'var(--orange-700)', borderRadius: 6, padding: '1px 7px', fontWeight: 600, fontSize: '0.92em' }}>{children}</span>;

const prose = { fontFamily: 'var(--font-body)', fontSize: 16.5, lineHeight: 1.7, color: 'var(--text-body)' };
const h3 = { fontFamily: 'var(--font-display)', fontSize: 24, color: 'var(--text-strong)', margin: '0 0 12px' };

function Block({ title, children }) {
  return (
    <div style={{ marginBottom: 34 }}>
      <h3 style={h3}>{title}</h3>
      <div style={prose}>{children}</div>
    </div>
  );
}
function Bullets({ items }) {
  return (
    <ul style={{ listStyle: 'none', padding: 0, margin: '8px 0 0', display: 'flex', flexDirection: 'column', gap: 10 }}>
      {items.map((it, i) => (
        <li key={i} style={{ display: 'flex', gap: 12, ...prose }}>
          <Icon name="check" size={19} style={{ color: 'var(--color-primary)', flex: '0 0 auto', marginTop: 4 }} />
          <span>{it}</span>
        </li>
      ))}
    </ul>
  );
}

function Privacy() {
  return (
    <div style={{ background: 'var(--bg-page)' }}>
      <window.Nav />
      <section style={{ background: 'var(--burgundy-500)', color: 'var(--cream-200)', padding: '60px 0 56px' }}>
        <div style={{ maxWidth: 820, margin: '0 auto', padding: '0 28px' }}>
          <SectionLabel color="var(--orange-400)">stashly.life/privacy</SectionLabel>
          <h1 style={{ fontFamily: 'var(--font-display)', fontSize: 52, margin: '14px 0 10px' }}>Privacy Policy</h1>
          <p style={{ fontFamily: 'var(--font-body)', fontSize: 15, color: 'var(--cream-300)', margin: 0 }}>Last updated: <PH>[DATE]</PH></p>
        </div>
      </section>
      <section style={{ padding: '56px 0 80px' }}>
        <div style={{ maxWidth: 820, margin: '0 auto', padding: '0 28px' }}>
          <p style={{ ...prose, marginBottom: 36 }}>
            Stashly ("Stashly", "we", "us") is operated by <PH>[LEGAL OWNER / COMPANY NAME]</PH>, based in <PH>[COUNTRY / JURISDICTION]</PH>. This Privacy Policy explains what we collect when you use the Stashly app and website, how we use it, and the choices you have.
          </p>

          <Block title="Information we collect">
            <Bullets items={[
              <span><b>Account information:</b> when you create an account or join our waitlist — name, email, and any profile details you choose to provide.</span>,
              <span><b>Your beauty stash content:</b> the products, collections, reviews, notes, and routines you add to the app.</span>,
              <span><b>Usage information:</b> how you interact with the app — features used, challenges joined, actions taken.</span>,
              <span><b>Device and technical data:</b> device type, operating system, app version, identifiers (including advertising identifiers), and general location inferred from your IP address.</span>,
            ]} />
          </Block>

          <Block title="How we use your information">
            To provide and personalize the app; remember your collection and send relevant reminders (like expirations); power community features, challenges, and rewards; understand and improve how Stashly is used; communicate with you about updates, perks, and opportunities; and keep Stashly secure.
          </Block>

          <Block title="Analytics and third-party services">
            We work with trusted third parties to run and measure the app:
            <Bullets items={[
              <span><b>AppsFlyer</b> — a mobile measurement and attribution provider that helps us understand how people discover and use Stashly. AppsFlyer may process device identifiers and usage events on our behalf.</span>,
              <span><b>Apple App Store &amp; Google Play</b> — for distribution, in-app purchases, and related analytics, under their own privacy policies.</span>,
              <span><b>Hosting and infrastructure providers</b> that store data on our behalf.</span>,
            ]} />
            <p style={{ ...prose, marginTop: 14 }}>We do <b>not</b> sell your personal information.</p>
          </Block>

          <Block title="Sharing your information">
            We only share personal information with service providers who help us run Stashly, when required by law, or as part of a business transfer. Community content you choose to make public (reviews, shared collections) may be visible to other users.
          </Block>

          <Block title="Data retention">
            We keep your information while your account is active or as needed to provide the service, and only as long as necessary for the purposes above or as required by law.
          </Block>

          <Block title="Your rights and choices">
            Depending on where you live, you may have the right to access, correct, export, or delete your personal information, and to limit certain processing. Contact us at <PH>[SUPPORT EMAIL]</PH> to make a request. You can request deletion of your account and data at any time.
          </Block>

          <Block title="Children's privacy">
            Stashly is not intended for children under 13, and we do not knowingly collect their information.
          </Block>

          <Block title="Security">
            We take reasonable measures to protect your information, though no method of storage or transmission is completely secure.
          </Block>

          <Block title="Changes to this policy">
            We may update this policy from time to time and will revise the "last updated" date above.
          </Block>

          <Card padding="md" tone="default" style={{ marginTop: 8 }}>
            <h3 style={{ ...h3, marginBottom: 8 }}>Contact us</h3>
            <p style={{ ...prose, margin: 0 }}>Questions about this policy or your data? Email <PH>[SUPPORT EMAIL]</PH>.</p>
          </Card>
        </div>
      </section>
      <window.Footer />
    </div>
  );
}
window.StashlyPrivacy = Privacy;
