Retro Stylish Alert - MeggiTools
Run
Toggle Theme
Share Link
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Retro Stylish Alert</title> <style> body { font-family: 'Courier New', monospace; background-color: #ffeb3b; display: flex; justify-content: center; align-items: center; height: 100vh; } .alert-container { position: fixed; top: 0; left: 0; width: 100%; height: 100%; display: flex; justify-content: center; align-items: center; backdrop-filter: blur(5px); -webkit-backdrop-filter: blur(5px); z-index: 9999; opacity: 0; visibility: hidden; transition: opacity 0.5s, visibility 0.5s; } .alert { background-color: #ff5722; border-radius: 10px; padding: 20px; box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3); text-align: center; animation: slideDown 0.5s ease-out; } @keyframes slideDown { from { transform: translateY(-50px); opacity: 0; } to { transform: translateY(0); opacity: 1; } } .alert-header { display: flex; justify-content: center; align-items: center; font-size: 24px; font-weight: bold; margin-bottom: 15px; color: white; } .alert-header .icon { margin-right: 10px; } .alert-body { font-size: 18px; margin-bottom: 20px; color: white; } .alert-footer { display: flex; justify-content: center; } .alert-footer button { background-color: #ffffff; color: #ff5722; border: none; padding: 10px 20px; border-radius: 5px; cursor: pointer; font-size: 16px; transition: background-color 0.3s; } .alert-footer button:hover { background-color: #ff7043; color: #ffffff; } .show-alert { opacity: 1; visibility: visible; } .show-alert2 { width: auto; height: 50px; background:#ff7043; border: none; outline: none; color: #fff; border-radius: 5px; padding-left: 3%; padding-right: 3%; opacity: 1; visibility: visible; cursor: pointer; font-size: 1.2em; } </style> </head> <body> <div class="alert-container" id="alertContainer"> <div class="alert"> <div class="alert-header"> <span class="icon">💾</span> <span>Retro Alert</span> </div> <div class="alert-body"> This is a retro-style alert with slide-down animation. </div> <div class="alert-footer"> <button type="button" onclick="closeAlert()">Close</button> </div> </div> </div> <button type="button" onclick="showAlert()" class="show-alert2">Show Retro Alert</button> <script> function showAlert() { document.getElementById('alertContainer').classList.add('show-alert'); } function closeAlert() { document.getElementById('alertContainer').classList.remove('show-alert'); } </script> </body> </html>