1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
<!DOCTYPE html> <body> <style> body { display: flex; height: 200px; } #container1 { position: relative; } #container2 { position: absolute; height: 100%; display: flex; } #container3 { display: flex; } </style> <div id="container1"> <div id="container2"> <div id="container3"> <input type="text" placeholder="Username"> </div> </div> </div> </body>