🧠 Context
There's no custom 404 page, so a bad URL falls back to the host's default (e.g. a bare GitHub Pages 404). Astro turns src/pages/404.astro into a static 404.html automatically, and GitHub Pages serves it for unknown paths. This ticket adds a small, on-brand 404 that uses the existing Base layout (so it keeps the header, footer, and site styling) and points people back to the gallery.
Files you'll touch:
src/pages/404.astro (new)
Don't edit: the layout, header, footer, or any other page. This is one self-contained route.
🛠️ Implementation Plan
-
Create src/pages/404.astro using the Base layout so it inherits the shell:
---
import Base from '../layouts/Base.astro';
---
<Base title="Page not found · CCSS Showcase">
<section>
<p>404</p>
<h1>Page not found</h1>
<p>That page doesn't exist (or moved). Try the project gallery.</p>
<a href="/projects">Back to projects</a>
</section>
</Base>
-
Style it within the token system (text-accent, text-muted, bg-ink, etc.) — keep it simple and centered. Don't pull in new assets or dependencies. Pay attention to text hierarchy and colors, try to keep it consistent with the rest of the site.
-
Verify. Run pnpm dev, hit a nonexistent path (e.g. /test), and confirm you see the custom 404 page with the header and footer present.
✅ Acceptance Criteria
🧠 Context
There's no custom 404 page, so a bad URL falls back to the host's default (e.g. a bare GitHub Pages 404). Astro turns
src/pages/404.astrointo a static404.htmlautomatically, and GitHub Pages serves it for unknown paths. This ticket adds a small, on-brand 404 that uses the existingBaselayout (so it keeps the header, footer, and site styling) and points people back to the gallery.Files you'll touch:
src/pages/404.astro(new)Don't edit: the layout, header, footer, or any other page. This is one self-contained route.
🛠️ Implementation Plan
Create
src/pages/404.astrousing theBaselayout so it inherits the shell:Style it within the token system (
text-accent,text-muted,bg-ink, etc.) — keep it simple and centered. Don't pull in new assets or dependencies. Pay attention to text hierarchy and colors, try to keep it consistent with the rest of the site.Verify. Run
pnpm dev, hit a nonexistent path (e.g./test), and confirm you see the custom 404 page with the header and footer present.✅ Acceptance Criteria
src/pages/404.astrorenders inside theBaselayout (header + footer present)./projects.pnpm buildproducesdist/404.html.pnpm format:check,pnpm check, andpnpm buildall pass.