Position & Z-Index — Tailwind CSS

Position: static, relative, absolute, fixed, sticky Inset (top/right/bottom/left): top-0, right-4, bottom-0, left-0, inset-0 (semua sisi) Z-Index: z-0, z-10, z-

Position: static, relative, absolute, fixed, sticky

Inset (top/right/bottom/left): top-0, right-4, bottom-0, left-0, inset-0 (semua sisi)

Z-Index: z-0, z-10, z-20, z-30, z-40, z-50, z-auto

<!-- Overlay pattern -->
<div class="relative">
  <img src="photo.jpg" class="w-full">
  <div class="absolute inset-0 bg-black/50 flex items-center justify-center">
    <p class="text-white text-2xl">Overlay</p>
  </div>
</div>

<!-- Sticky header -->
<header class="sticky top-0 z-50 bg-white shadow">
  Navbar
</header>

Yang akan kamu pelajari