<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/micro-interactions-still-matter-estpgvelq" -->

---
title: Micro-interactions still matter | daily.dev
description: A short CSS tutorial demonstrating how to create polished micro-interactions using just four lines of CSS. The technique combines hover background color...
canonical: https://daily.dev/posts/micro-interactions-still-matter-estpgvelq
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: Micro-interactions still matter | daily.dev
og:description: A short CSS tutorial demonstrating how to create polished micro-interactions using just four lines of CSS. The technique combines hover background color...
og:url: https://daily.dev/posts/micro-interactions-still-matter-estpgvelq
og:image: https://api.daily.dev/og/posts/EStpgVeLq.png
og:image:alt: Micro-interactions still matter
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Micro-interactions still matter

**[Coding in Public](https://daily.dev/sources/codinginpublic)** · 4 min read · 2 upvotes · 0 comments

## Summary

A short CSS tutorial demonstrating how to create polished micro-interactions using just four lines of CSS. The technique combines hover background color changes using OKLCH color with opacity, a box shadow for visual depth, a scale transform on active/click state, and a custom linear easing function for a 'squishy' feel. The box shadow approach is preferred over background-with-padding because it doesn't disrupt document flow, allowing the squish animation to work smoothly. CSS nesting, modern scale property, and easing generators like Easing Wizard are used throughout.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://www.youtube.com/watch?v=HrSnHMaWpGA>

## Similar posts on daily.dev

- [Elastic/Bouncy Hover Effect](https://daily.dev/posts/elastic-bouncy-hover-effect-0se5rz4ih) · CSS Tip · 47 upvotes · 2 comments
- [A Squishy Button with a Hover/Click Effect](https://daily.dev/posts/a-squishy-button-with-a-hover-click-effect-3rgo6369d) · CSS Tip · 44 upvotes · 3 comments
- [Hover Proximity Using Modern CSS – Master.dev Blog](https://daily.dev/posts/hover-proximity-using-modern-css-master-dev-blog-wa5xjv85b) · Frontend Masters · 18 upvotes · 1 comments

---

Tags: [#webdev](https://daily.dev/tags/webdev), [#css](https://daily.dev/tags/css)

[View this post on daily.dev](https://daily.dev/posts/micro-interactions-still-matter-estpgvelq)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"Micro-interactions still matter","url":"https://daily.dev/posts/micro-interactions-still-matter-estpgvelq","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/micro-interactions-still-matter-estpgvelq"},"datePublished":"2026-02-24T13:32:31.360Z","dateModified":"2026-02-24T13:32:48.374Z","description":"A short CSS tutorial demonstrating how to create polished micro-interactions using just four lines of CSS. The technique combines hover background color...","image":"https://i.ytimg.com/vi/HrSnHMaWpGA/sddefault.jpg","thumbnailUrl":"https://i.ytimg.com/vi/HrSnHMaWpGA/sddefault.jpg","isAccessibleForFree":true,"articleSection":"Coding in Public","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"Coding in Public","logo":"https://media.daily.dev/image/upload/s--9JGHAZLp--/f_auto/v1723789179/logos/codinginpublic","url":"https://daily.dev/sources/codinginpublic"},"commentCount":0,"discussionUrl":"https://daily.dev/posts/micro-interactions-still-matter-estpgvelq","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":2},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"keywords":"webdev,css","timeRequired":"PT4M","video":{"@type":"VideoObject","name":"Micro-interactions still matter","description":"A short CSS tutorial demonstrating how to create polished micro-interactions using just four lines of CSS. The technique combines hover background color...","thumbnailUrl":"https://i.ytimg.com/vi/HrSnHMaWpGA/sddefault.jpg","uploadDate":"2026-02-24T13:32:31.360Z","duration":"PT4M","url":"https://api.daily.dev/r/EStpgVeLq","embedUrl":"https://www.youtube.com/embed/HrSnHMaWpGA"}}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"Coding in Public","item":"https://daily.dev/sources/codinginpublic"},{"@type":"ListItem","position":3,"name":"Micro-interactions still matter"}]}
```

