跪拜 Guibai
← All articles
Frontend · Visual Design · CSS

From One Hex to One Prompt: 23 CSS Design Styles, Priced by Their Cost Ladder

By iDao技术魔方 ·
Read original on juejin.cn ↗ Google Translate ↗ Alt translation

Teams shipping CSS can use the cost ladder to decide quickly whether a new style will survive production: if it cannot be reproduced cheaply and cannot degrade gracefully, it will break real users. The contrast and fallback failures here are measurable, not matters of taste.

Summary

Twenty-three design styles, spanning skeuomorphism in 2007 to speculative generative interfaces in 2028, are reproduced in runnable CSS, with each style's cost structure and fallback behavior laid out next to the code. The cost ladder is blunt: skeuomorphism needs a shadow stack per material, flat design needs one hex, glassmorphism needs one line of backdrop-filter, and AI-generated UI needs one prompt. The unit cost of texture only falls, so the reason to adopt a style is whether its cost structure can keep collapsing, not whether it looks good at the moment.

The production guidance separates styles that can ship from styles that belong in portfolios. Glassmorphism earns its place because an @supports fallback turns it into a translucent solid on old browsers. Neumorphism fails because its measured 1.2:1–1.5:1 contrast misses the WCAG 2.2 AA 3:1 floor for UI components. Liquid glass is only an approximation on the web: Apple's version uses GPU compositing and ambient-light sensing, and Apple's own guidance keeps it off data-dense content. The anti-AI pattern is treated as a build failure: design tokens and CI linting block the purple-gradient, oversized-shadow, predictable-font defaults.

A selection matrix routes B2B backends to flat, Material, or dark; overlay navigation to glass with a fallback; marketing heroes to big type, aurora mesh, or bento grids; portfolios to neubrutalism, acid, or CRT; and explanatory content to 2.5D isometric or bento layouts. Two speculative styles, ambient and generative UI, get CSS sketches as well, with the generative case scoped to client-side rendering of agent-produced layout messages.

Takeaways
— Skeuomorphism costs one layer/shadow stack per material; flat design costs one hex; glassmorphism costs one backdrop-filter line; AI-generated UI costs one prompt.
— Neumorphic elements measured 1.2:1–1.5:1 contrast against their background, below the 3:1 WCAG 2.2 AA requirement for UI components.
— Glassmorphism is production-safe because an @supports not (backdrop-filter) rule degrades it to a translucent solid background.
— Liquid glass on the web is an approximation; Apple's system version uses GPU compositing and real-time ambient-light adaptation that CSS cannot match.
— Apple's guidance discourages liquid glass on data screens such as tables and forms; navigation and overlays are the acceptable surfaces.
— Ryo Lu at Cursor names purple gradients, exaggerated shadows, and predictable fonts as AI-generated UI clichés; Wes Bos calls them the four horsemen.
— The anti-AI fix writes brand color and radius into design tokens and uses CI pattern linting to fail the build on default-looking values.
— Any translucent effect needs a fallback first, via @supports or prefers-reduced-transparency.
— A pre-launch contrast test should enforce 3:1 for UI components.
— In the cited user-exit data, 38% of users leave because a site looks bad and 39% because it is slow; slow kills slightly faster than ugly.
Conclusions

Survival tracks fallback coverage more than visual appeal. Glassmorphism had one @supports line; neumorphism had no way around a 1.2:1 contrast ratio.

The anti-AI-slop fix turns taste into a CI failure. Naming the clichés matters less than the mechanism: if default-looking gradients and radii can fail a build, the design decision is enforced instead of debated.

Those abandonment numbers put the slow-kills-faster-than-ugly claim on a one-point margin. The practical reading is not that performance matters more, but that ugliness and slowness are near-equal reasons to lose users, so neither can be ignored.

The 2027–2028 predictions are speculative, but they share a direction: interface chrome shrinks, and CSS's job shifts from composing visible surfaces to constraining agent-generated output. The container-query sketch proves only that the rendering primitives exist, not that the interaction model will arrive.

Concepts & terms
backdrop-filter
CSS property that applies blur, saturation, brightness, or other filters to the pixels behind an element; the basis of glassmorphism and web approximations of liquid glass.
@supports
CSS feature query that applies a style block only when the browser supports a property; the fallback mechanism that lets glass effects degrade to solid backgrounds.
prefers-reduced-transparency
CSS media query matching users who request less transparency at the OS level; the liquid-glass example uses it to disable blur and switch to an opaque background.
WCAG 2.2 AA 3:1 contrast
Accessibility requirement that UI components maintain at least a 3:1 contrast ratio against adjacent colors; neumorphism's measured 1.2:1–1.5:1 fails it.
Design tokens
Named variables for colors, radii, spacing, and other design decisions; the anti-AI pattern writes a real brand color and restrained radius into tokens so defaults cannot slip in.
Container queries
CSS @container rules that let components respond to the width of their container instead of the viewport; used in the generative-UI sketch to adapt agent-produced cards.
A2UI
A proposed pattern in which an AI agent emits structured layout messages and the client renders them; agent code is never executed, which keeps the agent from running arbitrary scripts.
Frutiger Aero
A glossy, water-themed, optimistic aesthetic from mid-2000s interfaces; its 2024–2026 revival is reproduced as a CSS orb with radial highlights and blue gradients.
Source: juejin.cn ↗ Google Translate ↗ Backup ↗