Show Output
<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <title>Example of CSS min-height property</title> <style> p { min-height: 100px; background: #f0e68c; } div { height: 200px; min-height: 300px; background: #ffc0cb; } </style> </head> <body> <p>Enter some more line of text to see how it works.</p> <div>The minimum height of this div element is set to 300px, so it can't be smaller than that.</div> </body> </html>