generate a modern website, full stack website using html, css and js putted inton one…
- User
generate a modern website, full stack website using html, css and js putted inton one single file. be random and choose any topic!
Assistant
Here's a fun, modern "Random Tech Quote Generator" website in a single HTML file using HTML, CSS, and JavaScript. It includes animations, dynamic color changes, and a responsive design:
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Random Tech Quote Generator</title> <style> * { margin: 0; padding: 0; box-sizing: border-box; } body { min-height: 100vh; display: flex; justify-content: center; align-items: center; font-family: 'Arial', sans-serif; transition: background-color 0.5s; background: linear-gradient(135deg, #2a1c5c, #0e3d6d); } .container { background: rgba(255,255,255,0.1); padding: 40px; border-radius: 20px; backdrop-filter: blur(15px); max-width: 600px; text-align: center; box-shadow: 0 8px 32px rgba(0,0,0,0.3); transition: all 0.3s ease; } .quote-text { font-size: 2rem; color: #f8f8ff; line-height: 1.5; margin-bottom: 20px; } .author { font-style: italic; opacity: 0.8; margin-bottom: 30px; } button { background: #4CAF50; color: white; padding: 12px 24px; border: none; border-radius: 24px; font-size: 1rem; cursor: pointer; transition: all 0.3s ease; box-shadow: 0 4px 6px rgba(0,0,0,0.1); } button:hover { transform: translateY(-2px); box-shadow: 0 6px 10px rgba(0,0,0,0.2); } @media (max-width: 768px) { .container { padding: 30px; } .quote-text { font-size: 1.5rem; } } </style> </head> <body> <div class="container"> <div class="quote-text" id="quote"></div> <div class="author" id="author"></div> <button onclick="generateQuote()">Generate Tech Quote</button> </div> <script> const quotes = [ { quote: "Code is like humor. When you have to explain it, it’s bad.", author: "Martin Fowler" }, { quote: "The best way to predict the future is to implement it.", author: "Alan Kay" }, { quote: "First, solve the problem. Then, write the code.", author: "John Johnson" }, { quote: "Programming isn’t about what you know, but what you can figure out.", author: "Chris Pine" }, { quote: "Experience is the name everyone gives to their mistakes.", author: "Oscar Wilde (for programmers)" } ]; function getRandomColor() { return `#${Math.floor(Math.random()*16777215).toString(16)}`; } function generateQuote() { const randomIndex = Math.floor(Math.random() * quotes.length); const { quote, author } = quotes[randomIndex]; document.body.style.backgroundColor = getRandomColor(); document.getElementById('quote').textContent = `"${quote}"`; document.getElementById('author').textContent = `- ${author}`; } // Initialize with first quote generateQuote(); </script> </body> </html>This code creates a modern quote generator with:
- Smooth animations and transitions
- Dynamic background color changes
- Responsive design for all devices
- Stylish blur effect on the container
- Random quotes about programming
- Professional color scheme and typography
- Hover effects on the button
- Automatic initialization on page load
To use:
- Save the code as an .html file
- Open in any modern browser
- Click the button to generate new quotes
- The background color and quote will change each time
The design features:
- Dark mode gradient background
- Blur effect container
- Subtle shadows and transitions
- Responsive layout
- Clean typography
- Random color scheme changes
- Interactive button with hover effect
You can easily modify the quotes array to add your own quotes or change the design elements in the CSS.
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.