16-file refinement (mono system intact): oversized tight headlines + giant faint mono indices as texture, single shared hairline grids over boxes, wider 8px vertical rhythm, restrained hairline-draw hover micro-interactions, red kept to <=1 per screen. Copy cut to terse, confident Swedish across landing + app screens. Logic/props/ids/contracts preserved; tsc clean, next build green. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
80 lines
3.4 KiB
TypeScript
80 lines
3.4 KiB
TypeScript
"use client";
|
|
|
|
import { useReveal } from "@/hooks/use-reveal";
|
|
import { MARKETS } from "@/lib/data";
|
|
|
|
const STATS = [
|
|
["4 980", "poster i exempel"],
|
|
["20", "utelämnade. Ej gissade"],
|
|
["3,2", "källor per fält"],
|
|
];
|
|
|
|
export function CollectionSection() {
|
|
const ref = useReveal<HTMLElement>();
|
|
const liveCount = MARKETS.filter((m) => m.live).length;
|
|
return (
|
|
<section ref={ref} id="tackning" className="border-b border-border bg-background">
|
|
<div className="mx-auto max-w-[80rem] px-6 py-32 lg:py-40">
|
|
<div className="flex items-baseline justify-between gap-6 border-b border-border pb-6">
|
|
<p className="reveal font-mono text-[11px] uppercase tracking-[0.18em] text-muted-foreground">04 — Täckning</p>
|
|
<p className="reveal delay-1 font-mono text-[11px] uppercase tracking-[0.18em] text-muted-foreground">{liveCount}/{MARKETS.length} live</p>
|
|
</div>
|
|
|
|
<div className="mt-12 grid items-end gap-y-8 lg:grid-cols-12 lg:gap-x-10">
|
|
<h2 className="reveal delay-1 col-span-8 text-[clamp(2.4rem,6vw,4.75rem)] font-medium leading-[0.95] tracking-[-0.03em]">
|
|
Tjugo marknader.
|
|
<br />
|
|
En modell.
|
|
</h2>
|
|
<p className="reveal-fade delay-2 col-span-4 font-mono text-[13px] leading-relaxed text-muted-foreground lg:text-right">
|
|
Samma motor. Samma bevis.
|
|
<br />
|
|
Varje land.
|
|
</p>
|
|
</div>
|
|
|
|
<div className="reveal delay-2 mt-16 grid grid-cols-[repeat(auto-fill,minmax(108px,1fr))] gap-px border border-border bg-border">
|
|
{MARKETS.map((m, i) => (
|
|
<div
|
|
key={m.code}
|
|
className="group relative bg-background p-4 transition-opacity duration-300"
|
|
style={{ opacity: m.live ? 1 : 0.4 }}
|
|
>
|
|
<div className="flex items-baseline justify-between">
|
|
<p className="font-mono text-sm font-semibold tracking-tight">{m.code}</p>
|
|
<span className="font-mono text-[9px] text-muted-foreground/60">{String(i + 1).padStart(2, "0")}</span>
|
|
</div>
|
|
<p className="mt-1 font-mono text-[10px] uppercase tracking-[0.08em] text-muted-foreground">
|
|
{m.live ? `${m.coverage}%` : "kommande"}
|
|
</p>
|
|
<div className="mt-3 h-px w-full bg-secondary">
|
|
<div
|
|
className="h-full transition-[width] duration-500"
|
|
style={{
|
|
width: `${m.coverage}%`,
|
|
backgroundColor: m.coverage >= 95 ? "var(--prov-3)" : m.coverage >= 85 ? "var(--prov-2)" : "var(--muted-foreground)",
|
|
}}
|
|
/>
|
|
</div>
|
|
</div>
|
|
))}
|
|
</div>
|
|
|
|
<div className="reveal delay-3 mt-px grid grid-cols-1 gap-px border border-border bg-border sm:grid-cols-3">
|
|
{STATS.map(([n, l], i) => (
|
|
<div key={l} className="bg-background p-6">
|
|
<p
|
|
className="text-[clamp(2.25rem,4vw,3rem)] font-medium leading-none tracking-[-0.03em]"
|
|
style={i === 1 ? { color: "var(--accent-red)" } : undefined}
|
|
>
|
|
{n}
|
|
</p>
|
|
<p className="mt-3 font-mono text-[10px] uppercase tracking-[0.1em] text-muted-foreground">{l}</p>
|
|
</div>
|
|
))}
|
|
</div>
|
|
</div>
|
|
</section>
|
|
);
|
|
}
|