import { ProgressBarLink } from '@/shared/components'
import { APP_NAME } from '@/shared/config/app'
import { ArrowRightIcon, BellRingIcon } from 'lucide-react'
import { Reveal } from './motion'
import { StoreButtons } from './store-buttons'

export const CallToAction = () => (
  <section className='mx-auto max-w-7xl px-4 py-16 sm:py-20 lg:px-6'>
    <Reveal className='relative isolate overflow-hidden rounded-[2rem] bg-[linear-gradient(135deg,oklch(0.42_0.14_138),oklch(0.56_0.18_132))] px-6 py-16 text-center text-white shadow-2xl shadow-primary/20 sm:px-12 lg:py-24'>
      <div
        aria-hidden
        className='absolute inset-0 -z-10 bg-[radial-gradient(rgb(255_255_255/0.18)_1px,transparent_1px)] [background-size:22px_22px] mask-fade-radial'
      />
      <BellRingIcon
        aria-hidden
        className='absolute -right-12 -top-12 -z-10 size-72 rotate-12 text-white/[0.07]'
      />
      <h2 className='mx-auto max-w-3xl font-display text-3xl font-bold tracking-tight text-balance sm:text-4xl lg:text-5xl'>
        Не пропускайте ни одного заказа
      </h2>
      <p className='mx-auto mt-5 max-w-2xl text-lg text-white/85 text-pretty'>
        Скачайте {APP_NAME}&nbsp;— это бесплатно. Подключение первого сайта
        займёт пару минут.
      </p>
      <StoreButtons variant='light' className='mt-10 justify-center' />
      <ProgressBarLink
        href='/auth/signup'
        className='group mt-6 inline-flex items-center gap-1.5 text-sm font-medium text-white/85 transition-colors hover:text-white'
      >
        Или зарегистрируйтесь в веб-версии
        <ArrowRightIcon className='size-4 transition-transform group-hover:translate-x-0.5' />
      </ProgressBarLink>
    </Reveal>
  </section>
)
