Skip to content

Duotone Shift

A copy-paste animated gradients component in pure HTML & CSS. Zero dependencies, framework-agnostic, MIT-licensed.

Animated GradientsHTMLCSSany framework

Copy into your project

HTML
<!-- Duotone Shift -->
<div class="nuda-gradient-duotone" role="img" aria-label="Shifting duotone tile"></div>
CSS
.nuda-gradient-duotone {
  width: 140px;
  height: 140px;
  border-radius: 14px;
  background: linear-gradient(135deg,#09090b 0%,#e4ff54 100%);
  background-size: 100% 100%;
  animation: nuda-gradient-duotone-shift 5s ease-in-out infinite alternate;
}

@keyframes nuda-gradient-duotone-shift {
  0% {
    filter: hue-rotate(0deg) contrast(1);
  }
  100% {
    filter: hue-rotate(160deg) contrast(1.3);
  }
}

@media (prefers-reduced-motion:reduce) {
  .nuda-gradient-duotone {
    animation: none;
  }
}

How to use Duotone Shift

Paste the HTML where you need it and the CSS into a global stylesheet (or a <style> tag). Every class is prefixed nuda- so it never collides with Tailwind or your own styles. Tweak the CSS custom properties to match your design system.

Works in React, Vue, Svelte, Astro, Next.js, Nuxt, Laravel Blade, Django, Rails — or a single .html file. No npm install, no build step.

More animated gradients components

← Browse all NudaUI components