NHM 고생물학 — 자연사 박물관 단색 랜딩 페이지
MIT 라이선스
pulkitxm/claude-directory갤러리에서 제공된 랜딩 페이지입니다.
단색 편집 스타일의 가상 자연사 박물관 고생물학 컬렉션 랜딩 페이지입니다. 세 개의 섹션이 연속 스크롤로 구성되어 있습니다: 지연된 배경 비디오 공개와 애니메이션 기하학적 'NHM' SVG 로고타입(폴리곤별 슬라이드업 공개)이 포함된 전체 뷰포트 히어로, 스크롤 시 나타나는 디스플레이 헤드라인과 액션 알약이 있는 'Explore Our World' 섹션, 자동 순환 화석 이미지와 사용자 정의 SVG feTurbulence/feDisplacementMap 모래 용해 전환 효과가 있는 어두운 'Ancient Collection' 장 브라우저. React 19, Vite 6, Tailwind CSS 4 (CSS 우선 구성), Motion (Framer Motion)으로 제작되었으며, 순수하게 흑백/회색 팔레트로 색상 악센트가 없습니다.
워크플로
example.html을 사용자 작업 공간에 작업 파일로 복제합니다.- 자리 표시자 콘텐츠를 사용자의 실제 브랜드명, 헤드라인, 본문, 숫자, 이미지로 교체합니다. 자산 교체 시 기존 이미지 크기를 유지합니다.
- 디자인 시스템을 유지합니다. 아래 빌드 사양의 팔레트, 서체 규모, 간격 리듬, 모션은 정체성입니다. 글꼴을 대체하거나, 팔레트 색상을 변경하거나, 장식 요소를 제거하지 마십시오.
- 섹션을 복제하여 확장하며, 다른 템플릿에서 레이아웃을 가져오지 않습니다. 섹션이 없으면 이 템플릿의 고유 어휘로 처음부터 디자인합니다.
- 모션을 접근성 있게 유지합니다. 빌드 사양에 따라 모든 애니메이션은
prefers-reduced-motion뒤에 있어야 합니다.
출력 규약
<artifact> 태그 안에 내보냅니다:
<artifact identifier="nhm-paleontology-landing" type="text/html" title="NHM 고생물학 — 자연사 박물관 단색 랜딩 페이지">
<!doctype html>
<html>...</html>
</artifact>
빌드 사양
이 디자인을 생성한 업스트림 프롬프트를 그대로 제공합니다.
NHM — 자연사 박물관 고생물학 랜딩
개요
자연사 박물관의 고생물학 컬렉션을 위한 단일 페이지, 단색 랜딩 페이지를 빌드합니다. 페이지는 하나의 연속 스크롤로 세 개의 섹션 — 지연된 배경 비디오와 기하학적 'NHM' 로고타입이 있는 전체 뷰포트 히어로, 'Explore Our World' 소개 섹션, SVG 필터 모래/용해 이미지 전환이 있는 어두운 'Ancient Collection' 장 브라우저 — 으로 구성됩니다. 전체 페이지는 단일 App.tsx 컴포넌트와 동일한 파일 내 SandTransitionImage 헬퍼, LeafIcon 헬퍼로 구성됩니다.
기술 스택
- 프레임워크: React 19 (
react,react-dom^19.0.1) withStrictMode - 빌드 도구: Vite 6 (
vite^6.2.3,@vitejs/plugin-react^5.0.4) - 언어: TypeScript (
typescript~5.8.2,@types/react^19.0.10,@types/react-dom^19.0.4) - 스타일링: Tailwind CSS 4 (
tailwindcss^4.1.14,@tailwindcss/vite^4.1.14) — CSS 우선 구성 via@theme - 애니메이션: Motion / Framer Motion (
motion^12.23.24),motion/react에서 가져옴 - 아이콘: Lucide (
lucide-react^0.546.0) - 폰트 (Google Fonts): Inter (sans, 두께 300/400/500/600) and JetBrains Mono (mono, 두께 400/500)
- 주요 기술: 지연된 배경 비디오 공개, 자동 순환 챕터 캐러셀,
requestAnimationFrame으로 구동되는 SVGfeTurbulence/feDisplacementMap모래 용해 필터, 폴리곤별 애니메이션 기하학적 로고타입,whileInView스크롤 공개.
전역 설정
index.html
lang="en",<meta charset="UTF-8" />, 뷰포트 메타width=device-width, initial-scale=1.0.- 설명 메타:
NHM — Natural History Museum. Exploring the story of life on earth through science, discovery and wonder. - 제목:
NHM — Natural History Museum - 루트:
<div id="root"></div>및<script type="module" src="/src/main.tsx"></script>.
src/main.tsx
import { StrictMode } from "react";
import { createRoot } from "react-dom/client";
import "./index.css";
import App from "./App";
createRoot(document.getElementById("root")!).render(
<StrictMode>
<App />
</StrictMode>,
);
src/index.css
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&family=JetBrains+Mono:wght@400;500&display=swap');
@import "tailwindcss";
@theme {
--font-sans: "Inter", ui-sans-serif, system-ui, sans-serif;
--font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, monospace;
}
@layer base {
body {
background-color: #fcfcfc;
color: #111;
overflow-x: hidden;
font-family: var(--font-sans);
-webkit-font-smoothing: antialiased;
}
::selection {
background-color: #000;
color: #fff;
}
}
@layer utilities {
.text-mega {
font-size: 21vw;
line-height: 0.75;
letter-spacing: -0.04em;
}
}
전역 스타일링 요약: 배경 #fcfcfc, 텍스트 #111, 선택 영역 #000 배경 / #fff 텍스트, overflow-x: hidden, 기본 폰트 font-sans (Inter), 안티앨리어싱 처리. .text-mega 유틸리티(font-size: 21vw, line-height: 0.75, letter-spacing: -0.04em)는 모든 레이아웃에 필요하지는 않지만 정의됩니다.
데이터, 상태 및 상수
임포트
import { useEffect, useRef, useState } from "react";
import { AnimatePresence, motion, usePresence } from "motion/react";
import type { Variants } from "motion/react";
import {
ArrowRight,
ArrowUpRight,
Bone,
BookOpen,
Dna,
Gem,
Leaf,
Plus,
} from "lucide-react";
에셋 URL (로컬, /assets/ 아래에 제공)
참고: 에셋은 원격 CDN이 아닌
/assets/...에서 로컬로 제공됩니다. 원래 브리핑은 Cloudinary URL을 참조했지만, 프로젝트는 이러한 정확한 (소문자, 대소문자 구분) 파일명으로 로컬에 제공합니다.
const VIDEO_URL =
"/assets/magnific_use-img-2-as-the-exact-ba_Piu3X0W42C_wnrc8f.mp4";
const PTERODACTYL_URL =
"/assets/ChatGPT_Image_May_23_2026_12_24_44_PM_1_lv1dne.png";
챕터 데이터
const chaptersData = [
{ name: "공룡의 시대", image: "/assets/01_udnber.png" },
{ name: "고대 생명체의 화석", image: "/assets/02_pmvxxl.png" },
{ name: "중생대 파충류", image: "/assets/03_hcp3jc.png" },
{ name: "해양 화석 갤러리", image: "/assets/04_get63z.png" },
{ name: "선사시대 거인들", image: "/assets/05_kz1tyu.png" },
];
기타 상수
const NAV_LINKS = ["방문", "전시", "발견", "학습", "소개"];
const ACTION_PILLS = [
{ icon: Bone, label: "공룡" },
{ icon: Dna, label: "고대 생명" },
{ icon: Gem, label: "광물" },
{ icon: Leaf, label: "화석" },
{ icon: BookOpen, label: "더 알아보기" },
];
const EASE: [number, number, number, number] = [0.16, 1, 0.3, 1];
컴포넌트 상태 (App 내부)
const [showVideo, setShowVideo] = useState(false);
const [activeChapter, setActiveChapter] = useState(2); // "중생대 파충류"에서 시작
const [isMobileMenuOpen, setIsMobileMenuOpen] = useState(false);
showVideo는 2800mssetTimeout후true로 전환됩니다 (언마운트 시 정리).activeChapter는 3500ms마다setInterval을 통해 자동 순환되며,(prev + 1) % 5로 감쌉니다 (언마운트 시 정리).
애니메이션 변형
const fadeUp: Variants = {
initial: { opacity: 0, y: 20 },
animate: { opacity: 1, y: 0 },
};
const fadeUpTransition = { duration: 0.8, ease: "easeOut" as const };
const letterBlock: Variants = {
initial: { y: 120, opacity: 0 },
animate: {
y: 0,
opacity: 1,
transition: { duration: 1.2, ease: EASE },
},
};
const logoVariants: Variants = {
initial: { scale: 1.03 },
animate: {
scale: 1,
transition: {
duration: 1.2,
ease: EASE,
staggerChildren: 0.06,
delayChildren: 0.1,
},
},
};
const staggerHeader: Variants = {
animate: { transition: { staggerChildren: 0.1, delayChildren: 0.1 } },
};
const staggerLeft: Variants = {
animate: { transition: { staggerChildren: 0.15, delayChildren: 0.6 } },
};
const staggerRight: Variants = {
animate: { transition: { staggerChildren: 0.15, delayChildren: 0.9 } },
};
const staggerPills: Variants = {
animate: { transition: { staggerChildren: 0.1, delayChildren: 0.3 } },
};
레이아웃
루트 요소: <main className="w-full">는 세 개의 <section> 블록을 포함합니다.
섹션 1 — 히어로 (전체 뷰포트 높이)
컨테이너: relative flex min-h-screen w-full flex-col overflow-hidden
1D. 배경 비디오
가장 먼저 렌더링되며(모든 항목 뒤에 위치), showVideo에 의해 제어되며 AnimatePresence 내부에 있습니다.
- 래퍼
motion.div:initial={{ opacity: 0 }},animate={{ opacity: 1 }},transition={{ duration: 1.4, ease: "easeOut" }}, 클래스pointer-events-none absolute top-0 left-0 z-0 h-full w-full. <video>:autoPlay loop muted playsInline,src={VIDEO_URL}, 클래스h-full w-full object-cover.
1A. 헤더 — NHM 로고타입
motion.header with initial="initial" animate="animate" variants={staggerHeader}, 클래스 relative z-20 px-6 pt-6 md:px-16.
motion.h1는variants={logoVariants}를 사용하며, 클래스w-full입니다.<span className="sr-only">NHM — 자연사 박물관</span>및 인라인 SVG를 포함합니다.- SVG:
viewBox="0 0 840 100", 클래스w-full overflow-hidden fill-[#111],aria-hidden="true". - 문자는
LOGO_LETTERS에서 데이터 기반으로 생성됩니다. 각 문자는<g transform={letter.translate}>이며, 각 폴리곤은motion.polygon으로variants={letterBlock}(y: 120에서 위로 슬라이드)을 갖습니다.
const LOGO_LETTERS: { translate: string; polygons: string[] }[] = [
{
// N
translate: "translate(0,0)",
polygons: [
"0,0 14,0 14,100 0,100",
"200,0 214,0 214,100 200,100",
"0,0 33,0 214,100 181,100",
],
},
{
// H
translate: "translate(280,0)",
polygons: [
"0,0 14,0 14,100 0,100",
"200,0 214,0 214,100 200,100",
"14,43 200,43 200,57 14,57",
],
},
{
// M
translate: "translate(560,0)",
polygons: [
"0,0 14,0 14,100 0,100",
"266,0 280,0 280,100 266,100",
"0,0 26,0 153,100 127,100",
"254,0 280,0 153,100 127,100",
],
},
];
1B. 서브 내비게이션 바
motion.div with variants={fadeUp} transition={fadeUpTransition}, 클래스 mt-8 flex items-start justify-between gap-3 font-mono text-[10px] tracking-[0.2em] uppercase md:text-[11px].
- 왼쪽 열 (
w-[15%]): 세 개의<p>줄 —Natura/History/Museum. - 화살표 분리선 (
hidden w-[5%] justify-center md:flex): LucideArrowRight,size={14},strokeWidth={1}, 클래스text-gray-400. - 중앙 열 (
flex-1 leading-relaxed font-mono text-gray-800 md:flex-none md:w-[30%]): 데스크톱에서는 3줄(hidden md:block)로, 모바일에서는 4줄(md:hidden)로 나뉜 카피 "Exploring the story of life on earth through science, discovery and wonder.":- 데스크톱:
Exploring the story of life/on earth through science,/discovery and wonder. - 모바일:
Exploring the story/of life on earth/through science,/discovery and wonder.
- 데스크톱:
- 화살표 분리선 (위와 동일,
hidden w-[5%] justify-center md:flex). - 오른쪽 열 / 내비게이션 (
hidden w-[15%] md:block):<ul className="space-y-1 text-gray-800">매핑NAV_LINKS— 방문, 전시, 발견, 학습, 소개 — 각각<a href="#">이며 클래스transition-colors hover:text-black hover:underline. - 햄버거 버튼 (맨 오른쪽,
md:hidden):<button type="button">witharia-label메뉴 열기/메뉴 닫기전환,aria-expanded={isMobileMenuOpen},onClick으로isMobileMenuOpen전환, 클래스group z-60 flex flex-col items-end gap-[6px] py-2 pl-4 md:hidden.- 두 개의
<span>막대, 각각 기본 클래스h-[1.5px] bg-black transition-all duration-300. - 열렸을 때: 첫 번째 막대
w-8 translate-y-[3.75px] rotate-45; 두 번째 막대w-8 -translate-y-[3.75px] -rotate-45(X자 형성). - 닫혔을 때: 첫 번째 막대
w-8 group-hover:w-6; 두 번째 막대w-8 group-hover:w-10.
- 두 개의
1C. 모바일 메뉴 오버레이
AnimatePresence가 isMobileMenuOpen일 때 표시되는 motion.div를 래핑합니다.
initial={{ y: -20, opacity: 0 }},animate={{ y: 0, opacity: 1 }},exit={{ y: -20, opacity: 0 }},transition={{ duration: 0.4, ease: EASE }}.- 클래스:
absolute top-full right-0 left-0 z-50 border-b border-gray-200 bg-[#fcfcfc] shadow-xl md:hidden. <nav className="px-6 py-10">with<ul className="space-y-6 font-mono text-sm tracking-[0.2em] uppercase">매핑 동일한NAV_LINKS; 각 링크의onClick은 메뉴를 닫습니다(setIsMobileMenuOpen(false)), 클래스transition-colors hover:text-black hover:underline.
히어로 본문 래퍼
<div className="relative z-10 flex w-full flex-1 items-start justify-between">는 왼쪽 및 오른쪽 사이드바를 보관합니다.
1E. 왼쪽 사이드바 콘텐츠
motion.div with initial="initial" animate="animate" variants={staggerLeft}, 클래스 mt-20 w-[320px] px-10 sm:mt-28 md:mt-32 md:px-16.
- 섹션 표시기 (
motion.div variants={fadeUp}, 클래스flex items-center gap-4 font-mono text-xs):<span>01</span>+<span className="h-[1.5px] w-16 bg-black/20" />. - 헤드라인 (
motion.h2 variants={fadeUp}, 클래스mt-6 text-[3.5rem] leading-[1] font-normal tracking-tight md:text-[5rem]):TIMELESS<br />WONDERS. - 설명 (
motion.p variants={fadeUp}, 클래스mt-6 w-[240px] text-[13px] leading-[1.6] text-gray-700 md:text-[14px]):자연의 세계로 들어서/수백만 년 전에 쓰여진/이야기를 발견하세요.(각 구문 사이 줄바꿈). - CTA 버튼 (
motion.div variants={fadeUp}, 클래스mt-10):<button type="button">with 클래스group relative overflow-hidden rounded-md border border-[#1a1a1a] bg-[#1a1a1a] px-6 py-3.5 shadow-sm transition-all duration-300 hover:-translate-y-[0.5px] hover:shadow-[3px_3px_0px_rgba(17,17,17,0.5)] active:translate-y-0 active:shadow-sm.- 슬라이딩 배경 패널 (
<span aria-hidden="true">): `absolute inset-0 -translate-x-[101%] bg-[#fcfcfc] transition-transform duration-700 ease-[cubic-bezier(0.16,1,0.3
- 슬라이딩 배경 패널 (
…
[번역을 위해 잘렸습니다]