Landing redesign: animated hero, draw cards, how-it-works, footer
Keeps only countries with archived results (Québec, France, US, Spain, Portugal). The landing gets motion and a real structure: staggered fade-in hero with a floating Loki, twinkling stars, a shimmering gold CTA and counters that tick up (draws archived, lotteries, countries); draw cards in place of the table, with lottery balls dropping in and a lift-on-hover; a three-step "Comment ça marche"; and a site-wide footer with links, covered countries, responsible-play note and 18+ notice. All motion is disabled under prefers-reduced-motion. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
302915d888
commit
ad214a24dd
+106
-34
@@ -1,44 +1,116 @@
|
||||
import Image from "next/image"
|
||||
import Link from "next/link"
|
||||
import { Button } from "@/components/ui/button"
|
||||
import { ArrowRight, Sparkles } from "lucide-react"
|
||||
import { CountUp } from "@/components/count-up"
|
||||
|
||||
/** Compact promo banner, 1xbet-style: short, wide, one message and one CTA — data stays above the fold. */
|
||||
export function Hero({ isAuthenticated }: { isAuthenticated: boolean }) {
|
||||
const STARS = [
|
||||
{ top: "12%", left: "48%", delay: "0s" },
|
||||
{ top: "22%", left: "62%", delay: "1.1s" },
|
||||
{ top: "8%", left: "72%", delay: "0.5s" },
|
||||
{ top: "30%", left: "54%", delay: "1.8s" },
|
||||
{ top: "16%", left: "88%", delay: "0.8s" },
|
||||
{ top: "40%", left: "92%", delay: "2.2s" },
|
||||
]
|
||||
|
||||
export function Hero({
|
||||
isAuthenticated,
|
||||
draws,
|
||||
lotteries,
|
||||
countries,
|
||||
}: {
|
||||
isAuthenticated: boolean
|
||||
draws: number
|
||||
lotteries: number
|
||||
countries: number
|
||||
}) {
|
||||
return (
|
||||
<section className="relative isolate overflow-hidden rounded-lg border border-gold/25">
|
||||
<img
|
||||
src="/lokilab/backgrounds/observatory-desktop.webp"
|
||||
alt=""
|
||||
aria-hidden="true"
|
||||
className="absolute inset-0 -z-20 h-full w-full object-cover object-[center_35%]"
|
||||
/>
|
||||
<section className="relative isolate overflow-hidden border-b border-border">
|
||||
<picture className="absolute inset-0 -z-20">
|
||||
<source media="(max-width: 767px)" srcSet="/lokilab/backgrounds/observatory-mobile.webp" />
|
||||
<img src="/lokilab/backgrounds/observatory-desktop.webp" alt="" aria-hidden="true" className="h-full w-full object-cover" />
|
||||
</picture>
|
||||
<div className="absolute inset-0 -z-10 bg-gradient-to-r from-background via-background/85 to-background/20" />
|
||||
|
||||
<div className="flex min-h-[176px] items-center justify-between gap-4 pl-5 sm:pl-8">
|
||||
<div className="py-5">
|
||||
<p className="text-[11px] font-semibold uppercase tracking-[0.2em] text-mint">L'armée de Loki</p>
|
||||
<h1 className="mt-1.5 font-display text-2xl leading-tight sm:text-3xl">
|
||||
Loki lit les tirages. <span className="text-gold">Suivez ses choix.</span>
|
||||
</h1>
|
||||
<p className="mt-1.5 max-w-md text-sm text-muted-foreground">
|
||||
Suivez ses pronostics, grimpez au classement — gratuit.
|
||||
</p>
|
||||
<Button asChild size="sm" className="mt-3.5 h-9 px-5 font-semibold">
|
||||
<Link href={isAuthenticated ? "/classement" : "/connexion?mode=inscription"}>
|
||||
{isAuthenticated ? "Voir le classement" : "Rejoindre l'armée"}
|
||||
</Link>
|
||||
</Button>
|
||||
</div>
|
||||
<Image
|
||||
src="/lokilab/mascots/loki-welcome-320.webp"
|
||||
alt=""
|
||||
aria-hidden="true"
|
||||
width={320}
|
||||
height={480}
|
||||
priority
|
||||
className="hidden h-[176px] w-auto self-end object-cover object-top sm:block sm:mr-6"
|
||||
<div className="absolute inset-x-0 bottom-0 -z-10 h-24 bg-gradient-to-t from-background to-transparent" />
|
||||
{STARS.map((s, i) => (
|
||||
<span
|
||||
key={i}
|
||||
aria-hidden
|
||||
className="animate-twinkle absolute -z-10 h-1 w-1 rounded-full bg-gold-light shadow-[0_0_8px_2px_rgba(255,227,163,0.7)]"
|
||||
style={{ top: s.top, left: s.left, animationDelay: s.delay }}
|
||||
/>
|
||||
))}
|
||||
|
||||
<div className="mx-auto grid max-w-6xl grid-cols-1 items-center gap-4 px-4 sm:px-6 md:grid-cols-[1.15fr_0.85fr]">
|
||||
<div className="py-10 md:py-14">
|
||||
<p className="animate-fade-up inline-flex items-center gap-1.5 rounded-full border border-mint/30 bg-mint/10 px-3 py-1 text-[11px] font-semibold uppercase tracking-[0.18em] text-mint">
|
||||
<Sparkles className="h-3 w-3" /> L'armée de Loki
|
||||
</p>
|
||||
<h1
|
||||
className="animate-fade-up mt-4 font-display text-4xl leading-[1.08] sm:text-5xl"
|
||||
style={{ animationDelay: "120ms" }}
|
||||
>
|
||||
Loki lit les tirages.
|
||||
<br />
|
||||
<span className="bg-gradient-to-r from-gold-light via-gold to-gold-light bg-clip-text text-transparent">
|
||||
Vous suivez ses choix.
|
||||
</span>
|
||||
</h1>
|
||||
<p
|
||||
className="animate-fade-up mt-4 max-w-md text-[15px] leading-relaxed text-muted-foreground"
|
||||
style={{ animationDelay: "240ms" }}
|
||||
>
|
||||
Résultats officiels, statistiques et pronostics de loterie au Québec, en France, aux
|
||||
États-Unis, en Espagne et au Portugal.
|
||||
</p>
|
||||
|
||||
<div className="animate-fade-up mt-6 flex flex-wrap items-center gap-3" style={{ animationDelay: "360ms" }}>
|
||||
<Link
|
||||
href={isAuthenticated ? "/classement" : "/connexion?mode=inscription"}
|
||||
className="shimmer relative inline-flex h-11 items-center gap-2 overflow-hidden rounded-md bg-gold px-6 text-sm font-semibold text-primary-foreground shadow-[0_0_28px_rgba(244,199,107,0.35)] transition-transform hover:-translate-y-0.5"
|
||||
>
|
||||
{isAuthenticated ? "Voir le classement" : "Rejoindre l'armée — gratuit"}
|
||||
<ArrowRight className="h-4 w-4" />
|
||||
</Link>
|
||||
<a
|
||||
href="#tirages"
|
||||
className="inline-flex h-11 items-center rounded-md border border-gold/30 bg-background/40 px-5 text-sm font-medium backdrop-blur transition-colors hover:bg-gold/10"
|
||||
>
|
||||
Derniers tirages
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<dl className="animate-fade-up mt-8 flex gap-8" style={{ animationDelay: "480ms" }}>
|
||||
<HeroStat value={draws} label="tirages archivés" />
|
||||
<HeroStat value={lotteries} label="loteries" />
|
||||
<HeroStat value={countries} label="pays" />
|
||||
</dl>
|
||||
</div>
|
||||
|
||||
<div className="relative hidden h-full items-end justify-center md:flex">
|
||||
<div className="animate-glow absolute bottom-16 h-72 w-72 rounded-full bg-gold/25 blur-3xl" />
|
||||
<Image
|
||||
src="/lokilab/mascots/loki-welcome.webp"
|
||||
alt="Loki salue de la main"
|
||||
width={640}
|
||||
height={960}
|
||||
priority
|
||||
sizes="400px"
|
||||
className="animate-float relative h-[420px] w-auto drop-shadow-[0_24px_40px_rgba(0,0,0,0.6)]"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
)
|
||||
}
|
||||
|
||||
function HeroStat({ value, label }: { value: number; label: string }) {
|
||||
return (
|
||||
<div>
|
||||
<dt className="sr-only">{label}</dt>
|
||||
<dd className="font-display text-3xl leading-none text-gold">
|
||||
<CountUp value={value} />
|
||||
</dd>
|
||||
<p className="mt-1 text-xs text-muted-foreground">{label}</p>
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user