export default async function main(): Promise<Response> {
const htmlContent = `
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Hello World</title>
<style>
@import url('https://fonts.googleapis.com/css2?family=Press+Start+2P&family=Pacifico&display=swap');
body {
font-family: 'Press Start 2P', cursive;
background: linear-gradient(135deg, #FF4081 0%, #81D4FA 100%);
display: flex;
align-items: center;
justify-content: center;
height: 100vh;
margin: 0;
animation: gradientAnimation 15s ease infinite;
}
h1 {
font-family: 'Pacifico', cursive;
color: white;
text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
animation: textAnimation 5s infinite;
}
@keyframes gradientAnimation {
0% { background-position: 0% 50%; }
50% { background-position: 100% 50%; }
100% { background-position: 0% 50%; }
}
@keyframes textAnimation {
0%, 100% { transform: scale(1); }
50% { transform: scale(1.2); }
}
</style>
</head>
<body>
<h1>Hello, world!</h1>
</body>
</html>
`;
return new Response(htmlContent, {
headers: {
"Content-Type": "text/html",
},
});
}