Keep the idea.
Refine the surface.
Clear text, a translucent fill, and a backdrop you can inspect.
02 / ACCESSIBILITY
Explore text contrast on a known, uniform backdrop. Change the tint opacity and text color, then compare the opaque fallback.
INTERACTIVE EXAMPLE
Material controls affect only this example. They do not replace your saved studio session.
Clear text, a translucent fill, and a backdrop you can inspect.
Change a control to inspect the example.
.glass {
color: #ffffff;
background: #12121a;
border: 1px solid rgba(255, 255, 255, 0.25);
border-radius: 24px;
box-shadow: 0 14px 40px rgba(0, 0, 0, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.12);
}
@supports ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
.glass {
background: rgba(18, 18, 26, 0.16);
-webkit-backdrop-filter: blur(18px) saturate(140%);
backdrop-filter: blur(18px) saturate(140%);
}
}
@media (prefers-reduced-transparency: reduce) {
.glass {
background: #12121a;
-webkit-backdrop-filter: none;
backdrop-filter: none;
}
}Complete class strings for your compiler. This preview uses the equivalent CSS material, not a Tailwind runtime.
<!-- Paste the complete classes into a template scanned by Tailwind. -->
<div class="
[background:#12121a] [color:#ffffff]
[border:1px_solid_rgba(255,_255,_255,_0.25)]
[border-radius:24px]
[box-shadow:0_14px_40px_rgba(0,_0,_0,_0.2),_inset_0_1px_0_rgba(255,_255,_255,_0.12)]
supports-[backdrop-filter:blur(1px)]:[background:rgba(18,_18,_26,_0.16)]
supports-[-webkit-backdrop-filter:blur(1px)]:[background:rgba(18,_18,_26,_0.16)]
[backdrop-filter:blur(18px)_saturate(140%)]
[-webkit-backdrop-filter:blur(18px)_saturate(140%)]
[@media(prefers-reduced-transparency:reduce)]:[background:#12121a]
[@media(prefers-reduced-transparency:reduce)]:[backdrop-filter:none]
[@media(prefers-reduced-transparency:reduce)]:[-webkit-backdrop-filter:none]
">
<!-- Your content -->
</div>White text on a transparent card does not have one universal contrast ratio. The surface mixes with the backdrop, so a background change can alter readability without any change to the text. This example uses a uniform backdrop to make that relationship inspectable.
For normal text, WCAG’s AA reference threshold is 4.5:1. Large text uses 3:1; that means at least 24 CSS pixels, or about 18.67 CSS pixels when bold. Do not classify a small label as large text just because it is uppercase or has wide letter spacing.
The estimate uses saturation and alpha composition in sRGB, followed by relative luminance. It compares your text color with a uniform surface color. It does not sample rendered pixels or account for text antialiasing, photographs, focus indicators, or neighboring controls. A passing pair does not certify the entire component.
The example and exported CSS respect the system preference for reduced transparency when the browser exposes it. The opaque background remains part of the material rather than an afterthought. Test that color deliberately: a fallback that hides the page but makes the text unreadable has not solved the problem.
Transparency is also only one accessibility concern. Keyboard focus must remain visible, controls need names, and interactive overlays need appropriate focus management. The studio’s Modal preview illustrates a surface; it does not implement the behavior of an accessible dialog.
Use a plain backdrop to establish a baseline, then test the actual component over the lightest and darkest relevant areas. Include hover, focus, disabled, and error states. If the backdrop cannot be controlled, a stronger fill or a solid text region may be a better design decision.