What each control writes
Background colour starts as the word "gradient", looked up in a table of six named two-stop gradients: gradient, sunset, ocean, forest, dark and peach. Any other text there is used as raw CSS and also emitted as the body rule at the end. Tint defaults to rgba(255, 255, 255, 0.25), Border to rgba(255, 255, 255, 0.35), Text colour to #ffffff, Padding to 24px 32px and Shadow to 0 8px 32px rgba(0, 0, 0, 0.18). Four sliders follow: Blur 0 to 40 at 14, Opacity 5 to 90 at 25, Radius 0 to 48 at 16 and Saturation 100 to 250 at 140.
A worked example
Untouched, the box holds a base .glass rule whose background is the fallback tint rgba(255, 255, 255, 0.6), then an @supports block that restores rgba(255, 255, 255, 0.25) and adds backdrop-filter: blur(14px) saturate(140%) prefixed and plain, then body { background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); }. The radius appears twice at 16px, and the border becomes 1px solid rgba(255, 255, 255, 0.35). Drag Blur to 0 and blur(0px) is still written; move Opacity to 80 and both background values follow it, with the fallback held 0.35 above the selected alpha.
The fallback checkbox
Ticked, the first .glass rule uses a more opaque version of the Tint alpha (selected alpha plus 0.35, capped at 1) and carries no filter, so a browser without backdrop-filter paints a solid-looking panel. The @supports block then restores the selected alpha and adds the prefixed and unprefixed backdrop-filter. Unticking the box removes the fallback background and the @supports wrapper, leaving one rule with the selected tint and the filters.
Where it stops
- The
@supportstest checks for backdrop-filter support in general, not for specific values, so a browser that parses the property but ignoressaturate()still takes the translucent path. - Text boxes are copied verbatim, so a malformed colour reaches the stylesheet and the browser drops the declaration.
- Translucency comes from the Opacity slider multiplying the alpha typed in Tint; a Tint value without an alpha channel is used unchanged.
- The preview is one fixed card reading Glass and Frosted panel on a 256px stage, with no real text or images.
Questions people ask
Why can I not see the frost
backdrop-filter blurs what sits behind the element, so a flat page colour gives it nothing; the stage carries a gradient for that reason.
What alpha reads as glass
The default 0.25 is the starting point, and past roughly 0.6 the panel reads as an opaque card.
Does it hold up under text
Check the pair in the contrast checker, and build a deeper value for the Shadow box with the shadow generator.