transparetn / index.html
steven1015's picture
Add 3 files
31ba512 verified
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>TRANSPARENT MICROINTERACTION MADNESS</title>
<script src="https://cdn.tailwindcss.com"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
<style>
@keyframes float {
0%, 100% { transform: translateY(0); }
50% { transform: translateY(-10px); }
}
@keyframes pulse-glow {
0%, 100% { box-shadow: 0 0 10px rgba(255, 255, 255, 0.3); }
50% { box-shadow: 0 0 20px rgba(255, 255, 255, 0.5); }
}
@keyframes spin {
0% { transform: rotate(0deg); }
100% { transform: rotate(360deg); }
}
@keyframes shake {
0%, 100% { transform: translateX(0); }
25% { transform: translateX(-5px); }
75% { transform: translateX(5px); }
}
@keyframes color-rotate {
0% { filter: hue-rotate(0deg); }
100% { filter: hue-rotate(360deg); }
}
/* Ultra transparent glass effects */
.aero-glass {
background: rgba(255, 255, 255, 0.08);
backdrop-filter: blur(16px) saturate(180%);
-webkit-backdrop-filter: blur(16px) saturate(180%);
border: 1px solid rgba(255, 255, 255, 0.1);
box-shadow: 0 4px 16px 0 rgba(31, 38, 135, 0.15);
}
.aero-glass-dark {
background: rgba(0, 0, 0, 0.08);
backdrop-filter: blur(16px) saturate(180%);
-webkit-backdrop-filter: blur(16px) saturate(180%);
border: 1px solid rgba(255, 255, 255, 0.1);
}
.aero-glass-purple {
background: rgba(139, 92, 246, 0.1);
backdrop-filter: blur(16px) saturate(180%);
-webkit-backdrop-filter: blur(16px) saturate(180%);
border: 1px solid rgba(255, 255, 255, 0.1);
}
/* Ultra transparent gradient background */
.gradient-bg {
background: linear-gradient(135deg, rgba(110, 142, 251, 0.15) 0%, rgba(167, 119, 227, 0.15) 50%, rgba(247, 168, 184, 0.15) 100%);
background-size: 200% 200%;
animation: gradient 15s ease infinite;
}
@keyframes gradient {
0% { background-position: 0% 50%; }
50% { background-position: 100% 50%; }
100% { background-position: 0% 50%; }
}
/* Subtle hover effects */
.micro-hover:hover {
transform: scale(1.03) rotate(0.5deg);
transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
backdrop-filter: blur(12px) saturate(200%);
background: rgba(255, 255, 255, 0.12);
}
.micro-active:active {
transform: scale(0.97);
transition: all 0.1s cubic-bezier(0.25, 0.8, 0.25, 1);
background: rgba(255, 255, 255, 0.15);
}
.micro-focus:focus {
outline: none;
box-shadow: 0 0 0 2px rgba(139, 92, 246, 0.3);
animation: pulse-glow 2s infinite;
backdrop-filter: blur(12px) saturate(200%);
}
.float-animation {
animation: float 6s ease-in-out infinite;
}
.spin-on-hover:hover {
animation: spin 2s linear infinite;
}
.shake-on-click:active {
animation: shake 0.3s cubic-bezier(.36,.07,.19,.97) both;
}
.color-rotate {
animation: color-rotate 10s linear infinite;
}
/* Ultra subtle ripple effect */
.ripple {
position: relative;
overflow: hidden;
}
.ripple:after {
content: "";
display: block;
position: absolute;
width: 100%;
height: 100%;
top: 0;
left: 0;
pointer-events: none;
background-image: radial-gradient(circle, rgba(255,255,255,0.3) 10%, transparent 10.01%);
background-repeat: no-repeat;
background-position: 50%;
transform: scale(10, 10);
opacity: 0;
transition: transform .5s, opacity 1s;
}
.ripple:active:after {
transform: scale(0, 0);
opacity: 0.2;
transition: 0s;
}
/* Very subtle text glow */
.text-glow {
text-shadow: 0 0 8px rgba(255, 255, 255, 0.4);
}
.text-glow-hover:hover {
text-shadow: 0 0 12px rgba(255, 255, 255, 0.6);
transition: text-shadow 0.3s ease;
}
.border-glow {
box-shadow: 0 0 8px rgba(139, 92, 246, 0.3);
}
.border-glow-hover:hover {
box-shadow: 0 0 16px rgba(139, 92, 246, 0.4);
transition: box-shadow 0.3s ease;
}
.parallax-bg {
background-attachment: fixed;
background-position: center;
background-repeat: no-repeat;
background-size: cover;
}
/* Subtle 3D tilt */
.tilt-on-hover {
transition: transform 0.5s ease, backdrop-filter 0.3s ease;
}
.tilt-on-hover:hover {
transform: perspective(1000px) rotateX(3deg) rotateY(3deg);
backdrop-filter: blur(14px) saturate(200%);
}
.bounce-on-hover:hover {
animation: bounce 0.5s;
}
@keyframes bounce {
0%, 100% { transform: translateY(0); }
50% { transform: translateY(-8px); }
}
.wiggle-on-hover:hover {
animation: wiggle 0.5s ease-in-out infinite;
}
@keyframes wiggle {
0%, 100% { transform: rotate(-2deg); }
50% { transform: rotate(2deg); }
}
.flip-on-hover:hover {
animation: flip 0.5s ease;
}
@keyframes flip {
0% { transform: rotateY(0); }
50% { transform: rotateY(180deg); }
100% { transform: rotateY(360deg); }
}
.expand-on-hover:hover {
transform: scale(1.05);
transition: transform 0.3s ease;
backdrop-filter: blur(14px) saturate(200%);
}
.squish-on-active:active {
transform: scale(0.95);
transition: transform 0.1s ease;
}
.rotate-on-scroll {
transition: transform 0.5s ease;
}
/* Fade-in animation */
.staggered-entry {
opacity: 0;
transform: translateY(10px);
transition: all 0.5s ease;
}
.staggered-entry.in-view {
opacity: 1;
transform: translateY(0);
}
.typewriter {
overflow: hidden;
border-right: 2px solid rgba(255,255,255,0.5);
white-space: nowrap;
animation: typing 3.5s steps(40, end), blink-caret 0.75s step-end infinite;
}
@keyframes typing {
from { width: 0 }
to { width: 100% }
}
@keyframes blink-caret {
from, to { border-color: transparent }
50% { border-color: rgba(255,255,255,0.5) }
}
/* Magnetic effect */
.magnetic {
display: inline-block;
transition: transform 0.2s ease;
}
.magnetic:hover {
transform: translate(var(--tx, 0), var(--ty, 0));
}
.glow-on-hover:hover {
filter: drop-shadow(0 0 6px rgba(255, 255, 255, 0.5));
transition: filter 0.3s ease;
}
.breathing {
animation: breathing 3s ease-out infinite;
}
@keyframes breathing {
0%, 100% { transform: scale(1); }
50% { transform: scale(1.03); }
}
.jelly-on-click:active {
animation: jelly 0.5s;
}
@keyframes jelly {
0%, 100% { transform: scale(1, 1); }
25% { transform: scale(0.95, 1.05); }
50% { transform: scale(1.05, 0.95); }
75% { transform: scale(0.98, 1.02); }
}
.neon-flicker {
animation: neon-flicker 2s infinite alternate;
}
@keyframes neon-flicker {
0%, 19.999%, 22%, 62.999%, 64%, 64.999%, 70%, 100% {
opacity: 1;
text-shadow: 0 0 8px rgba(255,255,255,0.5), 0 0 16px rgba(255,255,255,0.5), 0 0 24px rgba(139, 92, 246, 0.3);
}
20%, 21.999%, 63%, 63.999%, 65%, 69.999% {
opacity: 0.7;
text-shadow: none;
}
}
.rainbow-text {
background: linear-gradient(to right,
rgba(255,0,0,0.7),
rgba(255,127,0,0.7),
rgba(255,255,0,0.7),
rgba(0,255,0,0.7),
rgba(0,0,255,0.7),
rgba(75,0,130,0.7),
rgba(148,0,211,0.7));
-webkit-background-clip: text;
background-clip: text;
color: transparent;
background-size: 400% 400%;
animation: rainbow 8s ease infinite;
}
@keyframes rainbow {
0% { background-position: 0% 50%; }
50% { background-position: 100% 50%; }
100% { background-position: 0% 50%; }
}
/* Ultra subtle particles */
.particles {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
overflow: hidden;
pointer-events: none;
z-index: -1;
}
.particle {
position: absolute;
width: 6px;
height: 6px;
background: rgba(255, 255, 255, 0.2);
border-radius: 50%;
pointer-events: none;
}
/* Ultra subtle cursor trail */
.cursor-trail {
position: fixed;
width: 16px;
height: 16px;
border-radius: 50%;
background: rgba(255, 255, 255, 0.15);
pointer-events: none;
transform: translate(-50%, -50%);
z-index: 9999;
mix-blend-mode: screen;
backdrop-filter: blur(2px);
}
/* Ultra thin borders */
.thin-border {
border: 0.5px solid rgba(255,255,255,0.1);
}
/* Special ultra-transparent elements */
.ultra-transparent {
background: rgba(255,255,255,0.05);
backdrop-filter: blur(20px);
-webkit-backdrop-filter: blur(20px);
border: 0.5px solid rgba(255,255,255,0.05);
}
.ultra-transparent-hover:hover {
background: rgba(255,255,255,0.08);
backdrop-filter: blur(24px);
}
/* Floating labels */
.floating-label {
position: absolute;
top: -10px;
left: 10px;
font-size: 0.75rem;
background: rgba(0,0,0,0.3);
padding: 0 5px;
border-radius: 10px;
backdrop-filter: blur(5px);
color: rgba(255,255,255,0.8);
}
/* Transparent scrollbar */
::-webkit-scrollbar {
width: 8px;
height: 8px;
}
::-webkit-scrollbar-track {
background: rgba(255,255,255,0.05);
border-radius: 10px;
}
::-webkit-scrollbar-thumb {
background: rgba(255,255,255,0.2);
border-radius: 10px;
}
::-webkit-scrollbar-thumb:hover {
background: rgba(255,255,255,0.3);
}
</style>
</head>
<body class="gradient-bg text-white min-h-screen overflow-x-hidden">
<!-- Cursor trail -->
<div id="cursor-trail" class="cursor-trail"></div>
<!-- Floating particles -->
<div class="particles" id="particles"></div>
<!-- Main container with ultra transparent glass effect -->
<div class="min-h-screen flex flex-col items-center justify-center p-8">
<!-- Header with ultra transparent effects -->
<header class="ultra-transparent rounded-3xl p-8 mb-12 w-full max-w-4xl text-center relative overflow-hidden ultra-transparent-hover">
<div class="absolute inset-0 bg-white opacity-5"></div>
<h1 class="text-6xl font-bold mb-6 text-glow text-glow-hover rainbow-text typewriter">
TRANSPARENT MADNESS
</h1>
<p class="text-xl mb-8 text-glow-hover opacity-90">
A showcase of <span class="underline decoration-wavy decoration-purple-300/50">ultra transparent</span> UI interactions
</p>
<div class="flex justify-center space-x-6">
<button class="ultra-transparent rounded-full px-8 py-3 font-bold ripple micro-hover micro-active spin-on-hover glow-on-hover thin-border">
<span class="flex items-center opacity-90">
<i class="fas fa-play mr-2"></i> EXPERIENCE
</span>
</button>
<button class="aero-glass rounded-full px-8 py-3 font-bold ripple micro-hover micro-active shake-on-click glow-on-hover thin-border">
<span class="flex items-center opacity-90">
<i class="fas fa-magic mr-2"></i> MAGIC
</span>
</button>
</div>
</header>
<!-- Grid of ultra transparent interactive cards -->
<div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-8 w-full max-w-6xl">
<!-- Card 1 -->
<div class="ultra-transparent rounded-3xl p-6 micro-hover micro-active tilt-on-hover ripple staggered-entry thin-border">
<div class="text-4xl mb-4 text-center opacity-90">
<i class="fas fa-mouse-pointer breathing"></i>
</div>
<h3 class="text-2xl font-bold mb-3 text-center text-glow-hover opacity-95">Hover Effects</h3>
<p class="mb-4 opacity-80">Watch as I transform with ultra subtle transparency changes on hover.</p>
<div class="flex justify-center">
<button class="aero-glass-dark rounded-full px-4 py-2 text-sm ripple micro-hover micro-active wiggle-on-hover thin-border">
Hover Me
</button>
</div>
</div>
<!-- Card 2 -->
<div class="ultra-transparent rounded-3xl p-6 micro-hover micro-active flip-on-hover ripple staggered-entry thin-border">
<div class="text-4xl mb-4 text-center opacity-90">
<i class="fas fa-hand-pointer spin-on-hover"></i>
</div>
<h3 class="text-2xl font-bold mb-3 text-center text-glow-hover opacity-95">Click Animations</h3>
<p class="mb-4 opacity-80">Subtle jelly effects with increased transparency on interaction.</p>
<div class="flex justify-center">
<button class="aero-glass-dark rounded-full px-4 py-2 text-sm ripple micro-hover micro-active jelly-on-click thin-border">
Click Me
</button>
</div>
</div>
<!-- Card 3 -->
<div class="ultra-transparent rounded-3xl p-6 micro-hover micro-active expand-on-hover ripple staggered-entry thin-border">
<div class="text-4xl mb-4 text-center opacity-90">
<i class="fas fa-keyboard bounce-on-hover"></i>
</div>
<h3 class="text-2xl font-bold mb-3 text-center text-glow-hover opacity-95">Focus States</h3>
<p class="mb-4 opacity-80">Even form inputs get ultra subtle glow effects when focused.</p>
<div class="flex justify-center">
<input type="text" placeholder="Focus me" class="aero-glass-dark rounded-full px-4 py-2 text-sm w-full max-w-xs micro-focus thin-border opacity-90">
</div>
</div>
<!-- Card 4 -->
<div class="ultra-transparent rounded-3xl p-6 micro-hover micro-active tilt-on-hover ripple staggered-entry thin-border">
<div class="text-4xl mb-4 text-center opacity-90">
<i class="fas fa-scroll float-animation"></i>
</div>
<h3 class="text-2xl font-bold mb-3 text-center text-glow-hover opacity-95">Scroll Effects</h3>
<p class="mb-4 opacity-80">Elements fade in with increased transparency as you scroll.</p>
<div class="flex justify-center">
<div class="aero-glass-dark rounded-full h-8 w-8 flex items-center justify-center ripple micro-hover rotate-on-scroll thin-border">
<i class="fas fa-arrow-down opacity-90"></i>
</div>
</div>
</div>
<!-- Card 5 -->
<div class="ultra-transparent rounded-3xl p-6 micro-hover micro-active flip-on-hover ripple staggered-entry thin-border">
<div class="text-4xl mb-4 text-center opacity-90">
<i class="fas fa-cursor magnetic"></i>
</div>
<h3 class="text-2xl font-bold mb-3 text-center text-glow-hover opacity-95">Magnetic Pull</h3>
<p class="mb-4 opacity-80">Your cursor gently affects transparent elements with physics.</p>
<div class="flex justify-center">
<div class="aero-glass-dark rounded-full h-8 w-8 flex items-center justify-center ripple magnetic thin-border">
<i class="fas fa-magnet opacity-90"></i>
</div>
</div>
</div>
<!-- Card 6 -->
<div class="ultra-transparent rounded-3xl p-6 micro-hover micro-active expand-on-hover ripple staggered-entry thin-border">
<div class="text-4xl mb-4 text-center opacity-90">
<i class="fas fa-spinner spin-on-hover"></i>
</div>
<h3 class="text-2xl font-bold mb-3 text-center text-glow-hover opacity-95">Loading States</h3>
<p class="mb-4 opacity-80">Even waiting is beautiful with transparent animated loaders.</p>
<div class="flex justify-center">
<div class="aero-glass-dark rounded-full h-8 w-8 flex items-center justify-center ripple spin-on-hover thin-border">
<i class="fas fa-circle-notch opacity-90"></i>
</div>
</div>
</div>
</div>
<!-- Floating action button with ultra transparency -->
<div class="fixed bottom-8 right-8">
<button class="ultra-transparent rounded-full h-16 w-16 flex items-center justify-center text-2xl ripple micro-hover micro-active spin-on-hover jelly-on-click glow-on-hover thin-border">
<i class="fas fa-plus opacity-90"></i>
</button>
</div>
<!-- Ultra transparent notification toast -->
<div class="fixed top-8 right-8 ultra-transparent rounded-2xl p-4 max-w-xs ripple micro-hover staggered-entry thin-border" id="toast">
<div class="flex items-start">
<div class="flex-shrink-0">
<div class="h-10 w-10 rounded-full bg-purple-500/30 flex items-center justify-center text-white spin-on-hover thin-border">
<i class="fas fa-bell opacity-90"></i>
</div>
</div>
<div class="ml-3">
<h3 class="text-sm font-bold text-glow-hover opacity-95">New Interaction!</h3>
<p class="text-sm mt-1 opacity-80">You've unlocked transparent UI magic!</p>
</div>
<button class="ml-auto -mr-1 -mt-1 flex-shrink-0 flex items-center justify-center h-8 w-8 rounded-full ripple micro-hover micro-active thin-border">
<i class="fas fa-times opacity-90"></i>
</button>
</div>
</div>
<!-- Color mode toggle with ultra transparency -->
<div class="fixed top-8 left-8">
<button id="color-mode" class="ultra-transparent rounded-full h-12 w-12 flex items-center justify-center text-xl ripple micro-hover micro-active spin-on-hover jelly-on-click glow-on-hover thin-border">
<i class="fas fa-moon opacity-90"></i>
</button>
</div>
<!-- Audio toggle with ultra transparency -->
<div class="fixed top-8 left-24">
<button id="sound-toggle" class="ultra-transparent rounded-full h-12 w-12 flex items-center justify-center text-xl ripple micro-hover micro-active shake-on-click glow-on-hover thin-border">
<i class="fas fa-volume-up opacity-90"></i>
</button>
</div>
<!-- Floating labels demo -->
<div class="fixed bottom-8 left-8 ultra-transparent rounded-2xl p-6 max-w-xs ripple micro-hover thin-border">
<div class="relative">
<span class="floating-label">Email</span>
<input type="email" class="ultra-transparent w-full px-4 py-3 rounded-lg mt-2 micro-focus thin-border opacity-90" placeholder=" ">
</div>
<div class="relative mt-6">
<span class="floating-label">Password</span>
<input type="password" class="ultra-transparent w-full px-4 py-3 rounded-lg mt-2 micro-focus thin-border opacity-90" placeholder=" ">
</div>
<button class="ultra-transparent w-full mt-6 py-2 rounded-lg ripple micro-hover micro-active thin-border">
<span class="opacity-90">Sign In</span>
</button>
</div>
</div>
<script>
// Create ultra subtle particles
const particlesContainer = document.getElementById('particles');
const particleCount = 80;
for (let i = 0; i < particleCount; i++) {
const particle = document.createElement('div');
particle.classList.add('particle');
// Random position
const posX = Math.random() * 100;
const posY = Math.random() * 100;
// Random size
const size = Math.random() * 4 + 2;
// Random animation duration and delay
const duration = Math.random() * 25 + 15;
const delay = Math.random() * 15;
// Random movement direction
const moveX = Math.random() * 100 - 50;
const moveY = Math.random() * 100 - 50;
particle.style.left = `${posX}%`;
particle.style.top = `${posY}%`;
particle.style.width = `${size}px`;
particle.style.height = `${size}px`;
particle.style.opacity = Math.random() * 0.3 + 0.1;
particle.style.animation = `float ${duration}s ease-in-out ${delay}s infinite`;
particle.style.setProperty('--move-x', `${moveX}px`);
particle.style.setProperty('--move-y', `${moveY}px`);
particlesContainer.appendChild(particle);
}
// Ultra subtle cursor trail effect
const cursor = document.getElementById('cursor-trail');
let mouseX = 0;
let mouseY = 0;
let trailX = 0;
let trailY = 0;
let speed = 0.2;
document.addEventListener('mousemove', (e) => {
mouseX = e.clientX;
mouseY = e.clientY;
});
const animateCursor = () => {
const dx = mouseX - trailX;
const dy = mouseY - trailY;
trailX += dx * speed;
trailY += dy * speed;
cursor.style.left = `${trailX}px`;
cursor.style.top = `${trailY}px`;
// Change cursor color based on position
const hue = (trailX / window.innerWidth) * 360;
cursor.style.background = `hsla(${hue}, 80%, 80%, 0.1)`;
requestAnimationFrame(animateCursor);
};
animateCursor();
// Magnetic button effect
const magneticButtons = document.querySelectorAll('.magnetic');
magneticButtons.forEach(button => {
button.addEventListener('mousemove', (e) => {
const rect = button.getBoundingClientRect();
const x = e.clientX - rect.left;
const y = e.clientY - rect.top;
const centerX = rect.width / 2;
const centerY = rect.height / 2;
const distanceX = x - centerX;
const distanceY = y - centerY;
const distance = Math.sqrt(distanceX * distanceX + distanceY * distanceY);
const maxDistance = 40;
if (distance < maxDistance) {
const translateX = (distanceX / centerX) * 5;
const translateY = (distanceY / centerY) * 5;
button.style.setProperty('--tx', `${translateX}px`);
button.style.setProperty('--ty', `${translateY}px`);
} else {
button.style.setProperty('--tx', '0');
button.style.setProperty('--ty', '0');
}
});
button.addEventListener('mouseleave', () => {
button.style.setProperty('--tx', '0');
button.style.setProperty('--ty', '0');
});
});
// Scroll animation for staggered entries
const staggeredEntries = document.querySelectorAll('.staggered-entry');
const checkInView = () => {
staggeredEntries.forEach((entry, index) => {
const rect = entry.getBoundingClientRect();
const isInView = rect.top <= window.innerHeight * 0.8;
if (isInView) {
// Add delay based on index for staggered effect
entry.style.transitionDelay = `${index * 0.1}s`;
entry.classList.add('in-view');
}
});
};
// Initial check
checkInView();
// Check on scroll
window.addEventListener('scroll', checkInView);
// Color mode toggle
const colorModeBtn = document.getElementById('color-mode');
let isDarkMode = false;
colorModeBtn.addEventListener('click', () => {
isDarkMode = !isDarkMode;
if (isDarkMode) {
document.body.classList.remove('gradient-bg');
document.body.classList.add('bg-gray-900/90');
colorModeBtn.innerHTML = '<i class="fas fa-sun opacity-90"></i>';
// Add subtle color change effect
document.body.style.animation = 'color-rotate 3s linear';
setTimeout(() => {
document.body.style.animation = '';
}, 3000);
} else {
document.body.classList.add('gradient-bg');
document.body.classList.remove('bg-gray-900/90');
colorModeBtn.innerHTML = '<i class="fas fa-moon opacity-90"></i>';
// Add subtle color change effect
document.body.style.animation = 'color-rotate 3s linear';
setTimeout(() => {
document.body.style.animation = '';
}, 3000);
}
// Add subtle confetti effect
createConfetti();
});
// Sound toggle
const soundToggle = document.getElementById('sound-toggle');
let soundEnabled = true;
soundToggle.addEventListener('click', () => {
soundEnabled = !soundEnabled;
if (soundEnabled) {
soundToggle.innerHTML = '<i class="fas fa-volume-up opacity-90"></i>';
} else {
soundToggle.innerHTML = '<i class="fas fa-volume-mute opacity-90"></i>';
}
});
// Create subtle confetti effect
function createConfetti() {
const colors = ['rgba(255,0,0,0.5)', 'rgba(0,255,0,0.5)', 'rgba(0,0,255,0.5)', 'rgba(255,255,0,0.5)', 'rgba(255,0,255,0.5)', 'rgba(0,255,255,0.5)'];
for (let i = 0; i < 80; i++) {
const confetti = document.createElement('div');
confetti.classList.add('particle');
const posX = Math.random() * window.innerWidth;
const posY = -10;
const size = Math.random() * 8 + 3;
const color = colors[Math.floor(Math.random() * colors.length)];
const rotation = Math.random() * 360;
const duration = Math.random() * 4 + 2;
confetti.style.left = `${posX}px`;
confetti.style.top = `${posY}px`;
confetti.style.width = `${size}px`;
confetti.style.height = `${size}px`;
confetti.style.background = color;
confetti.style.transform = `rotate(${rotation}deg)`;
confetti.style.animation = `confetti-fall ${duration}s linear forwards`;
document.body.appendChild(confetti);
// Remove after animation
setTimeout(() => {
confetti.remove();
}, duration * 1000);
}
// Add confetti animation to styles
const style = document.createElement('style');
style.innerHTML = `
@keyframes confetti-fall {
0% { transform: translateY(0) rotate(0deg); opacity: 0.8; }
100% { transform: translateY(${window.innerHeight}px) rotate(360deg); opacity: 0; }
}
`;
document.head.appendChild(style);
}
// Easter egg - secret interaction
let konamiCode = [];
const secretCode = ['ArrowUp', 'ArrowUp', 'ArrowDown', 'ArrowDown', 'ArrowLeft', 'ArrowRight', 'ArrowLeft', 'ArrowRight', 'b', 'a'];
document.addEventListener('keydown', (e) => {
konamiCode.push(e.key);
if (konamiCode.length > secretCode.length) {
konamiCode.shift();
}
if (konamiCode.join('') === secretCode.join('')) {
// Activate secret mode
document.body.style.animation = 'color-rotate 1s linear infinite';
createConfetti();
// Show secret notification
const toast = document.getElementById('toast');
toast.querySelector('h3').textContent = 'SECRET UNLOCKED!';
toast.querySelector('p').textContent = 'Ultra transparent mode activated!';
toast.classList.add('neon-flicker');
}
});
// Make everything draggable with ultra subtle effects
document.querySelectorAll('.ultra-transparent, .aero-glass').forEach(element => {
let pos1 = 0, pos2 = 0, pos3 = 0, pos4 = 0;
element.addEventListener('mousedown', dragMouseDown);
function dragMouseDown(e) {
e = e || window.event;
e.preventDefault();
// Get the mouse cursor position at startup
pos3 = e.clientX;
pos4 = e.clientY;
// Increase transparency while dragging
element.style.opacity = '0.7';
document.addEventListener('mouseup', closeDragElement);
document.addEventListener('mousemove', elementDrag);
}
function elementDrag(e) {
e = e || window.event;
e.preventDefault();
// Calculate the new cursor position
pos1 = pos3 - e.clientX;
pos2 = pos4 - e.clientY;
pos3 = e.clientX;
pos4 = e.clientY;
// Set the element's new position
element.style.top = (element.offsetTop - pos2) + "px";
element.style.left = (element.offsetLeft - pos1) + "px";
element.style.position = 'absolute';
// Add subtle wobbly effect while dragging
element.style.transform = `rotate(${pos1 * 0.3}deg)`;
}
function closeDragElement() {
// Stop moving when mouse button is released
document.removeEventListener('mouseup', closeDragElement);
document.removeEventListener('mousemove', elementDrag);
// Restore opacity
element.style.opacity = '';
// Snap back to original position with animation
element.style.transition = 'all 0.5s cubic-bezier(0.68, -0.6, 0.32, 1.6)';
element.style.transform = '';
element.style.top = '';
element.style.left = '';
element.style.position = '';
setTimeout(() => {
element.style.transition = '';
}, 500);
}
});
</script>
<p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-deepsite.hf.space/logo.svg" alt="DeepSite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-deepsite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >DeepSite</a> - 🧬 <a href="https://enzostvs-deepsite.hf.space?remix=steven1015/transparetn" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
</html>