<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Dynamic Content Loading</title>
    <style>
        body {
            font-family: Arial, sans-serif;
            margin: 0;
            padding: 0;
            box-sizing: border-box;
            background-color: #f0f2f5;
            display: flex;
            justify-content: center;
            align-items: center;
            height: 100vh;
        }
        .content {
            max-width: 600px;
            width: 100%;
            background-color: white;
            padding: 20px;
            border-radius: 8px;
            box-shadow: 0 2px 5px rgba(0,0,0,0.1);
        }
        button {
            padding: 10px 20px;
            border: none;
            border-radius: 5px;
            background-color: #007bff;
            color: white;
            font-size: 1em;
            cursor: pointer;
        }
        button:hover {
            background-color: #0056b3;
        }
        .loader {
            display: none;
            text-align: center;
        }
    </style>
</head>
<body>
    <div class="content">
        <h1>Dynamic Content Loading</h1>
        <button onclick="loadContent()">Load Content</button>
        <div class="loader">Loading...</div>
        <div id="dynamicContent"></div>
    </div>

    <script>
        function loadContent() {
            const loader = document.querySelector('.loader');
            const contentDiv = document.getElementById('dynamicContent');
            
            loader.style.display = 'block';
            contentDiv.innerHTML = '';
            
            setTimeout(() => {
                contentDiv.innerHTML = '<p>This is the dynamically loaded content.</p>';
                loader.style.display = 'none';
            }, 2000); // Simulate a network delay
        }
    </script>
</body>
</html>