Spaces:
Running
Running
axeronis commited on
Commit ·
164c79f
1
Parent(s): 6e7279e
feat(landing): add login button, language switcher (RU/EN/KY), partner program section, rename Unlimited to Enterprise
Browse files- frontend/app/page.tsx +100 -7
frontend/app/page.tsx
CHANGED
|
@@ -6,7 +6,7 @@ import {
|
|
| 6 |
CheckCircle, TrendingUp, Sparkles, Clock, UserX,
|
| 7 |
Calendar, MessageCircle, ChevronDown, Check, Send,
|
| 8 |
Globe, Mic, AlertTriangle, RefreshCw, FileText, Users,
|
| 9 |
-
XCircle, Timer, DollarSign, ShoppingBag
|
| 10 |
} from 'lucide-react'
|
| 11 |
import { motion, AnimatePresence } from 'framer-motion'
|
| 12 |
import { useState, useRef, useEffect } from 'react'
|
|
@@ -64,7 +64,7 @@ const FEATURE_COLORS: Record<string, { bg: string; text: string; border: string;
|
|
| 64 |
const PLANS = [
|
| 65 |
{ name: 'Start', price: 99, limit: '500 диалогов', popular: false },
|
| 66 |
{ name: 'Growth', price: 199, limit: '1,500 диалогов', popular: true },
|
| 67 |
-
{ name: '
|
| 68 |
]
|
| 69 |
|
| 70 |
const FAQS = [
|
|
@@ -74,11 +74,29 @@ const FAQS = [
|
|
| 74 |
{ q: 'Есть ли скидки при оплате за год?', a: 'Да, вы экономите 30% при оплате годовой подписки.' },
|
| 75 |
]
|
| 76 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 77 |
// --- COMPONENT ---
|
| 78 |
|
| 79 |
export default function HomePage() {
|
| 80 |
const [activeFaq, setActiveFaq] = useState<number | null>(null)
|
| 81 |
const [isYearly, setIsYearly] = useState(true)
|
|
|
|
|
|
|
|
|
|
| 82 |
|
| 83 |
// Demo Chat State
|
| 84 |
const [messages, setMessages] = useState<{ role: 'bot' | 'user', text: string }[]>([
|
|
@@ -157,11 +175,47 @@ export default function HomePage() {
|
|
| 157 |
</Link>
|
| 158 |
|
| 159 |
<div className="hidden md:flex items-center gap-8 text-sm font-medium text-slate-300">
|
| 160 |
-
<Link href="#features" className="hover:text-cyan-400 transition-colors">
|
| 161 |
-
<Link href="#pricing" className="hover:text-cyan-400 transition-colors">
|
| 162 |
-
<Link href="#how-it-works" className="hover:text-cyan-400 transition-colors">
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 163 |
</div>
|
| 164 |
-
<div className="w-8" />
|
| 165 |
</div>
|
| 166 |
</nav>
|
| 167 |
|
|
@@ -601,7 +655,46 @@ export default function HomePage() {
|
|
| 601 |
</div>
|
| 602 |
</section>
|
| 603 |
|
| 604 |
-
{/* 9.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 605 |
<section className="py-32 px-6">
|
| 606 |
<div className="max-w-4xl mx-auto text-center">
|
| 607 |
<h2 className="text-5xl md:text-6xl font-black text-white mb-8 tracking-tight">
|
|
|
|
| 6 |
CheckCircle, TrendingUp, Sparkles, Clock, UserX,
|
| 7 |
Calendar, MessageCircle, ChevronDown, Check, Send,
|
| 8 |
Globe, Mic, AlertTriangle, RefreshCw, FileText, Users,
|
| 9 |
+
XCircle, Timer, DollarSign, ShoppingBag, Languages, LogIn, Handshake
|
| 10 |
} from 'lucide-react'
|
| 11 |
import { motion, AnimatePresence } from 'framer-motion'
|
| 12 |
import { useState, useRef, useEffect } from 'react'
|
|
|
|
| 64 |
const PLANS = [
|
| 65 |
{ name: 'Start', price: 99, limit: '500 диалогов', popular: false },
|
| 66 |
{ name: 'Growth', price: 199, limit: '1,500 диалогов', popular: true },
|
| 67 |
+
{ name: 'Enterprise', price: 499, limit: 'Безлимит диалогов', popular: false },
|
| 68 |
]
|
| 69 |
|
| 70 |
const FAQS = [
|
|
|
|
| 74 |
{ q: 'Есть ли скидки при оплате за год?', a: 'Да, вы экономите 30% при оплате годовой подписки.' },
|
| 75 |
]
|
| 76 |
|
| 77 |
+
const LANGUAGES = [
|
| 78 |
+
{ code: 'ru', name: 'Русский', flag: '🇷🇺' },
|
| 79 |
+
{ code: 'en', name: 'English', flag: '🇺🇸' },
|
| 80 |
+
{ code: 'ky', name: 'Кыргызча', flag: '🇰🇬' }
|
| 81 |
+
]
|
| 82 |
+
|
| 83 |
+
type LangCode = 'ru' | 'en' | 'ky'
|
| 84 |
+
|
| 85 |
+
const T: Record<LangCode, Record<string, string>> = {
|
| 86 |
+
ru: { features: 'Возможности', pricing: 'Цены', howItWorks: 'Как это работает', login: 'Войти', partner: 'Партнёрам' },
|
| 87 |
+
en: { features: 'Features', pricing: 'Pricing', howItWorks: 'How it works', login: 'Login', partner: 'Partners' },
|
| 88 |
+
ky: { features: 'Мүмкүнчүлүктөр', pricing: 'Баалар', howItWorks: 'Кантип иштейт', login: 'Кирүү', partner: 'Өнөктөштөр' }
|
| 89 |
+
}
|
| 90 |
+
|
| 91 |
+
|
| 92 |
// --- COMPONENT ---
|
| 93 |
|
| 94 |
export default function HomePage() {
|
| 95 |
const [activeFaq, setActiveFaq] = useState<number | null>(null)
|
| 96 |
const [isYearly, setIsYearly] = useState(true)
|
| 97 |
+
const [lang, setLang] = useState<LangCode>('ru')
|
| 98 |
+
const [showLangMenu, setShowLangMenu] = useState(false)
|
| 99 |
+
const t = T[lang]
|
| 100 |
|
| 101 |
// Demo Chat State
|
| 102 |
const [messages, setMessages] = useState<{ role: 'bot' | 'user', text: string }[]>([
|
|
|
|
| 175 |
</Link>
|
| 176 |
|
| 177 |
<div className="hidden md:flex items-center gap-8 text-sm font-medium text-slate-300">
|
| 178 |
+
<Link href="#features" className="hover:text-cyan-400 transition-colors">{t.features}</Link>
|
| 179 |
+
<Link href="#pricing" className="hover:text-cyan-400 transition-colors">{t.pricing}</Link>
|
| 180 |
+
<Link href="#how-it-works" className="hover:text-cyan-400 transition-colors">{t.howItWorks}</Link>
|
| 181 |
+
<Link href="#partners" className="hover:text-cyan-400 transition-colors">{t.partner}</Link>
|
| 182 |
+
</div>
|
| 183 |
+
|
| 184 |
+
<div className="flex items-center gap-3">
|
| 185 |
+
{/* Language Switcher */}
|
| 186 |
+
<div className="relative">
|
| 187 |
+
<button
|
| 188 |
+
onClick={() => setShowLangMenu(!showLangMenu)}
|
| 189 |
+
className="flex items-center gap-2 px-3 py-2 rounded-lg hover:bg-white/10 transition-colors text-sm"
|
| 190 |
+
>
|
| 191 |
+
<Languages className="w-4 h-4" />
|
| 192 |
+
<span>{LANGUAGES.find(l => l.code === lang)?.flag}</span>
|
| 193 |
+
</button>
|
| 194 |
+
{showLangMenu && (
|
| 195 |
+
<div className="absolute right-0 top-full mt-2 bg-[#0B0C15] border border-white/10 rounded-xl py-2 min-w-[140px] shadow-xl z-50">
|
| 196 |
+
{LANGUAGES.map((language) => (
|
| 197 |
+
<button
|
| 198 |
+
key={language.code}
|
| 199 |
+
onClick={() => { setLang(language.code as LangCode); setShowLangMenu(false); }}
|
| 200 |
+
className={`w-full px-4 py-2 text-left text-sm hover:bg-white/10 transition-colors flex items-center gap-3 ${lang === language.code ? 'text-cyan-400' : 'text-slate-300'}`}
|
| 201 |
+
>
|
| 202 |
+
<span>{language.flag}</span>
|
| 203 |
+
<span>{language.name}</span>
|
| 204 |
+
</button>
|
| 205 |
+
))}
|
| 206 |
+
</div>
|
| 207 |
+
)}
|
| 208 |
+
</div>
|
| 209 |
+
|
| 210 |
+
{/* Login Button */}
|
| 211 |
+
<Link
|
| 212 |
+
href="/login"
|
| 213 |
+
className="flex items-center gap-2 px-4 py-2 rounded-lg border border-white/10 hover:bg-white/10 transition-colors text-sm font-medium"
|
| 214 |
+
>
|
| 215 |
+
<LogIn className="w-4 h-4" />
|
| 216 |
+
<span className="hidden sm:inline">{t.login}</span>
|
| 217 |
+
</Link>
|
| 218 |
</div>
|
|
|
|
| 219 |
</div>
|
| 220 |
</nav>
|
| 221 |
|
|
|
|
| 655 |
</div>
|
| 656 |
</section>
|
| 657 |
|
| 658 |
+
{/* 9. PARTNER PROGRAM */}
|
| 659 |
+
<section id="partners" className="py-24 px-6 bg-gradient-to-br from-cyan-500/5 via-transparent to-emerald-500/5">
|
| 660 |
+
<div className="max-w-4xl mx-auto text-center">
|
| 661 |
+
<div className="inline-flex items-center gap-2 px-4 py-2 rounded-full bg-cyan-500/10 border border-cyan-500/20 text-cyan-400 text-sm font-bold mb-8">
|
| 662 |
+
<Handshake className="w-4 h-4" />
|
| 663 |
+
{lang === 'ru' ? 'Партнёрская программа' : lang === 'en' ? 'Partner Program' : 'Өнөктөш программасы'}
|
| 664 |
+
</div>
|
| 665 |
+
<h2 className="text-4xl md:text-5xl font-black text-white mb-6">
|
| 666 |
+
{lang === 'ru' ? 'Зарабатывайте вместе с нами' : lang === 'en' ? 'Earn with us' : 'Биз менен табыңыз'}
|
| 667 |
+
</h2>
|
| 668 |
+
<p className="text-xl text-slate-400 mb-12 max-w-2xl mx-auto">
|
| 669 |
+
{lang === 'ru' ? 'Приводите клиентов в MicroFunnel и получайте 30% от всех их платежей — пожизненно.' : lang === 'en' ? 'Refer clients to MicroFunnel and earn 30% of all their payments — for life.' : 'MicroFunnel-га кардарларды алып келиңиз жана алардын бардык төлөмдөрүнүн 30% алыңыз — өмүр бою.'}
|
| 670 |
+
</p>
|
| 671 |
+
|
| 672 |
+
<div className="grid md:grid-cols-3 gap-6 mb-12">
|
| 673 |
+
<div className="p-6 rounded-2xl bg-[#0B0C15] border border-white/5">
|
| 674 |
+
<div className="text-4xl font-black text-cyan-400 mb-2">30%</div>
|
| 675 |
+
<div className="text-slate-400">{lang === 'ru' ? 'комиссия с каждого платежа' : lang === 'en' ? 'commission per payment' : 'ар бир төлөмдөн комиссия'}</div>
|
| 676 |
+
</div>
|
| 677 |
+
<div className="p-6 rounded-2xl bg-[#0B0C15] border border-white/5">
|
| 678 |
+
<div className="text-4xl font-black text-emerald-400 mb-2">∞</div>
|
| 679 |
+
<div className="text-slate-400">{lang === 'ru' ? 'пожизненные выплаты' : lang === 'en' ? 'lifetime payouts' : 'өмүр бою төлөмдөр'}</div>
|
| 680 |
+
</div>
|
| 681 |
+
<div className="p-6 rounded-2xl bg-[#0B0C15] border border-white/5">
|
| 682 |
+
<div className="text-4xl font-black text-purple-400 mb-2">$49</div>
|
| 683 |
+
<div className="text-slate-400">{lang === 'ru' ? 'единоразовая активация' : lang === 'en' ? 'one-time activation' : 'бир жолку активация'}</div>
|
| 684 |
+
</div>
|
| 685 |
+
</div>
|
| 686 |
+
|
| 687 |
+
<Link
|
| 688 |
+
href="/register?partner=true"
|
| 689 |
+
className="inline-flex items-center gap-3 px-8 py-4 bg-gradient-to-r from-cyan-500 to-emerald-500 text-black font-bold text-lg rounded-xl hover:opacity-90 transition-all"
|
| 690 |
+
>
|
| 691 |
+
<Handshake className="w-5 h-5" />
|
| 692 |
+
{lang === 'ru' ? 'Стать партнёром' : lang === 'en' ? 'Become a partner' : 'Өнөктөш болуу'}
|
| 693 |
+
</Link>
|
| 694 |
+
</div>
|
| 695 |
+
</section>
|
| 696 |
+
|
| 697 |
+
{/* 10. MINIMALIST FINAL CTA - 7 days */}
|
| 698 |
<section className="py-32 px-6">
|
| 699 |
<div className="max-w-4xl mx-auto text-center">
|
| 700 |
<h2 className="text-5xl md:text-6xl font-black text-white mb-8 tracking-tight">
|