Unlock the power of CSS
Hide Code
Show Code
.gradient-heading { background: linear-gradient(45deg, var(--colora) 0%, var(--colora2) 100%); background-clip: text; color: transparent; }
.gradient-border { background: linear-gradient(var(--colorbody), (--colorbody)) padding-box, linear-gradient(0deg, var(--colora) 0%, (--colora2)100%) border-box; border: solid 1px transparent; }
/* parent card */ .polite-card {max-width: 400px; display: flex; flex-direction: column; background: var(--colors); border-radius: 8px; overflow: hidden;} /* text & button */ .css-card {padding: 20px;}
My face when someone expects me to be excited about something that I'm not excited about.
Learn moreCheck the full code on Codepen 👇
16
pixels
Smartphones
18
pixels
Laptops
20
pixels
Desktops
24
pixels
4K screens
.element:hover{scale: 1.05;}
.element:hover{transform: translateY(-4px);}
button:hover {background: linear-gradient(45deg, var(--col0%, var(--colora2) 100%) border-box;}
svg:hover {fill: var(--colora);}
h1 {color: transparent; -webkit-text-stroke-color: var(--colora); -webkit-text-stroke-width: 1px;} h1:hover{color: var(--colora);}
Fill
p{font-size: 5vw;}
Resize your Window
p{font-size: clamp(36px, 5vw, 72px);}
More Control
div{display: flex; gap: 20px;} div:nth-child(1){flex: 1;} div:nth-child(2){flex: 2;} div:nth-child(3){flex: 3;}
L
XL
XXL
parent{scroll-snap-type: y mandatory;} children{scroll-snap-align: start;}
li{list-style: "😎 ";} li:nth-child(2){list-style: "🍞 ";} li:nth-child(3){list-style: "👖 ";}
Good Habits
.moody{ /* same code, just add bg and adjust values */}
.dashing{/* Animation */ background: linear-gradient(270deg, var(--colora), var(--colora2), var(--colora)); background-size: 300% 300%; animation: bg 10s ease-ininfinite; @keyframes bg { 0% {background-position: 0% 50%;} 50% {background-position: 100% 100%;} 100% {background-position: 0% 50%;}}
.crispy{ /* same code, just adjust values */}
@keyframes bounce {0%, 20%, 50%, 80%, 100% {transform: translateY(0);} 40% {transform: translateY(-30px);} 60% {transform: translateY(-15px);}}
Look at me
@keyframes pulse {0%, 100% {transform: scale(1);}50% {transform: scale(1.2);}}
@keyframes flip {0%{transform: rotateY(0);}100% {transform: rotateY(360deg);}}
@keyframes rotate {0%{transform: rotate(0deg);}100% {transform: rotate(360deg);}}
box-shadow: 0px 4px 4px #00000030, 0px 12px 12px #00000015;
Combine two shadows to create a more natural and true sense of depth.
The first shadow is darker and closer to the card.
The second shadow is larger and softer.
Shadows don't work in dark mode, just as in real life
Coming soon
I will continue to add more features to the list. Please keep an eye out for them.
PS. Feel free to send me CSS features to add to this list.
You don't have to waste your time on Dribble, Behance or Instagram.
There is a much easier & better way to get design/UI inspirations.
I use Mobbin, for two reasons:
1. Proven real-world designs
2. Quick and easy to find exactly what I need