diff --git a/src/components/Diagram.astro b/src/components/Diagram.astro new file mode 100644 index 0000000..400fd8b --- /dev/null +++ b/src/components/Diagram.astro @@ -0,0 +1,225 @@ +--- +// Hand-authored, theme-aware architecture diagrams rendered as inline SVG at build. +// No client JS, no headless browser, no inline diff --git a/src/components/Hero.astro b/src/components/Hero.astro index a692a96..4234817 100644 --- a/src/components/Hero.astro +++ b/src/components/Hero.astro @@ -90,4 +90,37 @@ import { cvAvailable } from "../lib/assets"; flex-wrap: wrap; gap: var(--space-3); } + + /* Staggered entrance — CSS-only (runs with JS off), motion-aware. */ + @media (prefers-reduced-motion: no-preference) { + .hero__eyebrow, + .hero__title, + .hero__positioning, + .hero__tags, + .hero__cta { + animation: heroIn 0.7s var(--ease) both; + } + .hero__title { + animation-delay: 0.06s; + } + .hero__positioning { + animation-delay: 0.14s; + } + .hero__tags { + animation-delay: 0.22s; + } + .hero__cta { + animation-delay: 0.3s; + } + } + @keyframes heroIn { + from { + opacity: 0; + transform: translateY(12px); + } + to { + opacity: 1; + transform: none; + } + } diff --git a/src/pages/projects/[slug].astro b/src/pages/projects/[slug].astro index d8da119..693e4e5 100644 --- a/src/pages/projects/[slug].astro +++ b/src/pages/projects/[slug].astro @@ -1,5 +1,6 @@ --- import Layout from "../../layouts/Layout.astro"; +import Diagram from "../../components/Diagram.astro"; import { getCollection, render } from "astro:content"; import type { GetStaticPaths } from "astro"; @@ -40,6 +41,8 @@ const { Content } = await render(entry); )} + {p.diagram && } +