Toggle navigation
☰
HTML
CSS
Scripting
Database
<!doctype html> <title>Tailwind CSS States Example</title> <script src="https://cdn.tailwindcss.com"></script> <body class="bg-gray-100 p-8 flex flex-col items-center space-y-8"> <button class="bg-blue-500 hover:bg-blue-700 active:bg-blue-900 focus:outline-none focus:ring-4 focus:ring-blue-300 text-white font-bold py-2 px-4 rounded transition-all"> Hover, Active & Focus </button> <div class="group block max-w-xs mx-auto rounded-lg p-6 bg-white ring-1 ring-slate-900/5 shadow-lg space-y-3 hover:bg-sky-500 hover:ring-sky-500 transition-colors"> <div class="flex items-center space-x-3"> <svg class="h-6 w-6 stroke-sky-500 group-hover:stroke-white transition-colors" fill="none" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"> <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M12 4v16m8-8H4"></path> </svg> <h3 class="text-slate-900 group-hover:text-white text-sm font-semibold transition-colors">New project</h3> </div> <p class="text-slate-500 group-hover:text-white text-sm transition-colors">Create a new project from a variety of starting templates.</p> </div> </body>