Skip to content

Instantly share code, notes, and snippets.

@LeaVerou
Last active November 22, 2025 15:14
Show Gist options
  • Select an option

  • Save LeaVerou/b9875187aad760afcdae73ab51edf151 to your computer and use it in GitHub Desktop.

Select an option

Save LeaVerou/b9875187aad760afcdae73ab51edf151 to your computer and use it in GitHub Desktop.
Stiched effect
/**
* Stiched effect
*/
.tag {
--background: hsl(220 20 90);
--stitch-light: #0008;
--stitch-shadow: white;
--border-color: hsl(220 20 30);
display: inline-block;
border: 1.5px dashed white;
border-color: var(--stitch-shadow);
border-right-color: var(--stitch-light);
border-bottom-color: var(--stitch-light);
background: var(--background);
box-shadow: 0 0 0 .3em var(--background), 0 0 0 calc(.3em + 1px) var(--border-color);
border-radius: .2em;
> div {
padding: .35em .5em;
border: inherit;
border-color: var(--stitch-light);
border-right-color: var(--stitch-shadow);
border-bottom-color: var(--stitch-shadow);
border-radius: .2em;
}
}
body {
font: 200% / 1 system-ui;
padding: 3em;
}
<div class="tag"><div>Stiched</div></div>
// alert('Hello world!');
{"view":"split","fontsize":"100","seethrough":"","prefixfree":"1","page":"css"}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment