Untitled
unknown
plain_text
a year ago
1.8 kB
21
Indexable
<!DOCTYPE html>
<html lang="pt">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Gerador de Inspiração</title>
<style>
body {
margin: 0;
font-family: Arial, sans-serif;
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
background: linear-gradient(135deg, #4facfe, #00f2fe);
color: #fff;
text-align: center;
}
.container {
background: rgba(0,0,0,0.4);
padding: 40px;
border-radius: 15px;
max-width: 500px;
box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}
h1 {
margin-bottom: 20px;
font-size: 28px;
}
#quote {
font-size: 20px;
margin: 20px 0;
font-style: italic;
}
button {
background: #ff9800;
border: none;
color: white;
padding: 10px 20px;
font-size: 16px;
border-radius: 8px;
cursor: pointer;
transition: background 0.3s;
}
button:hover {
background: #e68900;
}
</style>
</head>
<body>
<div class="container">
<h1>✨ Inspiração do Dia ✨</h1>
<p id="quote">Clique no botão para gerar uma frase!</p>
<button onclick="newQuote()">Nova Frase</button>
</div>
<script>
const frases = [
"O sucesso nasce da perseverança.",
"Nunca desistas dos teus sonhos.",
"A disciplina é o caminho da liberdade.",
"Cada dia é uma nova oportunidade.",
"Acredita em ti e tudo será possível.",
"Grandes coisas levam tempo."
];
function newQuote() {
const aleatorio = Math.floor(Math.random() * frases.length);
document.getElementById("quote").textContent = frases[aleatorio];
}
</script>
</body>
</html>
Editor is loading...
Leave a Comment