Rebuild landing design system on the adaline pebble/meadow palette

Foundation for the adaline-based landing rebuild:
- globals.css: warm-cream light theme + Material-3 dark theme mapped onto the
  existing CSS-var names; CSS-keyframe entrance + IntersectionObserver reveal
  motion (to replace framer-motion incrementally)
- layout.tsx: self-host Instrument Sans/Serif, Newsreader and JetBrains Mono via
  next/font/google; drop the external Google Fonts <link>
- _headers: tighten CSP style/font-src to 'self' now that fonts are local
- components/ui: Container, Reveal, Eyebrow, Badge, Button, SectionHeading
- lib/landing-content.ts: feature-section copy for the six product screens
- public/images: six product screenshots optimized to WebP
- add reicon-react/reicon-brands (bundled, CSP-safe SVG icons)

Business logic (D1 download counter, platform metadata, theme, SEO) unchanged.
This commit is contained in:
ZacharyZhang-NY committed 2026-07-07 21:41:12 -04:00
1 parent 8265612206
commit b1e2374c7b
20 files changed
+433 -67

No files matched your search

+24
View File
@@ -0,0 +1,24 @@
import type { ReactNode } from "react";
/** Rounded meadow pill, optionally a link. */
export function Badge({
children,
href,
className = "",
}: {
children: ReactNode;
href?: string;
className?: string;
}) {
const classes = `eyebrow inline-flex items-center gap-1.5 self-start rounded-full px-3 py-1.5 text-sm bg-[var(--accent-soft)] text-[var(--accent)] transition-colors ${className}`;
if (href) {
return (
<a href={href} className={classes}>
{children}
</a>
);
}
return <span className={classes}>{children}</span>;
}
+47
View File
@@ -0,0 +1,47 @@
import type { ReactNode } from "react";
type ButtonVariant = "primary" | "ghost";
type ButtonSize = "md" | "sm";
const base =
"eyebrow inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-[20px] text-sm transition-colors";
const sizeClasses: Record<ButtonSize, string> = {
md: "h-11 px-6",
sm: "h-9 px-4",
};
const variantClasses: Record<ButtonVariant, string> = {
primary: "bg-[var(--cta)] text-[var(--text-on-cta)] hover:bg-[var(--cta-hover)]",
ghost: "border border-[var(--border-strong)] text-[var(--text-secondary)] hover:border-[var(--muted)]",
};
/** Link-styled call to action. Every landing CTA is an anchor. */
export function Button({
children,
href,
variant = "primary",
size = "md",
external = false,
className = "",
"aria-label": ariaLabel,
}: {
children: ReactNode;
href: string;
variant?: ButtonVariant;
size?: ButtonSize;
external?: boolean;
className?: string;
"aria-label"?: string;
}) {
return (
<a
href={href}
aria-label={ariaLabel}
{...(external ? { target: "_blank", rel: "noopener noreferrer" } : {})}
className={`${base} ${sizeClasses[size]} ${variantClasses[variant]} ${className}`}
>
{children}
</a>
);
}
+6
View File
@@ -0,0 +1,6 @@
import type { ReactNode } from "react";
/** Page-width wrapper: 1280px max, adaline grid margins (16px → 48px). */
export function Container({ children, className = "" }: { children: ReactNode; className?: string }) {
return <div className={`mx-auto w-full max-w-[1280px] px-4 md:px-12 ${className}`}>{children}</div>;
}
+10
View File
@@ -0,0 +1,10 @@
import type { ReactNode } from "react";
/** Small-caps mono label used above section headings. */
export function Eyebrow({ children, className = "" }: { children: ReactNode; className?: string }) {
return (
<span className={`eyebrow inline-flex items-center gap-1.5 text-sm text-[var(--muted)] ${className}`}>
{children}
</span>
);
}
+59
View File
@@ -0,0 +1,59 @@
"use client";
import { useEffect, useRef, useState, type CSSProperties, type ReactNode } from "react";
/**
* Scroll-reveal wrapper. Starts hidden (via the `.reveal` class) and marks
* itself in view the first time it intersects the viewport, letting CSS handle
* the rise-and-fade. Honours reduced-motion through the stylesheet.
*/
export function Reveal({
children,
delay = 0,
className = "",
}: {
children: ReactNode;
delay?: number;
className?: string;
}) {
const ref = useRef<HTMLDivElement | null>(null);
const [inView, setInView] = useState(false);
useEffect(() => {
const node = ref.current;
if (!node) {
return;
}
if (typeof IntersectionObserver === "undefined") {
setInView(true);
return;
}
const observer = new IntersectionObserver(
(entries) => {
for (const entry of entries) {
if (entry.isIntersecting) {
setInView(true);
observer.disconnect();
break;
}
}
},
{ threshold: 0.2, rootMargin: "0px 0px -10% 0px" },
);
observer.observe(node);
return () => observer.disconnect();
}, []);
return (
<div
ref={ref}
className={`reveal ${className}`}
data-in-view={inView}
style={delay ? ({ "--reveal-delay": `${delay}ms` } as CSSProperties) : undefined}
>
{children}
</div>
);
}
+32
View File
@@ -0,0 +1,32 @@
import type { ReactNode } from "react";
import { Eyebrow } from "./eyebrow";
/** Eyebrow + heading + subhead block shared by every section. */
export function SectionHeading({
eyebrow,
title,
description,
align = "left",
className = "",
}: {
eyebrow?: string;
title: ReactNode;
description?: ReactNode;
align?: "left" | "center";
className?: string;
}) {
const alignment =
align === "center" ? "items-center text-center mx-auto" : "items-start text-left";
return (
<div className={`flex max-w-[68ch] flex-col gap-3 md:gap-4 ${alignment} ${className}`}>
{eyebrow ? <Eyebrow>{eyebrow}</Eyebrow> : null}
<h2 className="text-balance text-[30px] font-medium leading-[1.12] tracking-[-0.02em] text-[var(--text)] md:text-[34px]">
{title}
</h2>
{description ? (
<p className="max-w-[62ch] text-pretty text-lg leading-relaxed text-[var(--muted)]">{description}</p>
) : null}
</div>
);
}