TITLE Cabinet of Impossible Minerals PROMPT A museum display case holding seven invented minerals, each a real-time raymarched crystal rendered with hand-written WebGL fragment shaders. Concept: a mineralogy gallery for specimens that cannot exist; the label copy is deadpan curatorial fiction, the rendering is seductive. Mood: hushed, luxurious, a dark gallery with one lamp. Palette: velvet black-plum #0E0B10, case interior aubergine #2A1E2E, brass #C9A45C for rules, frames and numbers, label card ivory #E8E2D6 with ink #1B1518; gem hues are specific to each specimen (e.g. a deep absinthe green #5FD08A, arterial garnet #A3122B, glacier blue #7FD6F2, uranium yellow #E6E04A, smoky violet #7A5CC2, black with rainbow sheen, milky opal). Layout: one specimen at a time fills a large square "vitrine" (the WebGL canvas) on the left/top; to the right/below sits a typeset museum label; along the bottom a brass-numbered rail of seven small thumbnails (CSS/SVG silhouettes of each crystal habit) for selection, also reachable with arrow keys. Typography: label in a classic museum style: specimen name in large Didot/Bodoni-like serif italics, catalogue number in tracked small caps with brass colour ("Acc. No. 1911.44.7"), properties as a tiny two-column table (Crystal system, Hardness, Lustre, Locality, Habit), and a paragraph of curatorial prose. Invented specimens such as: "Noctilite: found only in wells that have never reflected the moon"; "Verdant Halide of Mourne"; "Chorusite, which rings at 440 Hz when the room is empty"; "Slow Glass"; "Widow's Pyrite"; "Meridian Salt"; "Lacrimite (Tear-stone)": each with consistent, witty, specific data (hardness "6½, 7 on Tuesdays"). Rendering: each specimen is a signed-distance-field crystal: intersections of planes forming hexagonal prisms with pyramid terminations, octahedra, cubic pyrite-like twins, bladed clusters, a botryoidal blob for one; raymarched with: faceted normals, Fresnel reflection of a procedural studio environment, fake refraction/internal absorption (march inside the solid to tint by thickness), dispersion sparkle on edges, soft shadow and ambient occlusion onto a velvet plinth, and a slow lamp orbit so highlights travel across the facets. One uniform set per specimen (shape id, colours, roughness) so switching is cheap. Render at reduced internal resolution if frame time is high (adaptive scale) and cap DPR. Interaction: drag (mouse or touch) to rotate the specimen with inertia (on touch screens the vitrine keeps vertical page scrolling, so a sideways drag turns the specimen); the lamp follows the pointer position when hovering the vitrine; scroll/pinch does nothing (avoid trapping scroll). Selecting another specimen: the signature transition, where the current crystal dissolves into its facets' glints while the glass of the case shows a sweeping reflection, and the next one resolves, as the label text re-sets with a letter-by-letter typeset shimmer in brass. Number keys 1-7 also select a specimen and U toggles the lamp. A small "Lamp" switch toggles between gallery light and "ultraviolet", under which each mineral fluoresces in an unexpected colour (and the label reveals a hidden line of text in fluorescent ink). Entrance: darkness, then the case lamp warms up over 1.5s and the first crystal catches the light. Fallback if WebGL is unavailable: beautifully drawn SVG crystals with gradient facets for each specimen, and the same labels. Reduced motion: lamp static, rotation only on drag, cross-fade transitions. DESCRIPTION A hushed, single-lamp mineral gallery for seven specimens that cannot exist. A brass-framed vitrine holds one real-time raymarched crystal floating above a plum velvet plinth, lit by a lamp that slowly orbits so highlights slide from facet to facet; beside it hangs an ivory museum label set in Didot-style italics with a brass catalogue number, a small property table and a paragraph of deadpan curatorial fiction, and below runs a brass rail of seven numbered crystal-habit silhouettes. The page opens in darkness and the lamp warms up over a second and a half. Changing specimen dissolves the crystal facet by facet into glints while a reflection sweeps across the case glass, then the next mineral resolves as the label re-sets itself letter by letter in glowing brass. Switching the lamp to ultraviolet drops the room into violet, makes every mineral fluoresce in a colour it has no business being, and reveals one extra line on the label written in fluorescent ink. VISUAL TECHNIQUES - WebGL fragment-shader raymarching of signed-distance crystals built from plane intersections: truncated octahedron, hexagonal prism cluster with pyramid terminations, bladed spray, chamfered rhombohedron, interpenetrating cubes, hexagonal dipyramid, and a smooth-union botryoidal mass - Faceted normals, Fresnel reflection of a procedural studio environment (softboxes plus the moving lamp), refraction with an interior march, one internal bounce on total internal reflection, thickness-based absorption and per-channel dispersion - Edge detection from the distance field for bevel light and spectral edge sparkle; thin-film iridescence for the black specimen; milky scattering with play-of-colour for the opal one - Velvet plinth with nap noise, grazing sheen, gem-tinted soft shadows, ambient occlusion and a brass rim; filmic tone mapping, vignette and dither - Facet-hashed dissolve with timed facet flashes and screen-space four-point glints, paired with a CSS glass-reflection sweep - Ultraviolet mode: violet lamp and environment, per-specimen fluorescent emission with internal zoning, fluorescent spill onto the plinth, restyled label with glowing hidden ink - Adaptive internal resolution driven by measured frame time, capped device pixel ratio, rendering paused when hidden or off-screen - Letter-by-letter brass typeset shimmer using staggered CSS keyframes with custom easing; SVG turbulence paper and film grain; CSS brushed-brass frame with screws - One shared set of facet polygons drawn as SVG both for the rail silhouettes and for the gradient-faceted fallback crystals shown when WebGL is unavailable - Reduced-motion variant: static lamp, no idle rotation, cross-fade transitions, no letter animation INTERACTION MODEL Drag inside the vitrine with mouse or finger to turn the specimen; it keeps spinning with inertia and then settles into a slow idle rotation. Moving a mouse over the vitrine makes the lamp follow the pointer so highlights and shadows can be steered; on leaving, the lamp returns to its slow orbit. Scrolling and pinching are left alone. Click or tap one of the seven numbered silhouettes on the brass rail, or use the left and right arrow keys, Home and End, or the number keys 1-7, to change specimen: the crystal dissolves into glints, a reflection crosses the glass, the next crystal resolves and the label re-sets in brass. The Lamp switch (or the U key) toggles between gallery light and ultraviolet, under which each mineral fluoresces in an unexpected colour and a hidden line appears on the label. All controls are focusable buttons with visible focus states.