body { display: flex; justify-content: center; /* tengah horizontal */ align-items: center; /* tengah vertikal */ height: 100vh; margin: 0; } h1 { position: absolute; top: 20px; } .card { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); body { font-family: Arial; background: #f4f4f4; display: flex; justify-content: center; align-items: center; height: 100vh; } .container { background: white; padding: 30px; border-radius: 5px; text-align: center; box-shadow: 0 0 10px rgba(0,0,0,0.1); } input { padding: 10px; width: 150px; margin: 10px; } button { padding: 10px 10px; background: blue; color: white; border: none; cursor: pointer; } }