30 CSS Ribbons
This CSS Ribbons collection is your resource for creating stylish, geometrically complex, and dynamic decorative elements without using images. We demonstrate how to use CSS clip-path and pseudo-elements to cut out precise angles and “tails”, and how to achieve the folded ribbon effect. The key technical focus is on 3D transforms for creating realistic bookmarks and utilizing CSS Grid for complex layouts. Master these Pure CSS techniques to build responsive, animated, and easily customizable ribbons (including corner ribbons), ensuring visually impactful content highlighting.
Last updated:
Product Plan Cards with CSS Ribbons
A pure CSS pricing component that creates a dimensional ‘ribbon’ aesthetic solely through ::after pseudo-elements and clip-path geometry. The layout leverages CSS Custom Properties for distinct color themes and calc with negative margins to extend elements beyond the parent container, creating a folded paper effect without any JavaScript dependencies.
CSS Bookmark
A state-driven animation, controlled via the “checkbox hack,” showcases the power of CSS @property (Houdini) for smoothly animating gradients and mask properties. A complex multi-layered bookmark shape is created with an SVG mask, while the entire activation effect choreography is built on synchronized @keyframes.
CSS-only Corner Ribbons for GitHub Links
Generation of corner ribbons, where both Pug and SCSS use @each loops to automatically create the markup and styles for all four corners. The element’s positioning and transform are calculated from a single SCSS variable, making the component scalable and DRY.
Ribbon Design
A layered ribbon effect created by stacking two pseudo-elements, ::before and ::after. Each is slightly rotated using transform: rotate() and clipped by the parent’s overflow: hidden to create “torn” edges.