(motir-marketing) motir.co has NO not-found page — a 404 is Next's stock black-on-white screen with no chrome, no landmark and no way back, on four routes that call notFound()
Found while building MOTIR-4169 (the main landmark), on motir-marketing origin/main 140f2e4, 2026-09-02. Out of that card's scope — 4169 fixes the landmark on every route the site SERVES; a 404 is a response, not a route, and giving it a room is a design question 4169 does not own.
The measurement — read off the BUILD OUTPUT, not off the source
motir-marketing has no app/not-found.tsx and no app/error.tsx:
find app -name 'not-found.tsx' -o -name 'error.tsx' -o -name 'global-error.tsx' # → nothing
So Next prerenders its own. The body of .next/server/app/_not-found.html, from a clean pnpm build on 140f2e4, in full:
<div style="font-family:system-ui,…;height:100vh;text-align:center;display:flex;…">
<div>
<style>body{color:#000;background:#fff;margin:0}…</style>
<h1 class="next-error-h1" …>404</h1>
<div><h2 …>This page could not be found.</h2></div>
</div>
</div>
grep '<main' .next/server/app/_not-found.html → no match.
What a visitor actually gets
- No chrome at all — no header, no nav, no footer, no brand. Nothing on the page links anywhere, so the only way out of a 404 on motir.co is the browser's Back button or retyping the URL.
- No
mainlandmark, so the bypass mechanism MOTIR-4169 is putting on every other route stops at this one. - The theme is ignored. That inline
<style>hard-codes#000on#fffand swaps onprefers-color-schemealone — so a visitor who chose a theme, a palette or a type pairing on/designis served a page that honours none of them, insystem-uirather than the site's faces.
It is REACHED, and by four routes rather than by mistyping
Every one of these calls notFound() on ordinary input — an unknown slug, an unlisted project, a work item that is not public:
| route | when |
|---|---|
app/legal/[slug]/page.tsx | an unknown document slug |
app/explore/topic/[slug]/page.tsx | a topic slug the API does not list |
app/p/[identifier]/page.tsx (and its tabs) | a project that is not public |
app/p/[identifier]/items/[key]/page.tsx · requests/[requestKey]/page.tsx | an item or request that is not public |
/p/* makes it routine rather than exceptional: a shared link to a project whose owner turns public access off lands a real visitor here, and MOTIR-4123 already records /explore linking into that hole in production.
Root cause
Nothing is broken — nothing was ever written. Next's stock not-found is a FALLBACK that renders when a route group supplies none, and it renders OUTSIDE any of this site's shells, so it cannot inherit chrome from app/_components/SiteShell.tsx however the shells are arranged. The fix is a file that does not exist, not an edit to one that does.
The fix, and the part that is NOT mechanical
app/not-found.tsx rendering SiteShell — the chrome, the landmark, the theme — around a 404 room. What the room SAYS is a design question and this card does not answer it: motir.co's 404 is a marketing surface, and where it sends a lost visitor (Explore? the landing? a search box?) is a decision, so the fix wants a design/ pass first the way /legal had MOTIR-4005 before MOTIR-4009. design/public-site/ (motir-core) draws the chrome and no 404 room.
Note the ordering trap app/legal/layout.tsx and app/p/[identifier]/layout.tsx both already record in their own words: no loading.tsx may be introduced above a route that decides existence, or the response head flushes at 200 and the 404 becomes a page that merely looks like one (MOTIR-3491 is that defect, on the other host).
Acceptance criteria
app/not-found.tsxrenders inside the site chrome — onemainlandmark, the header and footer, the reader's theme — and the E2E lane asserts a 404 URL answers status 404 AND exposes exactly onemain.- The route stays a real 404: the status code is asserted, not just the rendering, and no
loading.tsxis added above any route that callsnotFound(). - At least one door out of the page, named by the design pass.
- The assertion runs in the existing
e2ejob with no new CI job.
Context refs
motir-marketing/app/_components/SiteShell.tsx— the chrome and the landmark, added by MOTIR-4169; what a 404 room composesmotir-marketing/app/legal/layout.tsx·app/p/[identifier]/layout.tsx— both carry the no-loading.tsx-above-a-404 rule in their own commentsmotir-marketing/e2e/routes.ts·e2e/specs/landmark.spec.ts— the route table and the landmark walk this joinsmotir-core/design/public-site/— the chrome as drawn; it draws no 404 room