Glassmorphism is a design trend that brings a frosted-glass aesthetic to user interfaces, creating a sense of depth and visual hierarchy.
Here are 10 stunning examples of glassmorphism in action, showcasing its versatility and elegance in modern UI design.
CODE1
Here's the code:
CODETEXT1
CODE2
Here's the code:
CODETEXT2
CODE3
Here's the code:
CODETEXT3
CODE4
Here's the code:
CODETEXT4
CODE5
Here's the code:
CODETEXT5
Subframe's drag-and-drop interface and intuitive, responsive canvas make it effortless to design pixel-perfect UIs, including stunning glassmorphism effects. Loved by designers and developers alike, Subframe ensures your creations are both beautiful and functional.
Start for free and bring your design visions to life with Subframe today!
CODE6
Here's the code:
CODETEXT6
CODE7
Here's the code:
CODETEXT7
CODE8
Here's the code:
CODETEXT8
CODE9
Here's the code:
CODETEXT9
CODE10
Here's the code:
CODETEXT10
Ready to elevate your UI designs? With Subframe, you can create pixel-perfect interfaces, including stunning glassmorphism effects, in minutes. Our drag-and-drop editor ensures efficiency and precision.
Start for free and begin designing immediately. Unleash your creativity with Subframe today!
<html> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Modern Music Dashboard</title> <style> :root { --primary-color: #ff84e8; --secondary-color: #84c1ff; --accent-color: #8884ff; --text-color: rgba(255, 255, 255, 0.95); --text-secondary: rgba(255, 255, 255, 0.7); --background: #131c2a; --glass-background: rgba(255, 255, 255, 0.08); --card-background: rgba(255, 255, 255, 0.1); --blur-amount: 12px; --transition-speed: 0.3s; } * { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; } body { background: var(--background); color: var(--text-color); width: 100%; height: 100vh; display: flex; justify-content: center; align-items: center; overflow: hidden; position: relative; } .bg-gradient { position: absolute; width: 100%; height: 100%; overflow: hidden; } .bg-gradient:before { content: ''; position: absolute; top: -50%; left: -50%; width: 200%; height: 200%; background: radial-gradient(circle at 30% 40%, var(--primary-color), transparent 40%), radial-gradient(circle at 70% 60%, var(--secondary-color), transparent 40%), radial-gradient(circle at 50% 50%, var(--accent-color), transparent 60%); filter: blur(30px); opacity: 0.15; animation: bgAnimation 30s infinite alternate; } @keyframes bgAnimation { 0% { transform: rotate(0deg) scale(1); } 100% { transform: rotate(360deg) scale(1.2); } } .dashboard-container { width: 100%; max-width: 700px; height: 100%; max-height: 700px; display: flex; flex-direction: column; position: relative; z-index: 1; padding: 20px; } .dashboard { background: var(--glass-background); backdrop-filter: blur(var(--blur-amount)); -webkit-backdrop-filter: blur(var(--blur-amount)); border-radius: 20px; box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2); border: 1px solid rgba(255, 255, 255, 0.1); padding: 25px; flex: 1; display: flex; flex-direction: column; overflow: hidden; } .header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 25px; } .logo { font-size: 24px; font-weight: 800; background: linear-gradient(to right, var(--primary-color), var(--secondary-color)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; letter-spacing: -0.5px; } .user-profile { width: 40px; height: 40px; border-radius: 50%; background: var(--glass-background); border: 1px solid rgba(255, 255, 255, 0.2); overflow: hidden; cursor: pointer; position: relative; transition: transform var(--transition-speed); } .user-profile:hover { transform: scale(1.1); } .user-profile img { width: 100%; height: 100%; object-fit: cover; } .search-bar { background: var(--glass-background); border-radius: 12px; padding: 12px 20px; display: flex; align-items: center; margin-bottom: 25px; border: 1px solid rgba(255, 255, 255, 0.1); transition: all var(--transition-speed); } .search-bar:focus-within { border-color: rgba(255, 255, 255, 0.3); box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.1); } .search-bar i { color: var(--text-secondary); margin-right: 10px; } .search-bar input { background: transparent; border: none; outline: none; color: var(--text-color); width: 100%; font-size: 14px; } .search-bar input::placeholder { color: var(--text-secondary); } .content-section { flex: 1; display: flex; flex-direction: column; overflow: hidden; } .section-title { font-size: 18px; font-weight: 600; margin-bottom: 15px; display: flex; justify-content: space-between; align-items: center; } .see-all { font-size: 14px; color: var(--text-secondary); font-weight: 500; cursor: pointer; transition: color var(--transition-speed); } .see-all:hover { color: var(--text-color); } .now-playing { background: var(--card-background); border-radius: 16px; padding: 20px; margin-bottom: 25px; display: flex; align-items: center; position: relative; overflow: hidden; border: 1px solid rgba(255, 255, 255, 0.1); } .now-playing::before { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(45deg, var(--primary-color), var(--secondary-color)); opacity: 0.1; filter: blur(20px); z-index: -1; } .album-art { width: 100px; height: 100px; border-radius: 12px; overflow: hidden; box-shadow: 0 8px 15px rgba(0, 0, 0, 0.2); position: relative; transition: transform var(--transition-speed); } .album-art:hover { transform: scale(1.05) translateY(-5px); } .album-art img { width: 100%; height: 100%; object-fit: cover; } .now-playing-info { margin-left: 20px; flex: 1; } .song-title { font-size: 18px; font-weight: 600; margin-bottom: 5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .artist { font-size: 14px; color: var(--text-secondary); margin-bottom: 15px; } .progress-container { width: 100%; height: 4px; background: rgba(255, 255, 255, 0.1); border-radius: 2px; overflow: hidden; margin-bottom: 10px; cursor: pointer; } .progress-bar { height: 100%; width: 35%; background: linear-gradient(to right, var(--primary-color), var(--secondary-color)); border-radius: 2px; position: relative; transition: width 0.1s linear; } .progress-bar::after { content: ''; position: absolute; right: -4px; top: 50%; transform: translateY(-50%); width: 8px; height: 8px; border-radius: 50%; background: var(--text-color); opacity: 0; transition: opacity var(--transition-speed); } .progress-container:hover .progress-bar::after { opacity: 1; } .time-info { display: flex; justify-content: space-between; font-size: 12px; color: var(--text-secondary); } .controls { display: flex; align-items: center; justify-content: center; margin-top: 5px; } .control-btn { background: none; border: none; color: var(--text-color); font-size: 16px; cursor: pointer; width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; border-radius: 50%; transition: all var(--transition-speed); position: relative; margin: 0 8px; } .control-btn:hover { background: rgba(255, 255, 255, 0.1); transform: translateY(-2px); } .play-pause { width: 48px; height: 48px; background: linear-gradient(45deg, var(--primary-color), var(--secondary-color)); position: relative; overflow: hidden; } .play-pause:hover { background: linear-gradient(45deg, var(--secondary-color), var(--primary-color)); transform: scale(1.1); } .play-pause::before { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(45deg, var(--primary-color), var(--secondary-color)); opacity: 0.7; filter: blur(15px); z-index: -1; } .recently-played { flex: 1; overflow-y: auto; padding-right: 10px; margin-right: -10px; scrollbar-width: thin; scrollbar-color: rgba(255, 255, 255, 0.2) transparent; } .recently-played::-webkit-scrollbar { width: 4px; } .recently-played::-webkit-scrollbar-track { background: transparent; } .recently-played::-webkit-scrollbar-thumb { background-color: rgba(255, 255, 255, 0.2); border-radius: 4px; } .track-item { display: flex; align-items: center; padding: 10px 15px; border-radius: 12px; margin-bottom: 10px; cursor: pointer; transition: all var(--transition-speed); position: relative; overflow: hidden; } .track-item:hover { background: var(--glass-background); } .track-item::before { content: ''; position: absolute; left: 0; top: 0; width: 4px; height: 100%; background: linear-gradient(to bottom, var(--primary-color), var(--secondary-color)); opacity: 0; transition: opacity var(--transition-speed); } .track-item:hover::before { opacity: 1; } .track-item.active { background: var(--glass-background); } .track-item.active::before { opacity: 1; } .track-number { font-size: 14px; font-weight: 500; color: var(--text-secondary); margin-right: 15px; width: 20px; text-align: center; } .track-item:hover .track-number { display: none; } .track-item:hover .play-icon { display: block; } .play-icon { display: none; font-size: 14px; color: var(--text-color); } .track-thumbnail { width: 40px; height: 40px; border-radius: 8px; overflow: hidden; margin-right: 15px; } .track-thumbnail img { width: 100%; height: 100%; object-fit: cover; } .track-info { flex: 1; } .track-name { font-size: 14px; font-weight: 500; margin-bottom: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .track-artist { font-size: 12px; color: var(--text-secondary); } .track-duration { font-size: 12px; color: var(--text-secondary); margin-left: 10px; } .footer-player { margin-top: auto; background: var(--glass-background); backdrop-filter: blur(var(--blur-amount)); -webkit-backdrop-filter: blur(var(--blur-amount)); border-radius: 12px; padding: 12px 20px; display: flex; align-items: center; border-top: 1px solid rgba(255, 255, 255, 0.05); display: none; } .equalizer { display: flex; align-items: flex-end; height: 12px; gap: 2px; margin-right: 10px; } .eq-bar { width: 2px; background: var(--accent-color); border-radius: 1px; animation: equalize 0.8s ease-in-out infinite alternate; } .eq-bar:nth-child(1) { height: 40%; animation-delay: 0s; } .eq-bar:nth-child(2) { height: 80%; animation-delay: 0.2s; } .eq-bar:nth-child(3) { height: 60%; animation-delay: 0.4s; } .eq-bar:nth-child(4) { height: 90%; animation-delay: 0.6s; } @keyframes equalize { 0% { height: 10%; } 100% { height: 100%; } } .audio-wave { position: absolute; right: 20px; top: 50%; transform: translateY(-50%); display: flex; align-items: center; gap: 3px; height: 20px; } .wave-bar { width: 3px; background: rgba(255, 255, 255, 0.6); border-radius: 1px; animation: waveAnimation 0.5s ease-in-out infinite alternate; } .wave-bar:nth-child(1) { height: 30%; animation-delay: 0s; } .wave-bar:nth-child(2) { height: 60%; animation-delay: 0.1s; } .wave-bar:nth-child(3) { height: 40%; animation-delay: 0.2s; } .wave-bar:nth-child(4) { height: 80%; animation-delay: 0.3s; } .wave-bar:nth-child(5) { height: 50%; animation-delay: 0.4s; } @keyframes waveAnimation { 0% { transform: scaleY(0.6); } 100% { transform: scaleY(1); } } @media (max-width: 600px) { .dashboard { padding: 15px; } .now-playing { flex-direction: column; align-items: flex-start; } .album-art { width: 80px; height: 80px; margin-bottom: 15px; } .now-playing-info { margin-left: 0; width: 100%; } } .volume-container { display: flex; align-items: center; margin-left: 15px; } .volume-icon { color: var(--text-secondary); margin-right: 10px; cursor: pointer; transition: color var(--transition-speed); } .volume-icon:hover { color: var(--text-color); } .volume-slider { width: 80px; height: 4px; background: rgba(255, 255, 255, 0.1); border-radius: 2px; overflow: hidden; cursor: pointer; } .volume-level { height: 100%; width: 70%; background: linear-gradient(to right, var(--primary-color), var(--secondary-color)); border-radius: 2px; position: relative; transition: width 0.1s linear; } .mood-badge { font-size: 11px; padding: 3px 8px; border-radius: 10px; background: rgba(255, 255, 255, 0.1); color: var(--text-secondary); margin-left: 10px; font-weight: 500; } .vibrant { background: linear-gradient(90deg, rgba(255, 132, 232, 0.2), rgba(132, 193, 255, 0.2)); border: 1px solid rgba(255, 132, 232, 0.3); } .chill { background: linear-gradient(90deg, rgba(132, 193, 255, 0.2), rgba(136, 132, 255, 0.2)); border: 1px solid rgba(132, 193, 255, 0.3); } .upbeat { background: linear-gradient(90deg, rgba(255, 214, 132, 0.2), rgba(255, 132, 132, 0.2)); border: 1px solid rgba(255, 214, 132, 0.3); } .melancholic { background: linear-gradient(90deg, rgba(136, 132, 255, 0.2), rgba(132, 193, 255, 0.2)); border: 1px solid rgba(136, 132, 255, 0.3); } .shuffle-container { display: flex; gap: 15px; margin-left: auto; } .shuffle-btn, .repeat-btn { color: var(--text-secondary); cursor: pointer; transition: all var(--transition-speed); } .shuffle-btn:hover, .repeat-btn:hover { color: var(--text-color); } .shuffle-btn.active, .repeat-btn.active { color: var(--primary-color); } .ripple { position: absolute; width: 100px; height: 100px; border-radius: 50%; background: rgba(255, 255, 255, 0.1); transform: scale(0); animation: ripple 0.6s linear; pointer-events: none; } @keyframes ripple { to { transform: scale(2); opacity: 0; } } .hover-float { transition: transform 0.3s ease; } .hover-float:hover { transform: translateY(-5px); } </style> </head> <body> <div class="bg-gradient"></div> <div class="dashboard-container"> <div class="dashboard"> <div class="header"> <div class="logo">AURA</div> <div class="user-profile hover-float"> <img src="https://images.unsplash.com/photo-1544005313-94ddf0286df2?q=80&w=100&auto=format&fit=crop" alt="Profile"> </div> </div> <div class="search-bar"> <i class="fas fa-search">🔍</i> <input type="text" placeholder="Search artists, songs, or moods..."> </div> <div class="content-section"> <div class="now-playing"> <div class="album-art"> <img src="https://images.unsplash.com/photo-1598387993090-a6647f6e6a65?q=80&w=200&auto=format&fit=crop" alt="Album Art"> </div> <div class="now-playing-info"> <div class="song-title">Midnight Reflections</div> <div class="artist">Lunar Echo <span class="mood-badge chill">Chill</span></div> <div class="progress-container" id="progressContainer"> <div class="progress-bar" id="progressBar"></div> </div> <div class="time-info"> <div class="current-time">1:45</div> <div class="total-time">4:30</div> </div> </div> <div class="audio-wave"> <div class="wave-bar"></div> <div class="wave-bar"></div> <div class="wave-bar"></div> <div class="wave-bar"></div> <div class="wave-bar"></div> </div> </div> <div class="controls"> <div class="shuffle-container"> <div class="shuffle-btn"> <i class="fas fa-random">🔀</i> </div> <div class="repeat-btn"> <i class="fas fa-redo-alt">🔁</i> </div> </div> <button class="control-btn" id="prevBtn"> <i class="fas fa-step-backward">⏮️</i> </button> <button class="control-btn play-pause" id="playPauseBtn"> <i class="fas fa-pause" id="playPauseIcon">⏸️</i> </button> <button class="control-btn" id="nextBtn"> <i class="fas fa-step-forward">⏭️</i> </button> <div class="volume-container"> <div class="volume-icon"> <i class="fas fa-volume-up">🔊</i> </div> <div class="volume-slider"> <div class="volume-level"></div> </div> </div> </div> <div class="section-title"> <span>Recently Played</span> <span class="see-all">See All</span> </div> <div class="recently-played"> <div class="track-item active"> <div class="track-number">1</div> <div class="play-icon">▶️</div> <div class="track-thumbnail"> <img src="https://images.unsplash.com/photo-1598387993090-a6647f6e6a65?q=80&w=100&auto=format&fit=crop" alt="Track"> </div> <div class="track-info"> <div class="track-name">Midnight Reflections</div> <div class="track-artist">Lunar Echo</div> </div> <span class="mood-badge chill">Chill</span> <div class="track-duration">4:30</div> </div> <div class="track-item"> <div class="track-number">2</div> <div class="play-icon">▶️</div> <div class="track-thumbnail"> <img src="https://images.unsplash.com/photo-1511671782779-c97d3d27a1d4?q=80&w=100&auto=format&fit=crop" alt="Track"> </div> <div class="track-info"> <div class="track-name">Electric Dreams</div> <div class="track-artist">Neon Pulse</div> </div> <span class="mood-badge vibrant">Vibrant</span> <div class="track-duration">3:25</div> </div> <div class="track-item"> <div class="track-number">3</div> <div class="play-icon">▶️</div> <div class="track-thumbnail"> <img src="https://images.unsplash.com/photo-1614613535308-eb5fbd3d2c17?q=80&w=100&auto=format&fit=crop" alt="Track"> </div> <div class="track-info"> <div class="track-name">Summer Whispers</div> <div class="track-artist">Coastal Wave</div> </div> <span class="mood-badge upbeat">Upbeat</span> <div class="track-duration">3:52</div> </div> <div class="track-item"> <div class="track-number">4</div> <div class="play-icon">▶️</div> <div class="track-thumbnail"> <img src="https://images.unsplash.com/photo-1630713079609-700d67468c8b?q=80&w=100&auto=format&fit=crop" alt="Track"> </div> <div class="track-info"> <div class="track-name">Autumn Rain</div> <div class="track-artist">Ethereal Silence</div> </div> <span class="mood-badge melancholic">Melancholic</span> <div class="track-duration">5:17</div> </div> <div class="track-item"> <div class="track-number">5</div> <div class="play-icon">▶️</div> <div class="track-thumbnail"> <img src="https://images.unsplash.com/photo-1611162617213-7d7a39e9b1d7?q=80&w=100&auto=format&fit=crop" alt="Track"> </div> <div class="track-info"> <div class="track-name">Neon City Lights</div> <div class="track-artist">Urban Echo</div> </div> <span class="mood-badge vibrant">Vibrant</span> <div class="track-duration">4:08</div> </div> <div class="track-item"> <div class="track-number">6</div> <div class="play-icon">▶️</div> <div class="track-thumbnail"> <img src="https://images.unsplash.com/photo-1504898770365-14faca6a7320?q=80&w=100&auto=format&fit=crop" alt="Track"> </div> <div class="track-info"> <div class="track-name">Mountain Dew</div> <div class="track-artist">Forest Ambience</div> </div> <span class="mood-badge chill">Chill</span> <div class="track-duration">6:21</div> </div> </div> </div> </div> </div> <script> document.addEventListener('DOMContentLoaded', function() { // Play/Pause button functionality const playPauseBtn = document.getElementById('playPauseBtn'); const playPauseIcon = document.getElementById('playPauseIcon'); const audioWave = document.querySelector('.audio-wave'); let isPlaying = true; playPauseBtn.addEventListener('click', function(e) { isPlaying = !isPlaying; if (isPlaying) { playPauseIcon.textContent = "⏸️"; audioWave.style.display = 'flex'; startProgressAnimation(); } else { playPauseIcon.textContent = "▶️"; audioWave.style.display = 'none'; stopProgressAnimation(); } createRippleEffect(e); }); // Ripple effect function createRippleEffect(e) { const button = e.currentTarget; const ripple = document.createElement('span'); ripple.classList.add('ripple'); const rect = button.getBoundingClientRect(); const size = Math.max(rect.width, rect.height); ripple.style.width = ripple.style.height = `${size}px`; ripple.style.left = `${e.clientX - rect.left - size / 2}px`; ripple.style.top = `${e.clientY - rect.top - size / 2}px`; button.appendChild(ripple); setTimeout(() => { ripple.remove(); }, 600); } // Track item hover effect const trackItems = document.querySelectorAll('.track-item'); trackItems.forEach(item => { item.addEventListener('click', function() { trackItems.forEach(t => t.classList.remove('active')); this.classList.add('active'); // Update now playing const thumbnail = this.querySelector('.track-thumbnail img').src; const title = this.querySelector('.track-name').textContent; const artist = this.querySelector('.track-artist').textContent; const mood = this.querySelector('.mood-badge').outerHTML; document.querySelector('.now-playing .album-art img').src = thumbnail; document.querySelector('.now-playing .song-title').textContent = title; document.querySelector('.now-playing .artist').innerHTML = artist + ' ' + mood; // Reset progress document.getElementById('progressBar').style.width = '0%'; document.querySelector('.current-time').textContent = '0:00'; // Ensure playing state isPlaying = true; playPauseIcon.textContent = "⏸️"; audioWave.style.display = 'flex'; resetAndStartProgress(); }); }); // Progress bar functionality const progressContainer = document.getElementById('progressContainer'); const progressBar = document.getElementById('progressBar'); const currentTimeEl = document.querySelector('.current-time'); let progressInterval; let currentProgress = 35; // Starting at 35% progressContainer.addEventListener('click', function(e) { const rect = this.getBoundingClientRect(); const clickPosition = e.clientX - rect.left; const progressWidth = (clickPosition / rect.width) * 100; currentProgress = progressWidth; progressBar.style.width = `${progressWidth}%`; // Update time const totalSeconds = 270; // 4:30 in seconds const currentSeconds = Math.floor((progressWidth / 100) * totalSeconds); const minutes = Math.floor(currentSeconds / 60); const seconds = currentSeconds % 60; currentTimeEl.textContent = `${minutes}:${seconds.toString().padStart(2, '0')}`; // If wasn't playing, start playing if (!isPlaying) { isPlaying = true; playPauseIcon.textContent = "⏸️"; audioWave.style.display = 'flex'; startProgressAnimation(); } }); function startProgressAnimation() { clearInterval(progressInterval); progressInterval = setInterval(() => { if (currentProgress >= 100) { clearInterval(progressInterval); // Simulate next track setTimeout(() => { const activeTrack = document.querySelector('.track-item.active'); const nextTrack = activeTrack.nextElementSibling || document.querySelector('.track-item'); if (nextTrack) { nextTrack.click(); } }, 1000); return; } currentProgress += 0.1; progressBar.style.width = `${currentProgress}%`; // Update time const totalSeconds = 270; // 4:30 in seconds const currentSeconds = Math.floor((currentProgress / 100) * totalSeconds); const minutes = Math.floor(currentSeconds / 60); const seconds = currentSeconds % 60; currentTimeEl.textContent = `${minutes}:${seconds.toString().padStart(2, '0')}`; }, 100); } function stopProgressAnimation() { clearInterval(progressInterval); } function resetAndStartProgress() { currentProgress = 0; progressBar.style.width = '0%'; startProgressAnimation(); } // Initialize progress animation if (isPlaying) { startProgressAnimation(); } // Next/Previous buttons document.getElementById('nextBtn').addEventListener('click', function(e) { const activeTrack = document.querySelector('.track-item.active'); const nextTrack = activeTrack.nextElementSibling || document.querySelector('.track-item'); if (nextTrack) { nextTrack.click(); } createRippleEffect(e); }); document.getElementById('prevBtn').addEventListener('click', function(e) { const activeTrack = document.querySelector('.track-item.active'); const allTracks = document.querySelectorAll('.track-item'); const index = Array.from(allTracks).indexOf(activeTrack); const prevTrack = index > 0 ? allTracks[index - 1] : allTracks[allTracks.length - 1]; if (prevTrack) { prevTrack.click(); } createRippleEffect(e); }); // Shuffle and repeat buttons document.querySelector('.shuffle-btn').addEventListener('click', function() { this.classList.toggle('active'); }); document.querySelector('.repeat-btn').addEventListener('click', function() { this.classList.toggle('active'); }); // Volume slider functionality const volumeSlider = document.querySelector('.volume-slider'); const volumeLevel = document.querySelector('.volume-level'); volumeSlider.addEventListener('click', function(e) { const rect = this.getBoundingClientRect(); const clickPosition = e.clientX - rect.left; const volumeWidth = (clickPosition / rect.width) * 100; volumeLevel.style.width = `${volumeWidth}%`; }); }); </script> </body> </html>
<html> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <style> * { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Inter', sans-serif; } :root { --bg-primary: #0d1117; --glass-bg: rgba(255, 255, 255, 0.07); --glass-border: rgba(255, 255, 255, 0.1); --glass-shadow: rgba(0, 0, 0, 0.3); --text-primary: rgba(255, 255, 255, 0.9); --text-secondary: rgba(255, 255, 255, 0.7); --accent: #6c5ce7; --accent-light: #a29bfe; --accent-transparent: rgba(108, 92, 231, 0.15); --success: #00b894; --price-tag: rgba(0, 184, 148, 0.15); } body { display: flex; justify-content: center; align-items: center; min-height: 100vh; background: linear-gradient(135deg, #0d1117 0%, #171f2e 100%); padding: 20px; overflow-x: hidden; perspective: 1000px; } .product-container { display: flex; flex-wrap: wrap; justify-content: center; gap: 25px; max-width: 700px; perspective: 1000px; } .product-card { position: relative; width: 320px; height: 420px; background: var(--glass-bg); border: 1px solid var(--glass-border); border-radius: 24px; backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); box-shadow: 0 8px 32px var(--glass-shadow); overflow: hidden; transition: all 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275); transform-style: preserve-3d; cursor: pointer; } .product-card:hover { transform: translateY(-10px) rotateX(5deg) rotateY(-5deg); box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5); border-color: var(--accent-light); } .card-content { padding: 20px; height: 100%; display: flex; flex-direction: column; justify-content: space-between; z-index: 1; position: relative; } .card-bg { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: radial-gradient(circle at top right, var(--accent-transparent), transparent 70%); opacity: 0; transition: opacity 0.6s ease; } .product-card:hover .card-bg { opacity: 1; } .image-container { position: relative; height: 220px; display: flex; justify-content: center; align-items: center; transition: transform 0.5s ease; transform-style: preserve-3d; } .product-card:hover .image-container { transform: translateZ(30px); } .product-image { max-width: 100%; max-height: 100%; object-fit: contain; filter: drop-shadow(0 10px 15px rgba(0, 0, 0, 0.3)); transition: all 0.5s ease; transform-style: preserve-3d; } .product-card:hover .product-image { transform: scale(1.1) translateZ(20px); } .product-badge { position: absolute; top: 15px; left: 0; background: var(--accent); color: white; padding: 6px 15px 6px 10px; font-size: 12px; font-weight: 600; border-radius: 0 20px 20px 0; box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2); transform: translateX(-100%); transition: transform 0.3s 0.1s ease-out; } .product-card:hover .product-badge { transform: translateX(0); } .product-info { transform: translateZ(10px); transition: transform 0.5s ease; } .product-card:hover .product-info { transform: translateZ(40px); } .product-category { font-size: 12px; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 8px; font-weight: 500; } .product-title { font-size: 18px; color: var(--text-primary); font-weight: 600; margin-bottom: 12px; } .product-description { font-size: 14px; color: var(--text-secondary); line-height: 1.4; margin-bottom: 15px; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; } .product-meta { display: flex; justify-content: space-between; align-items: center; margin-top: 10px; } .price-container { display: flex; flex-direction: column; } .product-price { display: inline-block; font-size: 22px; font-weight: 700; color: var(--text-primary); background: var(--price-tag); padding: 5px 12px; border-radius: 12px; transition: all 0.3s ease; } .product-card:hover .product-price { background: var(--accent-transparent); color: var(--accent-light); transform: scale(1.05); } .original-price { color: var(--text-secondary); font-size: 14px; text-decoration: line-through; margin-bottom: 5px; } .btn-add { background: transparent; border: 1px solid var(--accent); color: var(--accent); border-radius: 50px; padding: 10px 20px; font-size: 14px; font-weight: 600; cursor: pointer; transition: all 0.3s ease; display: flex; align-items: center; gap: 6px; overflow: hidden; position: relative; } .btn-bg { position: absolute; top: 0; left: 0; width: 0; height: 100%; background: var(--accent); transition: width 0.3s ease; z-index: -1; } .btn-add:hover .btn-bg { width: 100%; } .btn-add:hover { color: white; } .btn-add svg { transition: transform 0.3s ease; } .btn-add:hover svg { transform: rotate(90deg); } .rating { display: flex; align-items: center; margin-top: 10px; } .stars { display: flex; margin-right: 8px; } .star { color: #ffd700; font-size: 14px; margin-right: 2px; } .reviews { font-size: 12px; color: var(--text-secondary); } .features { display: flex; gap: 10px; margin-top: 5px; } .feature { font-size: 11px; background: rgba(255, 255, 255, 0.1); color: var(--text-secondary); padding: 4px 8px; border-radius: 50px; white-space: nowrap; } .success-message { position: absolute; bottom: -50px; left: 0; width: 100%; background: var(--success); color: white; text-align: center; padding: 12px; font-weight: 500; border-radius: 0 0 24px 24px; transition: transform 0.3s ease; transform: translateY(0); z-index: 0; } .show-success .success-message { transform: translateY(-50px); } @media (max-width: 680px) { .product-container { padding: 10px; } .product-card { width: 300px; height: 400px; } .image-container { height: 180px; } .product-title { font-size: 16px; } .product-price { font-size: 20px; } } @media (max-width: 340px) { .product-card { width: 100%; height: 380px; } .product-meta { flex-direction: column; align-items: flex-start; gap: 15px; } .btn-add { width: 100%; justify-content: center; } } </style> </head> <body> <div class="product-container"> <div class="product-card" id="card1"> <div class="card-bg"></div> <div class="card-content"> <div class="product-badge">NEW RELEASE</div> <div class="image-container"> <img src="https://assets.codepen.io/t-1/headphones.webp" alt="Sony WH-1000XM5" class="product-image"> </div> <div class="product-info"> <div class="product-category">Premium Audio</div> <h2 class="product-title">Sony WH-1000XM5 Wireless Headphones</h2> <p class="product-description">Industry-leading noise cancellation with 30-hour battery life and Hi-Res Audio certification.</p> <div class="features"> <span class="feature">ANC</span> <span class="feature">Bluetooth 5.2</span> <span class="feature">30h Battery</span> </div> <div class="rating"> <div class="stars"> <span class="star">★</span> <span class="star">★</span> <span class="star">★</span> <span class="star">★</span> <span class="star">★</span> </div> <span class="reviews">132 reviews</span> </div> <div class="product-meta"> <div class="price-container"> <span class="original-price">$399.99</span> <span class="product-price">$349.99</span> </div> <button class="btn-add"> <div class="btn-bg"></div> <span>Add to Cart</span> <svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"> <line x1="12" y1="5" x2="12" y2="19"></line> <line x1="5" y1="12" x2="19" y2="12"></line> </svg> </button> </div> </div> </div> <div class="success-message">Added to your cart!</div> </div> <div class="product-card" id="card2"> <div class="card-bg"></div> <div class="card-content"> <div class="product-badge">BEST SELLER</div> <div class="image-container"> <img src="https://assets.codepen.io/t-1/watch.webp" alt="Apple Watch Ultra" class="product-image"> </div> <div class="product-info"> <div class="product-category">Wearable Tech</div> <h2 class="product-title">Apple Watch Ultra Titanium Case</h2> <p class="product-description">Built for endurance, exploration, and adventure with precision GPS and 36-hour battery life.</p> <div class="features"> <span class="feature">Titanium</span> <span class="feature">Water Resistant</span> <span class="feature">GPS</span> </div> <div class="rating"> <div class="stars"> <span class="star">★</span> <span class="star">★</span> <span class="star">★</span> <span class="star">★</span> <span class="star">★</span> </div> <span class="reviews">214 reviews</span> </div> <div class="product-meta"> <div class="price-container"> <span class="original-price">$799.99</span> <span class="product-price">$749.99</span> </div> <button class="btn-add"> <div class="btn-bg"></div> <span>Add to Cart</span> <svg width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"> <line x1="12" y1="5" x2="12" y2="19"></line> <line x1="5" y1="12" x2="19" y2="12"></line> </svg> </button> </div> </div> </div> <div class="success-message">Added to your cart!</div> </div> </div> <script> document.addEventListener('DOMContentLoaded', function() { // Setup 3D tilt effect for cards const cards = document.querySelectorAll('.product-card'); cards.forEach(card => { card.addEventListener('mousemove', handleTilt); card.addEventListener('mouseleave', resetTilt); const addButton = card.querySelector('.btn-add'); addButton.addEventListener('click', (e) => { e.stopPropagation(); showSuccessMessage(card); }); }); function handleTilt(e) { const card = this; const cardRect = card.getBoundingClientRect(); const cardWidth = cardRect.width; const cardHeight = cardRect.height; const centerX = cardRect.left + cardWidth / 2; const centerY = cardRect.top + cardHeight / 2; const mouseX = e.clientX - centerX; const mouseY = e.clientY - centerY; const rotateY = (mouseX / (cardWidth / 2)) * 5; // Max 5 degrees const rotateX = -(mouseY / (cardHeight / 2)) * 5; // Max 5 degrees card.style.transform = `perspective(1000px) rotateX(${rotateX}deg) rotateY(${rotateY}deg)`; // Move image with cursor for parallax effect const image = card.querySelector('.image-container'); const moveX = (mouseX / cardWidth) * 15; // Max 15px const moveY = (mouseY / cardHeight) * 15; // Max 15px image.style.transform = `translateZ(30px) translate(${moveX}px, ${moveY}px)`; // Adjust highlight based on cursor position const cardBg = card.querySelector('.card-bg'); cardBg.style.background = `radial-gradient(circle at ${e.offsetX}px ${e.offsetY}px, var(--accent-transparent), transparent 70%)`; } function resetTilt() { this.style.transform = ''; const image = this.querySelector('.image-container'); image.style.transform = 'translateZ(30px)'; } function showSuccessMessage(card) { card.classList.add('show-success'); // Create ripple effect const button = card.querySelector('.btn-add'); const buttonRect = button.getBoundingClientRect(); const ripple = document.createElement('span'); ripple.style.position = 'absolute'; ripple.style.width = '5px'; ripple.style.height = '5px'; ripple.style.borderRadius = '50%'; ripple.style.backgroundColor = 'rgba(255, 255, 255, 0.7)'; ripple.style.transform = 'scale(0)'; ripple.style.animation = 'ripple 0.6s linear'; ripple.style.left = '50%'; ripple.style.top = '50%'; button.appendChild(ripple); setTimeout(() => { button.removeChild(ripple); card.classList.remove('show-success'); }, 2000); } // Add CSS animation const style = document.createElement('style'); style.textContent = ` @keyframes ripple { to { transform: scale(20); opacity: 0; } } @keyframes pulse { 0% { transform: scale(1); } 50% { transform: scale(1.05); } 100% { transform: scale(1); } } `; document.head.appendChild(style); // Simulate a staggered entrance for cards cards.forEach((card, index) => { card.style.opacity = '0'; card.style.transform = 'translateY(50px)'; card.style.transition = 'opacity 0.6s ease, transform 0.6s ease'; setTimeout(() => { card.style.opacity = '1'; card.style.transform = 'translateY(0)'; }, 100 * (index + 1)); }); }); </script> </body> </html>
<html> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Vitality Pulse - Health Dashboard</title> <style> :root { --primary: #5664d2; --primary-light: rgba(86, 100, 210, 0.3); --secondary: #ff7eb3; --secondary-light: rgba(255, 126, 179, 0.3); --tertiary: #42cabd; --tertiary-light: rgba(66, 202, 189, 0.3); --dark: #2d325a; --light: #f8f9fc; --border-radius: 16px; --font-main: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; } * { margin: 0; padding: 0; box-sizing: border-box; font-family: var(--font-main); } body { background: linear-gradient(135deg, #e0e6ff 0%, #f2f6ff 100%); color: var(--dark); width: 100%; height: 100vh; display: flex; justify-content: center; align-items: center; overflow-x: hidden; } /* Glassmorphism styles */ .glass { background: rgba(255, 255, 255, 0.6); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-radius: var(--border-radius); border: 1px solid rgba(255, 255, 255, 0.18); box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.07); } .container { width: 700px; height: 700px; padding: 20px; display: grid; grid-template-rows: auto 1fr auto; gap: 20px; overflow-y: auto; position: relative; } /* Header section */ header { display: flex; justify-content: space-between; align-items: center; padding: 0 10px; } .logo { display: flex; align-items: center; font-weight: 700; font-size: 1.5rem; color: var(--primary); } .logo-icon { width: 32px; height: 32px; margin-right: 8px; background: var(--primary); border-radius: 50%; display: flex; align-items: center; justify-content: center; color: white; } .profile { display: flex; align-items: center; gap: 10px; cursor: pointer; padding: 8px 16px; border-radius: 30px; transition: all 0.3s ease; } .profile:hover { background: rgba(255, 255, 255, 0.8); } .profile-img { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; border: 2px solid var(--primary); } /* Main content */ main { display: grid; grid-template-columns: 2fr 1fr; gap: 20px; overflow-y: auto; } .dashboard { display: grid; grid-template-rows: auto 1fr; gap: 20px; } /* Quick stats */ .quick-stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 15px; } .stat-card { padding: 20px; display: flex; flex-direction: column; position: relative; overflow: hidden; transition: transform 0.3s ease, box-shadow 0.3s ease; } .stat-card:hover { transform: translateY(-5px); box-shadow: 0 12px 32px 0 rgba(31, 38, 135, 0.1); } .stat-card::before { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 5px; background: var(--primary); transform: scaleX(0); transform-origin: left; transition: transform 0.3s ease; } .stat-card:hover::before { transform: scaleX(1); } .stat-card.steps::before { background: var(--primary); } .stat-card.heart-rate::before { background: var(--secondary); } .stat-card.sleep::before { background: var(--tertiary); } .stat-card.calories::before { background: #ffa800; } .stat-label { font-size: 14px; margin-bottom: 5px; color: var(--dark); opacity: 0.8; display: flex; align-items: center; gap: 5px; } .stat-value { font-size: 24px; font-weight: 700; margin-bottom: 5px; display: flex; align-items: baseline; } .stat-unit { font-size: 14px; font-weight: 400; margin-left: 5px; opacity: 0.7; } .stat-context { font-size: 12px; color: var(--dark); opacity: 0.6; } .trend-up { color: #4CAF50; } .trend-down { color: #f44336; } /* Charts */ .activity-chart { padding: 20px; height: 100%; display: flex; flex-direction: column; } .chart-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 15px; } .chart-title { font-size: 18px; font-weight: 600; } .chart-controls { display: flex; gap: 10px; } .chart-btn { padding: 6px 12px; background: transparent; border: 1px solid rgba(86, 100, 210, 0.3); border-radius: 20px; font-size: 12px; cursor: pointer; transition: all 0.2s ease; } .chart-btn.active { background: var(--primary); color: white; border-color: var(--primary); } .chart-btn:hover:not(.active) { background: rgba(86, 100, 210, 0.1); } .chart-container { flex: 1; display: flex; align-items: center; justify-content: center; position: relative; } canvas { width: 100% !important; height: 100% !important; } /* Right sidebar */ .sidebar { display: flex; flex-direction: column; gap: 20px; } .health-score { padding: 20px; display: flex; flex-direction: column; align-items: center; justify-content: center; position: relative; } .score-title { font-size: 16px; font-weight: 600; margin-bottom: 15px; } .score-circle { width: 120px; height: 120px; position: relative; display: flex; align-items: center; justify-content: center; margin-bottom: 15px; } .score-value { font-size: 36px; font-weight: 700; color: var(--primary); } .health-insights { padding: 20px; } .insight-title { font-size: 16px; font-weight: 600; margin-bottom: 15px; } .insight-list { display: flex; flex-direction: column; gap: 12px; } .insight-item { display: flex; gap: 10px; padding: 12px; border-radius: 12px; background: rgba(255, 255, 255, 0.5); transition: all 0.2s ease; cursor: pointer; } .insight-item:hover { background: rgba(255, 255, 255, 0.9); transform: translateX(5px); } .insight-icon { width: 30px; height: 30px; border-radius: 8px; display: flex; align-items: center; justify-content: center; font-size: 16px; flex-shrink: 0; } .insight-icon.hydration { background: var(--tertiary-light); color: var(--tertiary); } .insight-icon.sleep { background: var(--primary-light); color: var(--primary); } .insight-icon.stress { background: var(--secondary-light); color: var(--secondary); } .insight-content { display: flex; flex-direction: column; } .insight-label { font-size: 14px; font-weight: 600; margin-bottom: 2px; } .insight-desc { font-size: 12px; opacity: 0.7; } /* Goals section */ .goals-section { padding: 20px; } .goals-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 15px; } .goals-title { font-size: 18px; font-weight: 600; } .add-goal-btn { background: var(--primary); color: white; border: none; border-radius: 20px; padding: 6px 12px; font-size: 13px; cursor: pointer; transition: all 0.2s ease; display: flex; align-items: center; gap: 5px; } .add-goal-btn:hover { background: #4854c8; transform: translateY(-2px); } .goals-container { display: flex; gap: 15px; overflow-x: auto; padding-bottom: 5px; scroll-behavior: smooth; } .goals-container::-webkit-scrollbar { height: 4px; } .goals-container::-webkit-scrollbar-thumb { background: rgba(86, 100, 210, 0.3); border-radius: 10px; } .goal-card { min-width: 160px; padding: 15px; border-radius: 12px; display: flex; flex-direction: column; gap: 10px; transition: all 0.2s ease; cursor: pointer; background: rgba(255, 255, 255, 0.4); backdrop-filter: blur(8px); border: 1px solid rgba(255, 255, 255, 0.18); } .goal-card:hover { background: rgba(255, 255, 255, 0.8); transform: translateY(-5px); } .goal-icon { width: 40px; height: 40px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 18px; color: white; background: var(--primary); } .goal-card:nth-child(2) .goal-icon { background: var(--secondary); } .goal-card:nth-child(3) .goal-icon { background: var(--tertiary); } .goal-card:nth-child(4) .goal-icon { background: #ffa800; } .goal-info { display: flex; flex-direction: column; gap: 5px; } .goal-name { font-size: 14px; font-weight: 600; } .goal-progress { font-size: 12px; color: var(--dark); opacity: 0.7; } .progress-bar { width: 100%; height: 6px; background: rgba(0, 0, 0, 0.1); border-radius: 3px; overflow: hidden; } .progress-fill { height: 100%; background: var(--primary); border-radius: 3px; width: 0; transition: width 1s ease; } .goal-card:nth-child(2) .progress-fill { background: var(--secondary); } .goal-card:nth-child(3) .progress-fill { background: var(--tertiary); } .goal-card:nth-child(4) .progress-fill { background: #ffa800; } /* Animate elements in */ @keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } } .stat-card, .activity-chart, .health-score, .health-insights, .goal-card { animation: fadeIn 0.5s ease forwards; opacity: 0; } .stat-card:nth-child(1) { animation-delay: 0.1s; } .stat-card:nth-child(2) { animation-delay: 0.2s; } .stat-card:nth-child(3) { animation-delay: 0.3s; } .stat-card:nth-child(4) { animation-delay: 0.4s; } .activity-chart { animation-delay: 0.5s; } .health-score { animation-delay: 0.6s; } .health-insights { animation-delay: 0.7s; } .goal-card:nth-child(1) { animation-delay: 0.8s; } .goal-card:nth-child(2) { animation-delay: 0.9s; } .goal-card:nth-child(3) { animation-delay: 1.0s; } .goal-card:nth-child(4) { animation-delay: 1.1s; } /* Pulse animation for health score */ @keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(86, 100, 210, 0.4); } 70% { box-shadow: 0 0 0 15px rgba(86, 100, 210, 0); } 100% { box-shadow: 0 0 0 0 rgba(86, 100, 210, 0); } } .score-circle { animation: pulse 2s infinite; } /* Responsive adjustments */ @media (max-width: 700px) { .container { width: 100%; height: 100%; padding: 15px; } main { grid-template-columns: 1fr; } .quick-stats { grid-template-columns: 1fr 1fr; gap: 10px; } .stat-card { padding: 15px; } .stat-value { font-size: 20px; } .goal-card { min-width: 140px; } } @media (max-width: 500px) { .quick-stats { grid-template-columns: 1fr; } } /* Floating badge */ .floating-badge { position: absolute; bottom: 30px; right: 30px; background: var(--primary); color: white; padding: 10px 20px; border-radius: 25px; font-weight: 600; box-shadow: 0 5px 15px rgba(86, 100, 210, 0.3); cursor: pointer; transition: all 0.3s ease; z-index: 10; display: flex; align-items: center; gap: 8px; } .floating-badge:hover { transform: translateY(-5px) scale(1.05); box-shadow: 0 8px 20px rgba(86, 100, 210, 0.4); } .badge-pulse { width: 10px; height: 10px; background: #4CAF50; border-radius: 50%; position: relative; } .badge-pulse::after { content: ''; position: absolute; width: 100%; height: 100%; background: #4CAF50; border-radius: 50%; animation: ripple 1.5s infinite; } @keyframes ripple { 0% { transform: scale(1); opacity: 0.8; } 100% { transform: scale(3); opacity: 0; } } /* Loading state */ .loading-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: rgba(255, 255, 255, 0.9); display: flex; justify-content: center; align-items: center; z-index: 1000; backdrop-filter: blur(5px); } .loader { width: 50px; height: 50px; border: 5px solid var(--primary-light); border-radius: 50%; border-top: 5px solid var(--primary); animation: spin 1s linear infinite; } @keyframes spin { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } } /* Modal for insights */ .modal { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0, 0, 0, 0.5); display: flex; justify-content: center; align-items: center; z-index: 1000; opacity: 0; visibility: hidden; transition: all 0.3s ease; } .modal.active { opacity: 1; visibility: visible; } .modal-content { background: white; padding: 30px; border-radius: 16px; width: 90%; max-width: 500px; transform: translateY(20px); transition: all 0.3s ease; max-height: 80vh; overflow-y: auto; } .modal.active .modal-content { transform: translateY(0); } .modal-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; padding-bottom: 15px; border-bottom: 1px solid rgba(0, 0, 0, 0.1); } .modal-title { font-size: 20px; font-weight: 600; } .modal-close { background: none; border: none; font-size: 24px; cursor: pointer; color: var(--dark); opacity: 0.7; transition: all 0.2s ease; } .modal-close:hover { opacity: 1; transform: scale(1.1); } .modal-body { margin-bottom: 20px; } .modal-actions { display: flex; justify-content: flex-end; gap: 10px; } .modal-btn { padding: 10px 20px; border-radius: 30px; font-weight: 500; cursor: pointer; transition: all 0.2s ease; } .modal-btn.primary { background: var(--primary); color: white; border: none; } .modal-btn.secondary { background: transparent; border: 1px solid var(--primary); color: var(--primary); } .modal-btn:hover { transform: translateY(-2px); box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1); } /* Circle progress */ .circle-progress { position: relative; width: 120px; height: 120px; } .circle-bg { fill: none; stroke: rgba(86, 100, 210, 0.2); stroke-width: 8; } .circle-progress-value { fill: none; stroke: var(--primary); stroke-width: 8; stroke-linecap: round; transition: stroke-dashoffset 1s ease; } .circle-text { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); text-align: center; } </style> </head> <body> <div class="container glass"> <header> <div class="logo"> <div class="logo-icon"> <i>♥</i> </div> Vitality Pulse </div> <div class="profile"> <img src="https://randomuser.me/api/portraits/women/44.jpg" alt="Profile" class="profile-img"> <span>Sarah</span> </div> </header> <main> <div class="dashboard"> <div class="quick-stats"> <div class="stat-card steps glass"> <div class="stat-label"> <i>👣</i> Daily Steps </div> <div class="stat-value"> 8,342 <span class="stat-unit">steps</span> </div> <div class="stat-context"> <span class="trend-up">↑12%</span> from yesterday </div> </div> <div class="stat-card heart-rate glass"> <div class="stat-label"> <i>❤️</i> Heart Rate </div> <div class="stat-value"> 72 <span class="stat-unit">bpm</span> </div> <div class="stat-context"> Resting | Within normal range </div> </div> <div class="stat-card sleep glass"> <div class="stat-label"> <i>😴</i> Sleep Quality </div> <div class="stat-value"> 7.2 <span class="stat-unit">hrs</span> </div> <div class="stat-context"> <span class="trend-up">↑5%</span> better than last week </div> </div> <div class="stat-card calories glass"> <div class="stat-label"> <i>🔥</i> Calories </div> <div class="stat-value"> 1,842 <span class="stat-unit">kcal</span> </div> <div class="stat-context"> 68% of daily target </div> </div> </div> <div class="activity-chart glass"> <div class="chart-header"> <div class="chart-title">Activity Trends</div> <div class="chart-controls"> <button class="chart-btn active" data-period="week">Week</button> <button class="chart-btn" data-period="month">Month</button> <button class="chart-btn" data-period="year">Year</button> </div> </div> <div class="chart-container"> <canvas id="activityChart"></canvas> </div> </div> </div> <div class="sidebar"> <div class="health-score glass"> <div class="score-title">Your Health Score</div> <div class="score-circle"> <svg class="circle-progress" viewBox="0 0 36 36"> <path class="circle-bg" d="M18 2.0845 a 15.9155 15.9155 0 0 1 0 31.831 a 15.9155 15.9155 0 0 1 0 -31.831" /> <path class="circle-progress-value" d="M18 2.0845 a 15.9155 15.9155 0 0 1 0 31.831 a 15.9155 15.9155 0 0 1 0 -31.831" stroke-dasharray="100, 100" stroke-dashoffset="25" /> </svg> <div class="circle-text"> <div class="score-value">85</div> </div> </div> <div>Above average for your age group</div> </div> <div class="health-insights glass"> <div class="insight-title">Today's Insights</div> <div class="insight-list"> <div class="insight-item" data-insight="hydration"> <div class="insight-icon hydration">💧</div> <div class="insight-content"> <div class="insight-label">Hydration Level</div> <div class="insight-desc">You're slightly dehydrated. Aim for 3 more glasses today.</div> </div> </div> <div class="insight-item" data-insight="sleep"> <div class="insight-icon sleep">😴</div> <div class="insight-content"> <div class="insight-label">Sleep Quality</div> <div class="insight-desc">Deep sleep improved by 18% last night. Keep it up!</div> </div> </div> <div class="insight-item" data-insight="stress"> <div class="insight-icon stress">🧘</div> <div class="insight-content"> <div class="insight-label">Stress Levels</div> <div class="insight-desc">Your morning stress readings are 22% lower this week.</div> </div> </div> </div> </div> </div> </main> <div class="goals-section glass"> <div class="goals-header"> <div class="goals-title">Your Active Goals</div> <button class="add-goal-btn"> <span>+</span> New Goal </button> </div> <div class="goals-container"> <div class="goal-card"> <div class="goal-icon">🏃</div> <div class="goal-info"> <div class="goal-name">10K Steps Daily</div> <div class="goal-progress">83% complete</div> <div class="progress-bar"> <div class="progress-fill" style="width: 83%"></div> </div> </div> </div> <div class="goal-card"> <div class="goal-icon">💤</div> <div class="goal-info"> <div class="goal-name">8hr Sleep</div> <div class="goal-progress">90% complete</div> <div class="progress-bar"> <div class="progress-fill" style="width: 90%"></div> </div> </div> </div> <div class="goal-card"> <div class="goal-icon">💧</div> <div class="goal-info"> <div class="goal-name">2L Water Daily</div> <div class="goal-progress">65% complete</div> <div class="progress-bar"> <div class="progress-fill" style="width: 65%"></div> </div> </div> </div> <div class="goal-card"> <div class="goal-icon">🏋️</div> <div class="goal-info"> <div class="goal-name">Strength Training</div> <div class="goal-progress">45% complete</div> <div class="progress-bar"> <div class="progress-fill" style="width: 45%"></div> </div> </div> </div> </div> </div> <div class="floating-badge"> <div class="badge-pulse"></div> <span>Live Monitoring</span> </div> <div class="loading-overlay" id="loadingOverlay"> <div class="loader"></div> </div> <div class="modal" id="insightModal"> <div class="modal-content glass"> <div class="modal-header"> <h3 class="modal-title" id="modalTitle">Insight Details</h3> <button class="modal-close">×</button> </div> <div class="modal-body" id="modalBody"> <!-- Content will be loaded dynamically --> </div> <div class="modal-actions"> <button class="modal-btn secondary modal-close-btn">Close</button> <button class="modal-btn primary">Take Action</button> </div> </div> </div> </div> <script src="https://cdn.jsdelivr.net/npm/chart.js"></script> <script> document.addEventListener('DOMContentLoaded', function() { // Remove loading overlay after 1.5 seconds setTimeout(() => { const loadingOverlay = document.getElementById('loadingOverlay'); loadingOverlay.style.opacity = '0'; setTimeout(() => { loadingOverlay.style.display = 'none'; }, 500); }, 1500); // Initialize Chart.js const ctx = document.getElementById('activityChart').getContext('2d'); // Create gradient for chart const gradient = ctx.createLinearGradient(0, 0, 0, 400); gradient.addColorStop(0, 'rgba(86, 100, 210, 0.6)'); gradient.addColorStop(1, 'rgba(86, 100, 210, 0.1)'); // Weekly data const weeklyData = { labels: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'], datasets: [{ label: 'Steps', data: [7500, 9200, 8400, 6800, 9500, 10200, 8342], backgroundColor: gradient, borderColor: '#5664d2', borderWidth: 2, tension: 0.4, pointBackgroundColor: '#ffffff', pointBorderColor: '#5664d2', pointBorderWidth: 2, pointRadius: 4, pointHoverRadius: 6, fill: true }] }; // Monthly data const monthlyData = { labels: ['Week 1', 'Week 2', 'Week 3', 'Week 4'], datasets: [{ label: 'Steps', data: [52000, 58000, 61000, 56000], backgroundColor: gradient, borderColor: '#5664d2', borderWidth: 2, tension: 0.4, pointBackgroundColor: '#ffffff', pointBorderColor: '#5664d2', pointBorderWidth: 2, pointRadius: 4, pointHoverRadius: 6, fill: true }] }; // Yearly data const yearlyData = { labels: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'], datasets: [{ label: 'Steps', data: [220000, 240000, 310000, 280000, 320000, 350000, 420000, 380000, 360000, 400000, 385000, 420000], backgroundColor: gradient, borderColor: '#5664d2', borderWidth: 2, tension: 0.4, pointBackgroundColor: '#ffffff', pointBorderColor: '#5664d2', pointBorderWidth: 2, pointRadius: 4, pointHoverRadius: 6, fill: true }] }; // Chart options const chartOptions = { responsive: true, maintainAspectRatio: false, scales: { x: { grid: { display: false } }, y: { beginAtZero: true, grid: { color: 'rgba(0, 0, 0, 0.05)' } } }, plugins: { legend: { display: false }, tooltip: { backgroundColor: 'rgba(255, 255, 255, 0.8)', titleColor: '#2d325a', bodyColor: '#2d325a', borderColor: 'rgba(86, 100, 210, 0.2)', borderWidth: 1, caretSize: 6, cornerRadius: 8, padding: 12, displayColors: false } }, interaction: { intersect: false, mode: 'index' } }; // Create chart const activityChart = new Chart(ctx, { type: 'line', data: weeklyData, options: chartOptions }); // Chart period controls const chartBtns = document.querySelectorAll('.chart-btn'); chartBtns.forEach(btn => { btn.addEventListener('click', function() { chartBtns.forEach(b => b.classList.remove('active')); this.classList.add('active'); const period = this.dataset.period; switch(period) { case 'week': activityChart.data = weeklyData; break; case 'month': activityChart.data = monthlyData; break; case 'year': activityChart.data = yearlyData; break; } activityChart.update(); }); }); // Animate progress bars setTimeout(() => { const progressBars = document.querySelectorAll('.progress-fill'); progressBars.forEach(bar => { const width = bar.style.width; bar.style.width = '0'; setTimeout(() => { bar.style.width = width; }, 100); }); }, 1000); // Handle insight modal const insightItems = document.querySelectorAll('.insight-item'); const modal = document.getElementById('insightModal'); const modalTitle = document.getElementById('modalTitle'); const modalBody = document.getElementById('modalBody'); const closeButtons = document.querySelectorAll('.modal-close, .modal-close-btn'); const insightContent = { 'hydration': { title: 'Hydration Analysis', content: ` <p>Your hydration levels are currently at 65% of the optimal range. Based on your activity level and weight, we recommend drinking 3 more glasses of water before the end of the day.</p> <br> <p><strong>Why this matters:</strong> Proper hydration improves cognitive function, physical performance, and helps regulate body temperature.</p> <br> <p><strong>Recommended action:</strong> Set hourly
<html> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Glow Consulting - Business Solutions</title> <style> * { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Inter', sans-serif; } @import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap'); body { background-color: #0a0e17; color: #fff; height: 100vh; overflow-x: hidden; position: relative; } .container { width: 100%; max-width: 700px; margin: 0 auto; padding: 0 20px; height: 100%; position: relative; z-index: 10; } .background { position: absolute; top: 0; left: 0; width: 100%; height: 100%; overflow: hidden; z-index: 1; } .bg-shape { position: absolute; border-radius: 50%; filter: blur(70px); } .bg-shape-1 { top: -150px; right: -100px; width: 500px; height: 500px; background: linear-gradient(135deg, rgba(83, 92, 236, 0.6), rgba(129, 52, 175, 0.4)); } .bg-shape-2 { bottom: -200px; left: -150px; width: 600px; height: 600px; background: linear-gradient(135deg, rgba(36, 148, 233, 0.4), rgba(56, 207, 171, 0.3)); } .header { display: flex; justify-content: space-between; align-items: center; padding: 20px 0; } .logo { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 22px; letter-spacing: -0.5px; } .logo span { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: linear-gradient(135deg, #535cec, #8134af); } .nav-links { display: flex; gap: 20px; } .nav-links a { color: rgba(255, 255, 255, 0.7); text-decoration: none; font-size: 14px; font-weight: 500; transition: all 0.3s ease; } .nav-links a:hover { color: #fff; } .hero { display: flex; flex-direction: column; justify-content: center; height: calc(100% - 80px); padding-bottom: 40px; } .hero-content { background: rgba(255, 255, 255, 0.05); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); border-radius: 24px; border: 1px solid rgba(255, 255, 255, 0.08); padding: 40px; position: relative; overflow: hidden; transform: translateY(40px); opacity: 0; animation: slideUp 0.8s forwards; box-shadow: 0 20px 80px rgba(0, 0, 0, 0.2); } .hero-content::before { content: ''; position: absolute; top: -50%; left: -50%; width: 200%; height: 200%; background: radial-gradient(circle, rgba(255, 255, 255, 0.03) 0%, transparent 70%); transform: rotate(45deg); pointer-events: none; } .hero-subtitle { font-size: 14px; text-transform: uppercase; letter-spacing: 3px; margin-bottom: 16px; background: linear-gradient(90deg, #535cec, #8134af); -webkit-background-clip: text; -webkit-text-fill-color: transparent; display: inline-block; position: relative; } .hero-subtitle::after { content: ''; position: absolute; bottom: -8px; left: 0; width: 40px; height: 2px; background: linear-gradient(90deg, #535cec, #8134af); } .hero-title { font-size: 42px; font-weight: 700; line-height: 1.2; margin-bottom: 20px; letter-spacing: -1px; } .hero-title span { background: linear-gradient(90deg, #fff 0%, rgba(255, 255, 255, 0.7) 100%); -webkit-background-clip: text; -webkit-text-fill-color: transparent; } .hero-description { font-size: 16px; line-height: 1.6; color: rgba(255, 255, 255, 0.7); margin-bottom: 30px; max-width: 90%; } .hero-buttons { display: flex; gap: 16px; align-items: center; } .btn { padding: 12px 24px; border-radius: 12px; font-weight: 600; font-size: 15px; cursor: pointer; transition: all 0.3s ease; position: relative; overflow: hidden; } .btn-primary { background: linear-gradient(135deg, #535cec, #8134af); color: white; border: none; box-shadow: 0 6px 15px rgba(83, 92, 236, 0.2); } .btn-primary::before { content: ''; position: absolute; top: 0; left: -100%; width: 100%; height: 100%; background: linear-gradient(90deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0)); transition: all 0.4s ease; } .btn-primary:hover::before { left: 100%; } .btn-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(83, 92, 236, 0.3); } .btn-secondary { background: rgba(255, 255, 255, 0.05); color: white; border: 1px solid rgba(255, 255, 255, 0.1); } .btn-secondary:hover { background: rgba(255, 255, 255, 0.1); transform: translateY(-2px); } .stats { display: flex; margin-top: 40px; gap: 30px; } .stat-item { background: rgba(255, 255, 255, 0.03); border-radius: 16px; padding: 16px; flex: 1; backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border: 1px solid rgba(255, 255, 255, 0.05); transition: all 0.3s ease; cursor: default; } .stat-item:hover { transform: translateY(-4px); background: rgba(255, 255, 255, 0.05); } .stat-number { font-size: 24px; font-weight: 700; margin-bottom: 6px; background: linear-gradient(90deg, #fff, rgba(255, 255, 255, 0.7)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; } .stat-text { font-size: 14px; color: rgba(255, 255, 255, 0.6); } .floating-elements { position: absolute; top: 0; left: 0; width: 100%; height: 100%; pointer-events: none; z-index: 2; } .floating-element { position: absolute; border-radius: 50%; background: rgba(255, 255, 255, 0.03); border: 1px solid rgba(255, 255, 255, 0.05); } .element-1 { width: 80px; height: 80px; top: 15%; left: 10%; animation: float 8s ease-in-out infinite; } .element-2 { width: 120px; height: 120px; bottom: 20%; right: 12%; animation: float 10s ease-in-out infinite; } .element-3 { width: 50px; height: 50px; top: 70%; left: 20%; animation: float 7s ease-in-out infinite; } @keyframes float { 0% { transform: translateY(0) rotate(0deg); } 50% { transform: translateY(-20px) rotate(5deg); } 100% { transform: translateY(0) rotate(0deg); } } @keyframes slideUp { to { transform: translateY(0); opacity: 1; } } /* Responsive styles */ @media (max-width: 700px) { .hero-title { font-size: 32px; } .hero-content { padding: 30px; } .hero-description { max-width: 100%; } .hero-buttons { flex-direction: column; align-items: flex-start; gap: 12px; } .btn { width: 100%; text-align: center; } .stats { flex-direction: column; gap: 12px; } } </style> </head> <body> <div class="background"> <div class="bg-shape bg-shape-1"></div> <div class="bg-shape bg-shape-2"></div> </div> <div class="floating-elements"> <div class="floating-element element-1"></div> <div class="floating-element element-2"></div> <div class="floating-element element-3"></div> </div> <div class="container"> <header class="header"> <div class="logo"> <span></span>Glow </div> <nav class="nav-links"> <a href="#">Solutions</a> <a href="#">About</a> <a href="#">Clients</a> <a href="#">Contact</a> </nav> </header> <section class="hero"> <div class="hero-content" id="hero-content"> <p class="hero-subtitle">Elevate Your Business</p> <h1 class="hero-title">Transform insights into <span>strategic growth</span></h1> <p class="hero-description">We analyze your market position and develop tailored strategies that deliver measurable results. Our transparent process ensures you're involved every step of the way.</p> <div class="hero-buttons"> <button class="btn btn-primary">Get Started</button> <button class="btn btn-secondary">View Case Studies</button> </div> <div class="stats"> <div class="stat-item"> <div class="stat-number">94%</div> <div class="stat-text">Client retention rate</div> </div> <div class="stat-item"> <div class="stat-number">127+</div> <div class="stat-text">Growth strategies deployed</div> </div> <div class="stat-item"> <div class="stat-number">$1.8B</div> <div class="stat-text">Revenue generated</div> </div> </div> </div> </section> </div> <script> document.addEventListener('DOMContentLoaded', function() { const heroContent = document.getElementById('hero-content'); // Parallax effect on scroll window.addEventListener('scroll', function() { const scrollValue = window.scrollY; if (scrollValue < 400) { // Limit the effect to avoid excessive movement heroContent.style.transform = `translateY(${scrollValue * 0.05}px)`; } }); // Mouse move effect document.addEventListener('mousemove', function(e) { const xPos = (e.clientX / window.innerWidth - 0.5) * 20; const yPos = (e.clientY / window.innerHeight - 0.5) * 20; heroContent.style.transition = 'transform 0.3s ease-out'; heroContent.style.transform = `perspective(1000px) rotateY(${xPos * 0.03}deg) rotateX(${-yPos * 0.03}deg)`; setTimeout(() => { heroContent.style.transition = ''; }, 300); }); // Hover effects for buttons const buttons = document.querySelectorAll('.btn'); buttons.forEach(btn => { btn.addEventListener('mouseenter', function() { this.style.transform = 'translateY(-2px)'; }); btn.addEventListener('mouseleave', function() { this.style.transform = 'translateY(0)'; }); }); // Prevent actual form submission const allButtons = document.querySelectorAll('button'); allButtons.forEach(button => { button.addEventListener('click', function(e) { e.preventDefault(); // Add a visual feedback this.style.transform = 'scale(0.95)'; setTimeout(() => { this.style.transform = ''; }, 150); }); }); }); </script> </body> </html>
<html> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>NeoArcade Gaming Overlay</title> <style> * { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; } :root { --primary-neon: #00f7ff; --secondary-neon: #ff00f7; --accent-neon: #f7ff00; --dark-bg: #0a0a15; --glass-bg: rgba(20, 20, 40, 0.6); --glass-border: rgba(255, 255, 255, 0.1); } body { width: 100%; height: 100vh; display: flex; justify-content: center; align-items: center; background: var(--dark-bg); overflow: hidden; perspective: 1000px; } .game-background { position: absolute; width: 100%; height: 100%; background: url('https://images.unsplash.com/photo-1518770660439-4636190af475?ixlib=rb-4.0.3') no-repeat center center; background-size: cover; filter: blur(5px) brightness(0.3); z-index: -2; } .grid-overlay { position: absolute; width: 100%; height: 100%; background: linear-gradient(rgba(0, 247, 255, 0.03) 1px, transparent 1px), linear-gradient(90deg, rgba(0, 247, 255, 0.03) 1px, transparent 1px); background-size: 30px 30px; z-index: -1; } .container { width: 700px; height: 700px; display: grid; grid-template-rows: auto 1fr auto; position: relative; overflow: hidden; } .header { display: flex; justify-content: space-between; align-items: center; padding: 1rem; position: relative; } .game-title { font-size: 2rem; font-weight: 800; color: white; text-transform: uppercase; text-shadow: 0 0 10px var(--primary-neon), 0 0 20px var(--primary-neon); letter-spacing: 2px; position: relative; } .game-title::after { content: ''; position: absolute; left: 0; bottom: -5px; width: 100%; height: 2px; background: linear-gradient(90deg, transparent, var(--primary-neon), transparent); } .player-info { display: flex; align-items: center; gap: 15px; } .avatar { width: 45px; height: 45px; border-radius: 50%; background: linear-gradient(135deg, var(--primary-neon), var(--secondary-neon)); position: relative; display: flex; justify-content: center; align-items: center; font-weight: bold; color: var(--dark-bg); box-shadow: 0 0 10px var(--secondary-neon); } .level-indicator { background: var(--glass-bg); backdrop-filter: blur(10px); border: 1px solid var(--glass-border); border-radius: 10px; padding: 0.5rem 1rem; color: white; font-size: 0.9rem; display: flex; flex-direction: column; gap: 5px; } .xp-bar { width: 100%; height: 6px; background: rgba(255, 255, 255, 0.1); border-radius: 3px; overflow: hidden; } .xp-progress { height: 100%; width: 65%; background: linear-gradient(90deg, var(--primary-neon), var(--secondary-neon)); box-shadow: 0 0 8px var(--primary-neon); } .main-content { display: grid; grid-template-columns: 2fr 1fr; gap: 20px; padding: 1rem; position: relative; } .stats-panel, .inventory-panel, .mission-panel, .weapon-select, .chat-panel { background: var(--glass-bg); backdrop-filter: blur(15px); border: 1px solid var(--glass-border); border-radius: 15px; padding: 1.5rem; box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2); position: relative; overflow: hidden; transition: all 0.3s ease; } .stats-panel::before, .inventory-panel::before, .mission-panel::before, .weapon-select::before, .chat-panel::before { content: ''; position: absolute; top: -50%; left: -50%; width: 200%; height: 200%; background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%); opacity: 0; transform: rotate(30deg); transition: opacity 0.3s ease; pointer-events: none; } .stats-panel:hover::before, .inventory-panel:hover::before, .mission-panel:hover::before, .weapon-select:hover::before, .chat-panel:hover::before { opacity: 1; } .panel-grid { display: grid; grid-template-rows: 1fr 1fr; gap: 20px; height: 100%; } .panel-header { color: white; margin-bottom: 15px; display: flex; justify-content: space-between; align-items: center; } .panel-title { font-size: 1.2rem; font-weight: 600; position: relative; display: inline-block; } .panel-title::after { content: ''; position: absolute; left: 0; bottom: -5px; width: 30px; height: 2px; background: var(--secondary-neon); box-shadow: 0 0 5px var(--secondary-neon); } .stats-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; } .stat-item { color: white; display: flex; flex-direction: column; gap: 5px; } .stat-name { font-size: 0.9rem; opacity: 0.7; } .stat-value { font-size: 1.8rem; font-weight: 700; background: linear-gradient(90deg, var(--primary-neon), var(--secondary-neon)); -webkit-background-clip: text; background-clip: text; color: transparent; text-shadow: 0 0 5px rgba(0, 247, 255, 0.3); } .inventory-slots { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; } .inventory-slot { aspect-ratio: 1/1; background: rgba(0, 0, 0, 0.3); border: 1px solid var(--glass-border); border-radius: 10px; display: flex; justify-content: center; align-items: center; position: relative; cursor: pointer; transition: all 0.2s ease; } .inventory-slot:hover { transform: translateY(-5px); box-shadow: 0 5px 15px rgba(0, 247, 255, 0.2); border-color: var(--primary-neon); } .slot-item { width: 70%; height: 70%; background-size: contain; background-repeat: no-repeat; background-position: center; } .mission-list { display: flex; flex-direction: column; gap: 15px; overflow-y: auto; max-height: 200px; margin-top: 10px; padding-right: 10px; } .mission-item { background: rgba(0, 0, 0, 0.2); border-left: 3px solid var(--accent-neon); padding: 12px; border-radius: 0 8px 8px 0; color: white; transition: all 0.2s ease; cursor: pointer; } .mission-item:hover { background: rgba(247, 255, 0, 0.1); transform: translateX(5px); } .mission-title { font-weight: 600; margin-bottom: 5px; } .mission-desc { font-size: 0.85rem; opacity: 0.7; } .weapons { display: flex; gap: 15px; overflow-x: auto; padding-bottom: 10px; margin-top: 10px; } .weapon-item { background: rgba(0, 0, 0, 0.3); border: 1px solid var(--glass-border); border-radius: 10px; min-width: 80px; padding: 15px 10px; display: flex; flex-direction: column; align-items: center; gap: 10px; cursor: pointer; transition: all 0.2s ease; } .weapon-item.active { border-color: var(--primary-neon); box-shadow: 0 0 15px rgba(0, 247, 255, 0.3); } .weapon-item:hover { transform: translateY(-5px); } .weapon-icon { width: 40px; height: 40px; background-size: contain; background-repeat: no-repeat; background-position: center; } .weapon-name { color: white; font-size: 0.8rem; text-align: center; } .chat-messages { display: flex; flex-direction: column; gap: 10px; overflow-y: auto; max-height: 120px; margin-bottom: 15px; } .chat-message { color: white; padding: 8px 12px; border-radius: 10px; max-width: 80%; position: relative; } .team-message { background: rgba(0, 247, 255, 0.15); align-self: flex-start; border-bottom-left-radius: 0; } .enemy-message { background: rgba(255, 0, 247, 0.15); align-self: flex-end; border-bottom-right-radius: 0; } .message-sender { font-weight: 600; font-size: 0.8rem; margin-bottom: 3px; } .chat-input { display: flex; gap: 10px; } .chat-input input { flex: 1; background: rgba(0, 0, 0, 0.3); border: 1px solid var(--glass-border); border-radius: 20px; padding: 10px 15px; color: white; outline: none; transition: all 0.2s ease; } .chat-input input:focus { border-color: var(--primary-neon); box-shadow: 0 0 10px rgba(0, 247, 255, 0.3); } .send-btn { background: linear-gradient(135deg, var(--primary-neon), var(--secondary-neon)); border: none; border-radius: 50%; width: 40px; height: 40px; display: flex; justify-content: center; align-items: center; cursor: pointer; box-shadow: 0 0 10px rgba(0, 247, 255, 0.5); transition: all 0.2s ease; } .send-btn:hover { transform: rotate(45deg); } .bottom-nav { padding: 1rem; display: flex; justify-content: space-between; align-items: center; } .action-buttons { display: flex; gap: 15px; } .action-btn { background: var(--glass-bg); backdrop-filter: blur(10px); border: 1px solid var(--glass-border); border-radius: 10px; padding: 10px 20px; color: white; font-weight: 600; cursor: pointer; display: flex; align-items: center; gap: 8px; transition: all 0.2s ease; position: relative; overflow: hidden; } .action-btn::before { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent); transform: translateX(-100%); } .action-btn:hover::before { transform: translateX(100%); transition: transform 0.8s ease; } .primary-btn { background: linear-gradient(135deg, var(--primary-neon), var(--secondary-neon)); border: none; box-shadow: 0 0 15px rgba(0, 247, 255, 0.5); } .primary-btn:hover { transform: scale(1.05); box-shadow: 0 0 20px rgba(0, 247, 255, 0.7); } .mini-map { width: 80px; height: 80px; background: rgba(0, 0, 0, 0.5); border: 1px solid var(--primary-neon); border-radius: 50%; box-shadow: 0 0 15px rgba(0, 247, 255, 0.3); position: relative; overflow: hidden; } .map-content { width: 100%; height: 100%; background: radial-gradient(circle, transparent 50%, rgba(0, 247, 255, 0.2) 51%, rgba(0, 247, 255, 0.1) 100%), linear-gradient(rgba(0, 247, 255, 0.1) 1px, transparent 1px), linear-gradient(90deg, rgba(0, 247, 255, 0.1) 1px, transparent 1px); background-size: 100%, 10px 10px, 10px 10px; transform: rotate(45deg); } .player-dot { position: absolute; width: 8px; height: 8px; background: var(--primary-neon); border-radius: 50%; top: 50%; left: 50%; transform: translate(-50%, -50%); box-shadow: 0 0 5px var(--primary-neon); } .enemy-dot { position: absolute; width: 5px; height: 5px; background: var(--secondary-neon); border-radius: 50%; box-shadow: 0 0 3px var(--secondary-neon); } .pulse { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 50px; height: 50px; border-radius: 50%; background: transparent; border: 2px solid var(--primary-neon); animation: pulse 2s infinite; } @keyframes pulse { 0% { transform: translate(-50%, -50%) scale(0); opacity: 1; } 100% { transform: translate(-50%, -50%) scale(1); opacity: 0; } } .notification { position: absolute; top: 80px; right: 20px; background: var(--glass-bg); backdrop-filter: blur(10px); border-left: 3px solid var(--accent-neon); padding: 15px 20px; border-radius: 0 10px 10px 0; color: white; transform: translateX(150%); opacity: 0; transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275); z-index: 10; max-width: 300px; } .notification.active { transform: translateX(0); opacity: 1; } .notification-title { font-weight: 600; margin-bottom: 5px; color: var(--accent-neon); } .notification-close { position: absolute; top: 10px; right: 10px; cursor: pointer; color: rgba(255, 255, 255, 0.5); transition: color 0.2s ease; } .notification-close:hover { color: white; } .weapon-ammo { position: absolute; bottom: 15px; right: 15px; background: var(--glass-bg); backdrop-filter: blur(10px); border: 1px solid var(--glass-border); border-radius: 20px; padding: 5px 15px; color: white; font-weight: 600; font-size: 1.2rem; } @media (max-width: 700px) { .container { width: 100%; height: 100%; } .main-content { grid-template-columns: 1fr; } .panel-grid { grid-template-rows: auto auto; } .stats-grid { grid-template-columns: repeat(2, 1fr); } .action-buttons { flex-wrap: wrap; } .game-title { font-size: 1.5rem; } } /* Custom scrollbar */ ::-webkit-scrollbar { width: 5px; height: 5px; } ::-webkit-scrollbar-track { background: rgba(0, 0, 0, 0.2); border-radius: 10px; } ::-webkit-scrollbar-thumb { background: linear-gradient(var(--primary-neon), var(--secondary-neon)); border-radius: 10px; } </style> </head> <body> <div class="game-background"></div> <div class="grid-overlay"></div> <div class="container"> <div class="header"> <div class="game-title">NeoArcade</div> <div class="player-info"> <div class="level-indicator"> <span>Level 42</span> <div class="xp-bar"> <div class="xp-progress"></div> </div> </div> <div class="avatar">VR</div> </div> </div> <div class="main-content"> <div class="stats-panel"> <div class="panel-header"> <div class="panel-title">Player Stats</div> </div> <div class="stats-grid"> <div class="stat-item"> <div class="stat-name">Accuracy</div> <div class="stat-value">78%</div> </div> <div class="stat-item"> <div class="stat-name">K/D Ratio</div> <div class="stat-value">3.2</div> </div> <div class="stat-item"> <div class="stat-name">Win Rate</div> <div class="stat-value">64%</div> </div> <div class="stat-item"> <div class="stat-name">Headshots</div> <div class="stat-value">426</div> </div> </div> <div class="panel-header" style="margin-top: 30px;"> <div class="panel-title">Current Match</div> </div> <div class="stats-grid"> <div class="stat-item"> <div class="stat-name">Score</div> <div class="stat-value">2380</div> </div> <div class="stat-item"> <div class="stat-name">Eliminations</div> <div class="stat-value">15</div> </div> <div class="stat-item"> <div class="stat-name">Assists</div> <div class="stat-value">8</div> </div> <div class="stat-item"> <div class="stat-name">Time Left</div> <div class="stat-value">4:32</div> </div> </div> </div> <div class="panel-grid"> <div class="inventory-panel"> <div class="panel-header"> <div class="panel-title">Inventory</div> </div> <div class="inventory-slots"> <div class="inventory-slot"> <div class="slot-item" style="background-image: url('data:image/svg+xml;utf8,<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" fill=\"%2300f7ff\"><path d=\"M12,15.5A3.5,3.5 0 0,1 8.5,12A3.5,3.5 0 0,1 12,8.5A3.5,3.5 0 0,1 15.5,12A3.5,3.5 0 0,1 12,15.5M19.43,12.97C19.47,12.65 19.5,12.33 19.5,12C19.5,11.67 19.47,11.34 19.43,11L21.54,9.37C21.73,9.22 21.78,8.95 21.66,8.73L19.66,5.27C19.54,5.05 19.27,4.96 19.05,5.05L16.56,6.05C16.04,5.66 15.5,5.32 14.87,5.07L14.5,2.42C14.46,2.18 14.25,2 14,2H10C9.75,2 9.54,2.18 9.5,2.42L9.13,5.07C8.5,5.32 7.96,5.66 7.44,6.05L4.95,5.05C4.73,4.96 4.46,5.05 4.34,5.27L2.34,8.73C2.21,8.95 2.27,9.22 2.46,9.37L4.57,11C4.53,11.34 4.5,11.67 4.5,12C4.5,12.33 4.53,12.65 4.57,12.97L2.46,14.63C2.27,14.78 2.21,15.05 2.34,15.27L4.34,18.73C4.46,18.95 4.73,19.03 4.95,18.95L7.44,17.94C7.96,18.34 8.5,18.68 9.13,18.93L9.5,21.58C9.54,21.82 9.75,22 10,22H14C14.25,22 14.46,21.82 14.5,21.58L14.87,18.93C15.5,18.67 16.04,18.34 16.56,17.94L19.05,18.95C19.27,19.03 19.54,18.95 19.66,18.73L21.66,15.27C21.78,15.05 21.73,14.78 21.54,14.63L19.43,12.97Z\" /></svg>');"></div> </div> <div class="inventory-slot"> <div class="slot-item" style="background-image: url('data:image/svg+xml;utf8,<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" fill=\"%2300f7ff\"><path d=\"M17,4V2H7V4H2V11C2,12.1 2.9,13 4,13H7.1C7.5,14.96 9.04,16.5 11,16.9V19.08C8,19.54 8,22 8,22H16C16,22 16,19.54 13,19.08V16.9C14.96,16.5 16.5,14.96 16.9,13H20C21.1,13 22,12.1 22,11V4H17M4,11V6H7V11L4,11M20,11L17,11V6H20L20,11Z\" /></svg>');"></div> </div> <div class="inventory-slot"> <div class="slot-item" style="background-image: url('data:image/svg+xml;utf8,<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" fill=\"%2300f7ff\"><path d=\"M12,2A10,10 0 0,1 22,12A10,10 0 0,1 12,22A10,10 0 0,1 2,12A10,10 0 0,1 12,2M12,4A8,8 0 0,0 4,12C4,14.4 5,16.5 6.7,18C8.1,16.7 10,16 12,16C14,16 15.9,16.7 17.3,18C19,16.5 20,14.4 20,12A8,8 0 0,0 12,4M14,5.89C15.8,6.8 17,8.7 17,11C17,13.3 15.8,15.2 14,16.11V5.89M12,6A2,2 0 0,1 14,8A2,2 0 0,1 12,10A2,2 0 0,1 10,8A2,2 0 0,1 12,6Z\" /></svg>');"></div> </div> <div class="inventory-slot"> <div class="slot-item" style="background-image: url('data:image/svg+xml;utf8,<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" fill=\"%2300f7ff\"><path d=\"M4,2H20A2,2 0 0,1 22,4V16A2,2 0 0,1 20,18H16L12,22L8,18H4A2,2 0 0,1 2,16V4A2,2 0 0,1 4,2M4,4V16H8.83L12,19.17L15.17,16H20V4H4M6,7H18V9H6V7M6,11H16V13H6V11Z\" /></svg>');"></div> </div> <div class="inventory-slot"> <div class="slot-item" style="background-image: url('data:image/svg+xml;utf8,<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" fill=\"%23ff00f7\"><path d=\"M11,15H13V17H11V15M11,7H13V13H11V7M12,2C6.47,2 2,6.5 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M12,20A8,8 0 0,1 4,12A8,8 0 0,1 12,4A8,8 0 0,1 20,12A8,8 0 0,1 12,20Z\" /></svg>');"></div> </div> <div class="inventory-slot"> <div class="slot-item" style="background-image: url('data:image/svg+xml;utf8,<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" fill=\"%23ff00f7\"><path d=\"M12,11A1,1 0 0,0 11,12A1,1 0 0,0 12,13A1,1 0 0,0 13,12A1,1 0 0,0 12,11M10.5,15C9.67,15 9,14.33 9,13.5V10.5C9,9.67 9.67,9 10.5,9H13.5C14.33,9 15,9.67 15,10.5V13.5C15,14.33 14.33,15 13.5,15H10.5M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M12,20A8,8 0 0,1 4,12A8,8 0 0,1 12,4A8,8 0 0,1 20,12A8,8 0 0,1 12,20Z\" /></svg>');"></div> </div> <div class="inventory-slot"> <div class="slot-item" style="background-image: url('data:image/svg+xml;utf8,<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" fill=\"%23f7ff00\"><path d=\"M12,5.5A3.5,3.5 0 0,1 15.5,9A3.5,3.5 0 0,1 12,12.5A3.5,3.5 0 0,1 8.5,9A3.5,3.5 0 0,1 12,5.5M5,8C5.56,8 6.08,8.15 6.53,8.42C6.38,9.85 6.8,11.27 7.66,12.38C7.16,13.34 6.16,14 5,14A3,3 0 0,1 2,11A3,3 0 0,1 5,8M19,8A3,3 0 0,1 22,11A3,3 0 0,1 19,14C17.84,14 16.84,13.34 16.34,12.38C17.2,11.27 17.62,9.85 17.47,8.42C17.92,8.15 18.44,8 19,8M5.5,18.25C5.5,16.18 8.41,14.5 12,14.5C15.59,14.5 18.5,16.18 18.5,18.25V20H5.5V18.25M0,20V18.5C0,17.11 1.89,15.94 4.45,15.6C3.86,16.28 3.5,17.22 3.5,18.25V20H0M24,20H20.5V18.25C20.5,17.22 20.14,16.28 19.55,15.6C22.11,15.94 24,17.11 24,18.5V20Z\" /></svg>');"></div> </div> <div class="inventory-slot"> <div class="slot-item" style="background-image: url('data:image/svg+xml;utf8,<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" fill=\"%23f7ff00\"><path d=\"M2,10.96C1.5,10.68 1.35,10.07 1.63,9.59L3.13,7C3.24,6.8 3.41,6.66 3.6,6.58L11.43,2.18C11.59,2.06 11.79,2 12,2C12.21,2 12.41,2.06 12.57,2.18L20.47,6.62C20.66,6.72 20.82,6.88 20.91,7.08L22.36,9.6C22.64,10.08 22.47,10.69 22,10.96L21,11.54V16.5C21,16.88 20.79,17.21 20.47,17.38L12.57,21.82C12.41,21.94 12.21,22 12,22C11.79,22 11.59,21.94 11.43,21.82L3.53,17.38C3.21,17.21 3,16.88 3,16.5V10.96C2.7,11.13 2.32,11.14 2,10.96M12,4.15V4.15L12,10.85V10.85L17.96,7.5L12,4.15M5,15.91L11,19.29V12.58L5,9.21V15.91M19,15.91V12.69L14,15.59C13.67,15.77 13.3,15.76 13,15.6V19.29L19,15.91M13.85,13.36L20.13,9.73L19.55,8.72L13.27,12.35L13.85,13.36Z\" /></svg>');"></div> </div> </div> </div> <div class="mission-panel"> <div class="panel-header"> <div class="panel-title">Active Missions</div> </div> <div class="mission-list"> <div class="mission-item"> <div class="mission-title">Data Breach</div> <div class="mission-desc">Infiltrate Neutron Corp's server room and extract classified data (3/5)</div> </div> <div class="mission-item"> <div class="mission-title">Ghost Protocol</div> <div class="mission-desc">Eliminate 10 enemies without being detected (7/10)</div> </div> <div class="mission-item"> <div class="mission-title">Resource Hunt</div> <div class="mission-desc">Collect 15 quantum fragments from the reactor zone (12/15)</div> </div> </div> </div> </div> </div> <div class="bottom-nav"> <div class="action-buttons"> <div class="action-btn" id="abilities-btn"> Abilities </div> <div class="action-btn" id="team-btn"> Team </div> <div class="action-btn primary-btn" id="deploy-btn"> Deploy </div> </div> <div class="mini-map"> <div class="map-content"></div> <div class="player-dot"></div> <div class="enemy-dot" style="top: 30%; left: 70%;"></div> <div class="enemy-dot" style="top: 65%; left: 25%;"></div> <div class="enemy-dot" style="top: 40%; left: 20%;"></div> <div class="pulse"></div> </div> </div> <div class="weapon-select" style="position: absolute; bottom: 70px; left: 20px; width: 400px; max-width: 90%;"> <div class="panel-header"> <div class="panel-title">Loadout</div> </div>
<html> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Productivity App Sidebar</title> <style> :root { --primary-color: #6C63FF; --secondary-color: #F2F5FF; --text-color: #333; --text-light: rgba(255, 255, 255, 0.9); --glass-bg: rgba(255, 255, 255, 0.15); --glass-border: rgba(255, 255, 255, 0.2); --glass-shadow: rgba(31, 38, 135, 0.15); --glass-blur: 8px; --transition-speed: 0.3s; --border-radius: 14px; } * { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif; } body { height: 700px; width: 700px; display: flex; background-image: linear-gradient(135deg, #8BC6EC 0%, #9599E2 100%); overflow: hidden; font-size: 14px; } .app-container { display: flex; width: 100%; height: 100%; position: relative; } .sidebar { width: 260px; height: 100%; backdrop-filter: blur(var(--glass-blur)); -webkit-backdrop-filter: blur(var(--glass-blur)); background: var(--glass-bg); border-right: 1px solid var(--glass-border); box-shadow: 0 8px 32px 0 var(--glass-shadow); display: flex; flex-direction: column; transition: all var(--transition-speed) ease; z-index: 10; padding: 20px 0; } .sidebar-header { padding: 0 24px 20px; border-bottom: 1px solid rgba(255, 255, 255, 0.1); margin-bottom: 20px; } .logo-container { display: flex; align-items: center; gap: 12px; } .logo { height: 32px; width: 32px; background: var(--primary-color); border-radius: 8px; display: flex; align-items: center; justify-content: center; } .logo svg { width: 20px; height: 20px; fill: white; } .app-name { font-weight: 700; font-size: 18px; color: var(--text-light); letter-spacing: -0.5px; } .sidebar-content { flex: 1; overflow-y: auto; padding: 0 16px; } .sidebar-section { margin-bottom: 28px; } .section-title { text-transform: uppercase; font-size: 11px; font-weight: 600; color: rgba(255, 255, 255, 0.6); margin-bottom: 12px; padding-left: 10px; letter-spacing: 1px; } .nav-item { display: flex; align-items: center; padding: 10px; border-radius: var(--border-radius); margin-bottom: 4px; cursor: pointer; transition: all var(--transition-speed) ease; color: var(--text-light); position: relative; overflow: hidden; } .nav-item:hover { background: rgba(255, 255, 255, 0.1); } .nav-item.active { background: rgba(255, 255, 255, 0.2); font-weight: 500; } .nav-item.active::before { content: ""; position: absolute; left: 0; top: 0; height: 100%; width: 3px; background: var(--primary-color); border-radius: 0 4px 4px 0; } .nav-item-icon { width: 20px; height: 20px; margin-right: 12px; opacity: 0.9; display: flex; align-items: center; justify-content: center; } .nav-item-text { font-size: 14px; font-weight: 400; flex: 1; } .badge { background: var(--primary-color); color: white; font-size: 11px; font-weight: 600; padding: 2px 8px; border-radius: 10px; display: flex; align-items: center; justify-content: center; } .progress-section { margin-top: auto; padding: 0 16px 10px; } .progress-card { background: rgba(255, 255, 255, 0.08); padding: 16px; border-radius: var(--border-radius); margin-bottom: 20px; } .progress-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; } .progress-title { font-weight: 600; color: var(--text-light); } .progress-percent { font-size: 13px; color: var(--primary-color); font-weight: 600; } .progress-bar-bg { height: 6px; background: rgba(255, 255, 255, 0.1); border-radius: 10px; overflow: hidden; } .progress-bar-fill { height: 100%; background: var(--primary-color); border-radius: 10px; transition: width 1s ease-in-out; } .sidebar-footer { padding: 20px 16px 0; border-top: 1px solid rgba(255, 255, 255, 0.1); } .user-profile { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: var(--border-radius); cursor: pointer; transition: all var(--transition-speed) ease; } .user-profile:hover { background: rgba(255, 255, 255, 0.1); } .avatar { width: 36px; height: 36px; border-radius: 50%; background: linear-gradient(45deg, #FF9A8B, #FF6A88); display: flex; align-items: center; justify-content: center; font-weight: 600; color: white; font-size: 16px; } .user-info { flex: 1; } .user-name { font-weight: 600; color: var(--text-light); margin-bottom: 2px; } .user-title { font-size: 12px; color: rgba(255, 255, 255, 0.6); } .main-content { flex: 1; padding: 30px; position: relative; opacity: 0.5; background-image: url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 18c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm48 25c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm-43-7c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm63 31c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM34 90c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm56-76c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM12 86c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm28-65c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm23-11c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-6 60c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm29 22c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zM32 63c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm57-13c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-9-21c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM60 91c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM35 41c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM12 60c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2z' fill='rgba(255,255,255,.05)' fill-rule='evenodd'/%3E%3C/svg%3E"); } .toggle-sidebar { position: absolute; top: 20px; right: -15px; width: 30px; height: 30px; background: var(--glass-bg); border: 1px solid var(--glass-border); border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; backdrop-filter: blur(var(--glass-blur)); -webkit-backdrop-filter: blur(var(--glass-blur)); z-index: 20; transition: all var(--transition-speed) ease; box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); } .toggle-sidebar:hover { background: rgba(255, 255, 255, 0.25); } .toggle-sidebar svg { width: 14px; height: 14px; fill: var(--text-light); } .toggle-icon-open, .toggle-icon-close { transition: opacity 0.3s ease, transform 0.3s ease; } .sidebar.collapsed { width: 80px; } .sidebar.collapsed .app-name, .sidebar.collapsed .section-title, .sidebar.collapsed .nav-item-text, .sidebar.collapsed .badge, .sidebar.collapsed .progress-card, .sidebar.collapsed .user-info { opacity: 0; visibility: hidden; } .sidebar.collapsed .nav-item { justify-content: center; } .sidebar.collapsed .nav-item-icon { margin-right: 0; } .sidebar.collapsed .logo-container { justify-content: center; } .sidebar.collapsed .user-profile { justify-content: center; } /* Animations */ @keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } } .nav-item { animation: fadeIn 0.5s ease forwards; opacity: 0; } .nav-item:nth-child(1) { animation-delay: 0.1s; } .nav-item:nth-child(2) { animation-delay: 0.2s; } .nav-item:nth-child(3) { animation-delay: 0.3s; } .nav-item:nth-child(4) { animation-delay: 0.4s; } .nav-item:nth-child(5) { animation-delay: 0.5s; } .nav-item:nth-child(6) { animation-delay: 0.6s; } /* Ripple effect */ .nav-item { position: relative; overflow: hidden; } .ripple { position: absolute; background: rgba(255, 255, 255, 0.3); border-radius: 50%; transform: scale(0); animation: ripple 0.6s linear; pointer-events: none; } @keyframes ripple { to { transform: scale(4); opacity: 0; } } /* Mobile responsiveness */ @media (max-width: 768px) { .sidebar { position: absolute; left: 0; transform: translateX(-100%); } .sidebar.show { transform: translateX(0); } .toggle-sidebar { right: -40px; } } /* Custom scrollbar */ .sidebar-content::-webkit-scrollbar { width: 4px; } .sidebar-content::-webkit-scrollbar-track { background: transparent; } .sidebar-content::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.2); border-radius: 10px; } .sidebar-content::-webkit-scrollbar-thumb:hover { background: rgba(255, 255, 255, 0.3); } /* Hover animations */ .nav-item { transition: all 0.3s ease; } .nav-item:hover .nav-item-icon { transform: scale(1.1); color: var(--primary-color); } .nav-item.active .nav-item-icon { color: var(--primary-color); } /* Task glow effect */ .nav-item.active.highlight { box-shadow: 0 0 15px rgba(108, 99, 255, 0.5); } /* Tooltip styles */ .tooltip { position: absolute; left: 90px; background: rgba(0, 0, 0, 0.8); color: white; padding: 6px 12px; border-radius: 6px; font-size: 12px; opacity: 0; visibility: hidden; transition: all 0.3s ease; white-space: nowrap; z-index: 100; } .sidebar.collapsed .nav-item:hover .tooltip { opacity: 1; visibility: visible; } </style> </head> <body> <div class="app-container"> <div class="sidebar"> <div class="sidebar-header"> <div class="logo-container"> <div class="logo"> <svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"> <path d="M19 3H5C3.89 3 3 3.89 3 5V19C3 20.11 3.89 21 5 21H19C20.11 21 21 20.11 21 19V5C21 3.89 20.11 3 19 3ZM10 17L5 12L6.41 10.59L10 14.17L17.59 6.58L19 8L10 17Z" fill="white"/> </svg> </div> <span class="app-name">FlowTask</span> </div> </div> <div class="toggle-sidebar"> <div class="toggle-icon-open"> <svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"> <path d="M15.41 7.41L14 6L8 12L14 18L15.41 16.59L10.83 12L15.41 7.41Z"/> </svg> </div> <div class="toggle-icon-close" style="display: none;"> <svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"> <path d="M10 6L8.59 7.41L13.17 12L8.59 16.59L10 18L16 12L10 6Z"/> </svg> </div> </div> <div class="sidebar-content"> <div class="sidebar-section"> <div class="section-title">Menu</div> <div class="nav-item active" data-tooltip="Dashboard"> <div class="nav-item-icon"> <svg viewBox="0 0 24 24" fill="currentColor" xmlns="http://www.w3.org/2000/svg"> <path d="M4 13H10C10.55 13 11 12.55 11 12V4C11 3.45 10.55 3 10 3H4C3.45 3 3 3.45 3 4V12C3 12.55 3.45 13 4 13ZM4 21H10C10.55 21 11 20.55 11 20V16C11 15.45 10.55 15 10 15H4C3.45 15 3 15.45 3 16V20C3 20.55 3.45 21 4 21ZM14 21H20C20.55 21 21 20.55 21 20V12C21 11.45 20.55 11 20 11H14C13.45 11 13 11.45 13 12V20C13 20.55 13.45 21 14 21ZM13 4V8C13 8.55 13.45 9 14 9H20C20.55 9 21 8.55 21 8V4C21 3.45 20.55 3 20 3H14C13.45 3 13 3.45 13 4Z"/> </svg> </div> <span class="nav-item-text">Dashboard</span> <span class="tooltip">Dashboard</span> </div> <div class="nav-item" data-tooltip="My Tasks"> <div class="nav-item-icon"> <svg viewBox="0 0 24 24" fill="currentColor" xmlns="http://www.w3.org/2000/svg"> <path d="M19 3H5C3.89 3 3 3.89 3 5V19C3 20.11 3.89 21 5 21H19C20.11 21 21 20.11 21 19V5C21 3.89 20.11 3 19 3ZM10 17L5 12L6.41 10.59L10 14.17L17.59 6.58L19 8L10 17Z"/> </svg> </div> <span class="nav-item-text">My Tasks</span> <div class="badge">5</div> <span class="tooltip">My Tasks</span> </div> <div class="nav-item" data-tooltip="Calendar"> <div class="nav-item-icon"> <svg viewBox="0 0 24 24" fill="currentColor" xmlns="http://www.w3.org/2000/svg"> <path d="M19 4H18V2H16V4H8V2H6V4H5C3.89 4 3.01 4.9 3.01 6L3 20C3 21.1 3.89 22 5 22H19C20.1 22 21 21.1 21 20V6C21 4.9 20.1 4 19 4ZM19 20H5V10H19V20ZM19 8H5V6H19V8ZM9 14H7V12H9V14ZM13 14H11V12H13V14ZM17 14H15V12H17V14ZM9 18H7V16H9V18ZM13 18H11V16H13V18ZM17 18H15V16H17V18Z"/> </svg> </div> <span class="nav-item-text">Calendar</span> <span class="tooltip">Calendar</span> </div> </div> <div class="sidebar-section"> <div class="section-title">Projects</div> <div class="nav-item highlight" data-tooltip="Website Redesign"> <div class="nav-item-icon"> <svg viewBox="0 0 24 24" fill="currentColor" xmlns="http://www.w3.org/2000/svg"> <path d="M9.4 16.6L4.8 12L9.4 7.4L8 6L2 12L8 18L9.4 16.6ZM14.6 16.6L19.2 12L14.6 7.4L16 6L22 12L16 18L14.6 16.6Z"/> </svg> </div> <span class="nav-item-text">Website Redesign</span> <span class="tooltip">Website Redesign</span> </div> <div class="nav-item" data-tooltip="Q4 Marketing"> <div class="nav-item-icon"> <svg viewBox="0 0 24 24" fill="currentColor" xmlns="http://www.w3.org/2000/svg"> <path d="M11.8 10.9C9.53 10.31 8.8 9.7 8.8 8.75C8.8 7.66 9.81 6.9 11.5 6.9C13.28 6.9 13.94 7.75 14 9H16.21C16.14 7.28 15.09 5.7 13 5.19V3H10V5.16C8.06 5.58 6.5 6.84 6.5 8.77C6.5 11.08 8.41 12.23 11.2 12.9C13.7 13.5 14.2 14.38 14.2 15.31C14.2 16 13.71 17.1 11.5 17.1C9.44 17.1 8.63 16.18 8.5 15H6.32C6.44 17.19 8.08 18.42 10 18.83V21H13V18.85C14.95 18.48 16.5 17.35 16.5 15.3C16.5 12.46 14.07 11.49 11.8 10.9Z"/> </svg> </div> <span class="nav-item-text">Q4 Marketing</span> <span class="tooltip">Q4 Marketing</span> </div> <div class="nav-item" data-tooltip="Mobile App Launch"> <div class="nav-item-icon"> <svg viewBox="0 0 24 24" fill="currentColor" xmlns="http://www.w3.org/2000/svg"> <path d="M17 1.01L7 1C5.9 1 5 1.9 5 3V21C5 22.1 5.9 23 7 23H17C18.1 23 19 22.1 19 21V3C19 1.9 18.1 1.01 17 1.01ZM17 19H7V5H17V19ZM12 6.5C11.17 6.5 10.5 7.17 10.5 8C10.5 8.83 11.17 9.5 12 9.5C12.83 9.5 13.5 8.83 13.5 8C13.5 7.17 12.83 6.5 12 6.5ZM12 15.5C13.38 15.5 14.5 14.38 14.5 13C14.5 11.62 13.38 10.5 12 10.5C10.62 10.5 9.5 11.62 9.5 13C9.5 14.38 10.62 15.5 12 15.5Z"/> </svg> </div> <span class="nav-item-text">Mobile App Launch</span> <span class="tooltip">Mobile App Launch</span> </div> </div> </div> <div class="progress-section"> <div class="progress-card"> <div class="progress-header"> <span class="progress-title">Weekly Progress</span> <span class="progress-percent">72%</span> </div> <div class="progress-bar-bg"> <div class="progress-bar-fill" style="width: 72%"></div> </div> </div> </div> <div class="sidebar-footer"> <div class="user-profile"> <div class="avatar">AM</div> <div class="user-info"> <div class="user-name">Alex Morgan</div> <div class="user-title">Product Designer</div> </div> </div> </div> </div> <div class="main-content"> <!-- Main content would go here but is outside the scope of the sidebar challenge --> </div> </div> <script> document.addEventListener('DOMContentLoaded', function() { const sidebar = document.querySelector('.sidebar'); const toggleSidebar = document.querySelector('.toggle-sidebar'); const toggleIconOpen = document.querySelector('.toggle-icon-open'); const toggleIconClose = document.querySelector('.toggle-icon-close'); const navItems = document.querySelectorAll('.nav-item'); // Toggle sidebar toggleSidebar.addEventListener('click', function() { sidebar.classList.toggle('collapsed'); if (sidebar.classList.contains('collapsed')) { toggleIconOpen.style.display = 'none'; toggleIconClose.style.display = 'block'; } else { toggleIconOpen.style.display = 'block'; toggleIconClose.style.display = 'none'; } }); // Ripple effect on nav items navItems.forEach(item => { item.addEventListener('click', function(e) { // Make all items inactive first navItems.forEach(navItem => { navItem.classList.remove('active'); }); // Make clicked item active this.classList.add('active'); // Create ripple effect const ripple = document.createElement('span'); ripple.classList.add('ripple'); const rect = this.getBoundingClientRect(); const size = Math.max(rect.width, rect.height); const x = e.clientX - rect.left - size / 2; const y = e.clientY - rect.top - size / 2; ripple.style.width = ripple.style.height = `${size}px`; ripple.style.left = `${x}px`; ripple.style.top = `${y}px`; this.appendChild(ripple); // Remove ripple after animation setTimeout(() => { ripple.remove(); }, 600); }); }); // Highlight the "Website Redesign" task with a pulsating effect const highlightTask = document.querySelector('.nav-item.highlight'); if (highlightTask) { setInterval(() => { highlightTask.classList.toggle('active'); setTimeout(() => { highlightTask.classList.toggle('active'); }, 500); }, 5000); } // Animate progress bar on page load const progressBars = document.querySelectorAll('.progress-bar-fill'); progressBars.forEach(bar => { const width = bar.style.width; bar.style.width = '0%'; setTimeout(() => { bar.style.width = width; }, 300); }); // Add tooltips for collapsed sidebar navItems.forEach(item => { const text = item.querySelector('.nav-item-text').textContent; item.setAttribute('data-tooltip', text); }); }); </script> </body> </html>
<html> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Glass Portfolio Gallery</title> <style> :root { --bg-color: #f8f9fa; --glass-bg: rgba(255, 255, 255, 0.15); --glass-border: rgba(255, 255, 255, 0.18); --accent: #7c4dff; --accent-light: #b388ff; --text-primary: #33333d; --text-secondary: #666678; --drop-shadow: 0 8px 32px rgba(0, 0, 0, 0.1); } * { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif; } body { background-color: var(--bg-color); background-image: radial-gradient(circle at 20% 20%, rgba(124, 77, 255, 0.08) 0%, transparent 25%), radial-gradient(circle at 80% 80%, rgba(179, 136, 255, 0.08) 0%, transparent 30%); color: var(--text-primary); min-height: 100vh; display: flex; flex-direction: column; align-items: center; overflow-x: hidden; padding: 1.5rem; } .container { max-width: 700px; width: 100%; height: 100%; max-height: 700px; overflow-y: auto; scrollbar-width: thin; scrollbar-color: var(--accent-light) transparent; position: relative; } .container::-webkit-scrollbar { width: 5px; } .container::-webkit-scrollbar-track { background: transparent; } .container::-webkit-scrollbar-thumb { background-color: var(--accent-light); border-radius: 20px; } header { margin-bottom: 2rem; text-align: center; } h1 { font-size: 2.2rem; margin-bottom: 0.5rem; background: linear-gradient(135deg, var(--text-primary), var(--accent)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; position: relative; display: inline-block; } h1::before { content: ""; position: absolute; height: 4px; width: 40%; background: linear-gradient(90deg, var(--accent-light), transparent); bottom: -10px; left: 30%; border-radius: 2px; } p.subtitle { color: var(--text-secondary); font-size: 1rem; max-width: 85%; margin: 1.5rem auto 1rem; line-height: 1.6; } .filter-bar { display: flex; justify-content: center; gap: 0.8rem; margin-bottom: 2rem; flex-wrap: wrap; } .filter-btn { background: var(--glass-bg); backdrop-filter: blur(8px); border: 1px solid var(--glass-border); padding: 0.5rem 1rem; border-radius: 1.5rem; color: var(--text-primary); font-size: 0.875rem; cursor: pointer; transition: all 0.3s ease; box-shadow: var(--drop-shadow); } .filter-btn:hover { background: rgba(255, 255, 255, 0.25); transform: translateY(-2px); box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1); } .filter-btn.active { background: var(--accent); color: white; border-color: var(--accent); } .gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1.5rem; width: 100%; } .project-card { background: var(--glass-bg); backdrop-filter: blur(10px); border: 1px solid var(--glass-border); border-radius: 12px; overflow: hidden; box-shadow: var(--drop-shadow); transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); position: relative; height: 250px; opacity: 0; transform: translateY(20px); } .project-card.visible { opacity: 1; transform: translateY(0); } .project-image { height: 65%; width: 100%; background-size: cover; background-position: center; position: relative; overflow: hidden; } .project-image::before { content: ""; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(to bottom, transparent 50%, rgba(0, 0, 0, 0.4) 100%); } .project-content { padding: 1rem; height: 35%; display: flex; flex-direction: column; justify-content: space-between; } .project-title { font-size: 1rem; font-weight: 600; margin-bottom: 0.3rem; } .project-category { font-size: 0.75rem; color: var(--accent); text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 0.5rem; } .project-card:hover { transform: scale(1.03) translateY(-5px); box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15); } .project-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0, 0, 0, 0.7); display: flex; justify-content: center; align-items: center; opacity: 0; transition: opacity 0.3s ease; backdrop-filter: blur(3px); } .project-card:hover .project-overlay { opacity: 1; } .view-btn { background: var(--accent); color: white; border: none; padding: 0.6rem 1.2rem; border-radius: 25px; font-weight: 500; cursor: pointer; transform: translateY(20px); opacity: 0; transition: all 0.3s ease; box-shadow: 0 5px 15px rgba(124, 77, 255, 0.3); } .project-card:hover .view-btn { transform: translateY(0); opacity: 1; } .view-btn:hover { background: var(--accent-light); box-shadow: 0 8px 20px rgba(124, 77, 255, 0.4); } .modal { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0, 0, 0, 0.8); backdrop-filter: blur(5px); display: flex; justify-content: center; align-items: center; z-index: 1000; opacity: 0; pointer-events: none; transition: opacity 0.3s ease; } .modal.open { opacity: 1; pointer-events: all; } .modal-content { background: var(--glass-bg); backdrop-filter: blur(15px); border: 1px solid var(--glass-border); border-radius: 12px; width: 90%; max-width: 600px; max-height: 85vh; overflow-y: auto; padding: 2rem; position: relative; box-shadow: var(--drop-shadow); transform: scale(0.9); opacity: 0; transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); } .modal.open .modal-content { transform: scale(1); opacity: 1; } .modal-close { position: absolute; top: 1rem; right: 1rem; background: rgba(255, 255, 255, 0.2); border: none; width: 32px; height: 32px; border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; color: white; font-size: 1.2rem; transition: all 0.3s ease; } .modal-close:hover { background: rgba(255, 255, 255, 0.3); transform: rotate(90deg); } .modal-image { width: 100%; height: 250px; background-size: cover; background-position: center; border-radius: 8px; margin-bottom: 1.5rem; } .modal-title { font-size: 1.5rem; margin-bottom: 0.5rem; color: white; } .modal-category { color: var(--accent-light); font-size: 0.875rem; margin-bottom: 1rem; text-transform: uppercase; letter-spacing: 0.05em; } .modal-description { color: rgba(255, 255, 255, 0.8); margin-bottom: 1.5rem; line-height: 1.6; } .tag-container { display: flex; gap: 0.5rem; flex-wrap: wrap; margin-bottom: 1.5rem; } .tag { background: rgba(255, 255, 255, 0.1); padding: 0.3rem 0.8rem; border-radius: 15px; font-size: 0.75rem; color: white; } .cta-button { display: inline-block; background: var(--accent); color: white; border: none; padding: 0.8rem 1.5rem; border-radius: 25px; font-weight: 500; cursor: pointer; transition: all 0.3s ease; box-shadow: 0 5px 15px rgba(124, 77, 255, 0.3); text-decoration: none; } .cta-button:hover { background: var(--accent-light); box-shadow: 0 8px 20px rgba(124, 77, 255, 0.4); transform: translateY(-2px); } .empty-state { width: 100%; height: 200px; display: flex; flex-direction: column; align-items: center; justify-content: center; background: var(--glass-bg); backdrop-filter: blur(10px); border: 1px solid var(--glass-border); border-radius: 12px; padding: 2rem; text-align: center; display: none; } .empty-icon { font-size: 2.5rem; margin-bottom: 1rem; color: var(--accent); opacity: 0.7; } .empty-text { color: var(--text-secondary); } /* Cursor effect */ .cursor-glow { width: 250px; height: 250px; background: radial-gradient(circle, rgba(124, 77, 255, 0.15) 0%, rgba(124, 77, 255, 0) 70%); border-radius: 50%; position: absolute; transform: translate(-50%, -50%); pointer-events: none; z-index: -1; transition: opacity 0.2s ease; opacity: 0; } @media (max-width: 768px) { .gallery { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 1rem; } h1 { font-size: 1.8rem; } .filter-bar { gap: 0.5rem; } .filter-btn { padding: 0.4rem 0.8rem; font-size: 0.8rem; } .project-card { height: 200px; } .modal-content { padding: 1.5rem; } } /* Loading animation */ .loading { display: flex; justify-content: center; margin: 2rem 0; height: 50px; align-items: center; } .dot { width: 10px; height: 10px; background: var(--accent); border-radius: 50%; margin: 0 5px; animation: bounce 1.5s infinite ease-in-out; } .dot:nth-child(1) { animation-delay: 0s; } .dot:nth-child(2) { animation-delay: 0.2s; } .dot:nth-child(3) { animation-delay: 0.4s; } @keyframes bounce { 0%, 100% { transform: translateY(0); opacity: 1; } 50% { transform: translateY(-15px); opacity: 0.5; } } </style> </head> <body> <div class="container"> <header> <h1>Crystalline Creations</h1> <p class="subtitle">A curated collection of projects where transparency meets design — explore my work through delicate glass frames that showcase each piece with subtle elegance.</p> </header> <div class="filter-bar"> <button class="filter-btn active" data-filter="all">All Projects</button> <button class="filter-btn" data-filter="web">Web Design</button> <button class="filter-btn" data-filter="ux">UX Research</button> <button class="filter-btn" data-filter="branding">Branding</button> <button class="filter-btn" data-filter="motion">Motion</button> </div> <div class="gallery"> <!-- Cards will be added dynamically --> </div> <div class="empty-state"> <div class="empty-icon">🔍</div> <div class="empty-text">No projects found with this filter. Try another category.</div> </div> <div class="loading"> <div class="dot"></div> <div class="dot"></div> <div class="dot"></div> </div> </div> <!-- Modal --> <div class="modal"> <div class="modal-content"> <button class="modal-close">×</button> <div class="modal-image"></div> <h2 class="modal-title"></h2> <div class="modal-category"></div> <p class="modal-description"></p> <div class="tag-container"> <!-- Tags will be added dynamically --> </div> <button class="cta-button">View Full Project</button> </div> </div> <div class="cursor-glow"></div> <script> // Project data const projects = [ { id: 1, title: "Nebula Dashboard", category: "web", image: "https://images.unsplash.com/photo-1551434678-e076c223a692?ixlib=rb-1.2.1&auto=format&fit=crop&w=600&q=80", description: "A responsive admin dashboard with customizable data visualization components. Built using React and D3.js with a focus on accessibility and performance optimization.", tags: ["React", "D3.js", "Responsive", "Dashboard"] }, { id: 2, title: "Essence eCommerce", category: "ux", image: "https://images.unsplash.com/photo-1460925895917-afdab827c52f?ixlib=rb-1.2.1&auto=format&fit=crop&w=600&q=80", description: "User research and interface design for a premium cosmetics brand. Conducted user interviews, created journey maps, and designed a streamlined checkout process that increased conversion by 24%.", tags: ["User Research", "Wireframing", "Prototyping", "A/B Testing"] }, { id: 3, title: "Prism Identity", category: "branding", image: "https://images.unsplash.com/photo-1634986666676-ec8fd927c23d?ixlib=rb-1.2.1&auto=format&fit=crop&w=600&q=80", description: "Complete brand identity for a tech startup focusing on AR experiences. Developed a dynamic logo system that adapts to different contexts while maintaining brand recognition.", tags: ["Logo Design", "Brand Guidelines", "Visual Identity", "Typography"] }, { id: 4, title: "Parallax Scroll", category: "web", image: "https://images.unsplash.com/photo-1558655146-9f40138edfeb?ixlib=rb-1.2.1&auto=format&fit=crop&w=600&q=80", description: "An interactive storytelling website using advanced parallax scrolling techniques. Built with vanilla JavaScript and GSAP for smooth animations and transitions across all devices.", tags: ["JavaScript", "GSAP", "Interactive", "Storytelling"] }, { id: 5, title: "Fluid Transitions", category: "motion", image: "https://images.unsplash.com/photo-1550745165-9bc0b252726f?ixlib=rb-1.2.1&auto=format&fit=crop&w=600&q=80", description: "A motion design study exploring organic transitions between abstract shapes. Created using After Effects and Cinema 4D with a focus on natural movement and visual continuity.", tags: ["After Effects", "Cinema 4D", "Animation", "Visual Effects"] }, { id: 6, title: "Clarity Banking", category: "ux", image: "https://images.unsplash.com/photo-1563986768609-322da13575f3?ixlib=rb-1.2.1&auto=format&fit=crop&w=600&q=80", description: "UX redesign for a mobile banking application focusing on simplifying complex financial information. Improved user satisfaction scores by 35% through iterative testing and refinement.", tags: ["Mobile UX", "Financial UI", "User Testing", "Information Architecture"] }, { id: 7, title: "Echo Music App", category: "branding", image: "https://images.unsplash.com/photo-1511379938547-c1f69419868d?ixlib=rb-1.2.1&auto=format&fit=crop&w=600&q=80", description: "Brand identity and design system for a music streaming platform. Created a flexible visual language that adapts to user preferences while maintaining strong brand recognition.", tags: ["Brand Strategy", "App Design", "Style Guide", "UI Components"] }, { id: 8, title: "Morph Sequences", category: "motion", image: "https://images.unsplash.com/photo-1550684376-efcbd6e3f031?ixlib=rb-1.2.1&auto=format&fit=crop&w=600&q=80", description: "Experimental animation series exploring shape transformation and color theory. Each sequence represents emotional states through abstract visual metaphors and precise timing.", tags: ["Animation", "Color Theory", "Motion Graphics", "Experimental"] } ]; // DOM Elements const galleryEl = document.querySelector('.gallery'); const filterBtns = document.querySelectorAll('.filter-btn'); const modal = document.querySelector('.modal'); const modalContent = document.querySelector('.modal-content'); const modalClose = document.querySelector('.modal-close'); const modalImage = document.querySelector('.modal-image'); const modalTitle = document.querySelector('.modal-title'); const modalCategory = document.querySelector('.modal-category'); const modalDescription = document.querySelector('.modal-description'); const tagContainer = document.querySelector('.tag-container'); const emptyState = document.querySelector('.empty-state'); const loadingEl = document.querySelector('.loading'); const cursorGlow = document.querySelector('.cursor-glow'); // Initialize filter state let currentFilter = 'all'; // Cursor effect document.addEventListener('mousemove', (e) => { cursorGlow.style.left = `${e.clientX}px`; cursorGlow.style.top = `${e.clientY}px`; cursorGlow.style.opacity = '1'; }); document.addEventListener('mouseleave', () => { cursorGlow.style.opacity = '0'; }); // Simulate loading setTimeout(() => { loadingEl.style.display = 'none'; renderProjects(); }, 1500); // Render projects based on filter function renderProjects() { galleryEl.innerHTML = ''; const filteredProjects = currentFilter === 'all' ? projects : projects.filter(project => project.category === currentFilter); if (filteredProjects.length === 0) { emptyState.style.display = 'flex'; } else { emptyState.style.display = 'none'; filteredProjects.forEach((project, index) => { const card = document.createElement('div'); card.className = 'project-card'; card.dataset.category = project.category; card.innerHTML = ` <div class="project-image" style="background-image: url(${project.image})"></div> <div class="project-content"> <div> <div class="project-category">${getCategoryName(project.category)}</div> <h3 class="project-title">${project.title}</h3> </div> </div> <div class="project-overlay"> <button class="view-btn" data-id="${project.id}">View Details</button> </div> `; galleryEl.appendChild(card); // Animate cards in sequence setTimeout(() => { card.classList.add('visible'); }, 100 * index); }); } } // Get formatted category name function getCategoryName(category) { const categories = { 'web': 'Web Design', 'ux': 'UX Research', 'branding': 'Branding', 'motion': 'Motion Design' }; return categories[category] || category; } // Filter click handler filterBtns.forEach(btn => { btn.addEventListener('click', () => { // Update active state filterBtns.forEach(b => b.classList.remove('active')); btn.classList.add('active'); // Update filter and re-render currentFilter = btn.dataset.filter; renderProjects(); }); }); // Modal functionality galleryEl.addEventListener('click', (e) => { const viewBtn = e.target.closest('.view-btn'); if (viewBtn) { const projectId = parseInt(viewBtn.dataset.id); const project = projects.find(p => p.id === projectId); if (project) { // Populate modal content modalImage.style.backgroundImage = `url(${project.image})`; modalTitle.textContent = project.title; modalCategory.textContent = getCategoryName(project.category); modalDescription.textContent = project.description; // Add tags tagContainer.innerHTML = ''; project.tags.forEach(tag => { const tagEl = document.createElement('span'); tagEl.className = 'tag'; tagEl.textContent = tag; tagContainer.appendChild(tagEl); }); // Show modal modal.classList.add('open'); } } }); // Close modal modalClose.addEventListener('click', () => { modal.classList.remove('open'); }); // Close modal on outside click modal.addEventListener('click', (e) => { if (e.target === modal) { modal.classList.remove('open'); } }); // Prevent modal content click from closing modalContent.addEventListener('click', (e) => { e.stopPropagation(); }); // CTA Button click (no actual submission, just visual feedback) document.querySelector('.cta-button').addEventListener('click', function(e) { e.preventDefault(); this.textContent = 'Opening project...'; setTimeout(() => { this.textContent = 'View Full Project'; modal.classList.remove('open'); }, 1500); }); </script> </body> </html>
<html> <head> <style> * { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Inter', 'Segoe UI', sans-serif; } body { width: 100%; height: 100vh; display: flex; justify-content: center; align-items: center; background: linear-gradient(135deg, #1a1f2c, #121621); padding: 20px; overflow: hidden; } .dashboard-container { width: 100%; max-width: 680px; display: flex; flex-direction: column; gap: 20px; } .dashboard-header { color: #fff; padding-bottom: 10px; } .dashboard-header h1 { font-size: 1.8rem; font-weight: 700; margin-bottom: 5px; background: linear-gradient(90deg, #c5e0ff, #69a6ff); -webkit-background-clip: text; background-clip: text; color: transparent; } .dashboard-header p { font-size: 0.9rem; color: rgba(255, 255, 255, 0.6); } .card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 20px; } .financial-card { background: rgba(255, 255, 255, 0.07); backdrop-filter: blur(15px); border-radius: 15px; padding: 20px; box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2); border: 1px solid rgba(255, 255, 255, 0.1); transition: all 0.3s ease; position: relative; overflow: hidden; z-index: 1; height: 100%; } .financial-card::before { content: ''; position: absolute; inset: 0; background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), transparent); z-index: -1; border-radius: 15px; } .financial-card:hover { transform: translateY(-8px); box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3); } .card-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 15px; } .card-title { color: rgba(255, 255, 255, 0.8); font-size: 1rem; font-weight: 500; } .card-icon { width: 30px; height: 30px; display: flex; align-items: center; justify-content: center; color: #fff; border-radius: 8px; font-size: 0.9rem; } .card-value { font-size: 1.7rem; font-weight: 700; color: #fff; margin: 10px 0; transition: transform 0.3s ease; } .financial-card:hover .card-value { transform: scale(1.05); } .card-trend { display: flex; align-items: center; font-size: 0.85rem; margin-top: 5px; } .card-trend.positive { color: #4ade80; } .card-trend.negative { color: #f87171; } .card-trend-icon { margin-right: 5px; } .sparkline { margin-top: 20px; width: 100%; height: 40px; } .detailed-card { grid-column: 1 / -1; height: auto; } .chart-container { height: 200px; margin-top: 20px; position: relative; } .stat-container { display: flex; justify-content: space-between; margin-top: 15px; } .stat-item { background: rgba(255, 255, 255, 0.05); border-radius: 10px; padding: 10px; flex: 1; margin: 0 5px; transition: all 0.3s ease; } .stat-item:hover { background: rgba(255, 255, 255, 0.1); } .stat-title { font-size: 0.7rem; color: rgba(255, 255, 255, 0.6); margin-bottom: 5px; } .stat-value { font-size: 1.1rem; font-weight: 600; color: #fff; } .btn-action { background: rgba(105, 166, 255, 0.15); color: #69a6ff; border: 1px solid rgba(105, 166, 255, 0.3); border-radius: 8px; padding: 10px 15px; font-size: 0.85rem; font-weight: 600; cursor: pointer; transition: all 0.3s ease; outline: none; margin-top: 20px; display: inline-flex; align-items: center; } .btn-action:hover { background: rgba(105, 166, 255, 0.3); } .btn-action svg { margin-left: 8px; transition: transform 0.3s ease; } .btn-action:hover svg { transform: translateX(3px); } .dot-indicator { width: 8px; height: 8px; border-radius: 50%; display: inline-block; margin-right: 5px; } .dot-indicator.active { background-color: #4ade80; } .dot-indicator.pending { background-color: #facc15; } .dot-indicator.closed { background-color: #f87171; } .time-period-selector { display: flex; gap: 10px; margin-top: 15px; } .time-btn { background: transparent; border: 1px solid rgba(255, 255, 255, 0.2); color: rgba(255, 255, 255, 0.6); border-radius: 6px; padding: 6px 12px; font-size: 0.75rem; cursor: pointer; transition: all 0.3s ease; } .time-btn.active { background: rgba(105, 166, 255, 0.15); color: #69a6ff; border-color: rgba(105, 166, 255, 0.3); } .time-btn:hover:not(.active) { background: rgba(255, 255, 255, 0.05); color: rgba(255, 255, 255, 0.8); } @media (max-width: 600px) { .dashboard-header h1 { font-size: 1.5rem; } .card-grid { grid-template-columns: 1fr; } .stat-container { flex-direction: column; gap: 10px; } .stat-item { margin: 0; } } /* Custom gradient backgrounds for cards */ .financial-card.investment { background: linear-gradient(to right, rgba(111, 76, 255, 0.1), rgba(28, 20, 56, 0.1)); } .financial-card.savings { background: linear-gradient(to right, rgba(66, 153, 225, 0.1), rgba(18, 41, 60, 0.1)); } .financial-card.expenses { background: linear-gradient(to right, rgba(236, 72, 153, 0.1), rgba(56, 24, 41, 0.1)); } .financial-card.detailed { background: linear-gradient(170deg, rgba(20, 30, 48, 0.4), rgba(36, 59, 85, 0.1)); } /* Animations */ @keyframes pulse { 0% { transform: scale(1); } 50% { transform: scale(1.05); } 100% { transform: scale(1); } } .pulse-animation { animation: pulse 2s infinite; } /* Floating dots background decoration */ .dots-bg { position: absolute; width: 100%; height: 100%; top: 0; left: 0; overflow: hidden; z-index: -1; } .dot { position: absolute; background: rgba(255, 255, 255, 0.05); border-radius: 50%; } </style> </head> <body> <div class="dots-bg" id="dotsBg"></div> <div class="dashboard-container"> <div class="dashboard-header"> <h1>Financial Intelligence</h1> <p>Market overview for April 28, 2023 • Last updated 2 hours ago</p> </div> <div class="card-grid"> <div class="financial-card investment"> <div class="card-header"> <div class="card-title">Portfolio Value</div> <div class="card-icon" style="background: rgba(111, 76, 255, 0.2);"> <svg width="16" height="16" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M12 2C6.48 2 2 6.48 2 12C2 17.52 6.48 22 12 22C17.52 22 22 17.52 22 12C22 6.48 17.52 2 12 2ZM16 17H8C7.45 17 7 16.55 7 16C7 15.45 7.45 15 8 15H16C16.55 15 17 15.45 17 16C17 16.55 16.55 17 16 17ZM16 13H8C7.45 13 7 12.55 7 12C7 11.45 7.45 11 8 11H16C16.55 11 17 11.45 17 12C17 12.55 16.55 13 16 13ZM16 9H8C7.45 9 7 8.55 7 8C7 7.45 7.45 7 8 7H16C16.55 7 17 7.45 17 8C17 8.55 16.55 9 16 9Z" fill="#9b7aff"/> </svg> </div> </div> <div class="card-value">$143,926</div> <div class="card-trend positive"> <span class="card-trend-icon">↑</span> 12.4% from last month </div> <canvas class="sparkline" id="investmentSparkline"></canvas> </div> <div class="financial-card savings"> <div class="card-header"> <div class="card-title">Total Savings</div> <div class="card-icon" style="background: rgba(66, 153, 225, 0.2);"> <svg width="16" height="16" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M21 18V19C21 20.1 20.1 21 19 21H5C3.89 21 3 20.1 3 19V5C3 3.9 3.89 3 5 3H19C20.1 3 21 3.9 21 5V6H12C10.89 6 10 6.9 10 8V16C10 17.1 10.89 18 12 18H21ZM12 16H22V8H12V16ZM16 13.5C15.17 13.5 14.5 12.83 14.5 12C14.5 11.17 15.17 10.5 16 10.5C16.83 10.5 17.5 11.17 17.5 12C17.5 12.83 16.83 13.5 16 13.5Z" fill="#4299e1"/> </svg> </div> </div> <div class="card-value">$58,340</div> <div class="card-trend positive"> <span class="card-trend-icon">↑</span> 3.8% from last month </div> <canvas class="sparkline" id="savingsSparkline"></canvas> </div> <div class="financial-card expenses"> <div class="card-header"> <div class="card-title">Monthly Expenses</div> <div class="card-icon" style="background: rgba(236, 72, 153, 0.2);"> <svg width="16" height="16" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M14 2H6C4.9 2 4 2.9 4 4V20C4 21.1 4.9 22 6 22H18C19.1 22 20 21.1 20 20V8L14 2ZM6 20V4H13V9H18V20H6ZM16 11H8V13H16V11ZM14 15H8V17H14V15Z" fill="#ec4899"/> </svg> </div> </div> <div class="card-value">$4,287</div> <div class="card-trend negative"> <span class="card-trend-icon">↑</span> 2.3% from last month </div> <canvas class="sparkline" id="expensesSparkline"></canvas> </div> <div class="financial-card detailed"> <div class="card-header"> <div class="card-title">Investment Performance</div> <div class="time-period-selector"> <button class="time-btn">1W</button> <button class="time-btn active">1M</button> <button class="time-btn">3M</button> <button class="time-btn">1Y</button> <button class="time-btn">All</button> </div> </div> <div class="chart-container"> <canvas id="performanceChart"></canvas> </div> <div class="stat-container"> <div class="stat-item"> <div class="stat-title">ROI</div> <div class="stat-value">+16.8%</div> </div> <div class="stat-item"> <div class="stat-title">Volatility</div> <div class="stat-value">Low</div> </div> <div class="stat-item"> <div class="stat-title">Dividend Yield</div> <div class="stat-value">3.2%</div> </div> <div class="stat-item"> <div class="stat-title">Risk Score</div> <div class="stat-value">62/100</div> </div> </div> <button class="btn-action"> View detailed report <svg width="16" height="16" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M12 4L10.59 5.41L16.17 11H4V13H16.17L10.59 18.59L12 20L20 12L12 4Z" fill="#69a6ff"/> </svg> </button> </div> </div> </div> <script src="https://cdn.jsdelivr.net/npm/chart.js"></script> <script> // Create floating dots in background const dotsBg = document.getElementById('dotsBg'); for (let i = 0; i < 50; i++) { const dot = document.createElement('div'); dot.classList.add('dot'); const size = Math.random() * 6 + 2; dot.style.width = `${size}px`; dot.style.height = `${size}px`; dot.style.left = `${Math.random() * 100}%`; dot.style.top = `${Math.random() * 100}%`; // Random opacity dot.style.opacity = Math.random() * 0.5; dotsBg.appendChild(dot); } // Animation for dots const dots = document.querySelectorAll('.dot'); dots.forEach(dot => { const animDuration = Math.random() * 50 + 30; const animDelay = Math.random() * 10; dot.style.animation = `pulse ${animDuration}s ${animDelay}s infinite`; }); // Sparkline charts function createSparkline(canvasId, data, color) { const canvas = document.getElementById(canvasId); const ctx = canvas.getContext('2d'); new Chart(ctx, { type: 'line', data: { labels: Array(data.length).fill(''), datasets: [{ data: data, borderColor: color, borderWidth: 2, fill: true, backgroundColor: color.replace(')', ', 0.1)').replace('rgb', 'rgba'), pointRadius: 0, tension: 0.4 }] }, options: { responsive: true, maintainAspectRatio: false, plugins: { legend: { display: false }, tooltip: { enabled: false } }, scales: { x: { display: false }, y: { display: false } } } }); } // Main performance chart function createPerformanceChart() { const ctx = document.getElementById('performanceChart').getContext('2d'); const gradient = ctx.createLinearGradient(0, 0, 0, 200); gradient.addColorStop(0, 'rgba(105, 166, 255, 0.4)'); gradient.addColorStop(1, 'rgba(105, 166, 255, 0.0)'); new Chart(ctx, { type: 'line', data: { labels: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'], datasets: [{ label: 'Portfolio Value', data: [112000, 118500, 116000, 120500, 118900, 128000, 131000, 135000, 134000, 138000, 140000, 143926], borderColor: 'rgb(105, 166, 255)', borderWidth: 2, fill: true, backgroundColor: gradient, pointRadius: 0, pointHoverRadius: 6, pointBackgroundColor: '#fff', pointHoverBackgroundColor: 'rgb(105, 166, 255)', pointBorderColor: 'rgb(105, 166, 255)', pointHoverBorderColor: 'rgb(255, 255, 255)', pointBorderWidth: 2, tension: 0.4 }] }, options: { responsive: true, maintainAspectRatio: false, plugins: { legend: { display: false }, tooltip: { backgroundColor: 'rgba(17, 25, 40, 0.9)', titleColor: 'rgba(255, 255, 255, 0.8)', bodyColor: 'rgba(255, 255, 255, 0.8)', borderColor: 'rgba(255, 255, 255, 0.1)', borderWidth: 1, padding: 10, cornerRadius: 8, callbacks: { label: function(context) { return `$${context.raw.toLocaleString()}`; } } } }, scales: { x: { grid: { display: false, drawBorder: false }, ticks: { color: 'rgba(255, 255, 255, 0.6)', font: { size: 10 }, maxRotation: 0 } }, y: { grid: { color: 'rgba(255, 255, 255, 0.1)', drawBorder: false }, ticks: { color: 'rgba(255, 255, 255, 0.6)', font: { size: 10 }, callback: function(value) { return '$' + value.toLocaleString(); } } } }, interaction: { mode: 'index', intersect: false }, hover: { mode: 'nearest', intersect: true } } }); } // Initialize charts when DOM is loaded document.addEventListener('DOMContentLoaded', function() { // Sparkline data const investmentData = [90000, 92000, 95000, 97000, 101000, 105000, 108000, 112000, 120000, 125000, 130000, 143926]; const savingsData = [48000, 49500, 51000, 52000, 53500, 55000, 56000, 56800, 57200, 57800, 58100, 58340]; const expensesData = [3800, 4100, 3900, 4000, 4200, 4100, 4150, 4250, 4300, 4180, 4200, 4287]; // Create sparklines createSparkline('investmentSparkline', investmentData, 'rgb(111, 76, 255)'); createSparkline('savingsSparkline', savingsData, 'rgb(66, 153, 225)'); createSparkline('expensesSparkline', expensesData, 'rgb(236, 72, 153)'); // Create performance chart createPerformanceChart(); // Time period selector const timeButtons = document.querySelectorAll('.time-btn'); timeButtons.forEach(btn => { btn.addEventListener('click', function() { timeButtons.forEach(b => b.classList.remove('active')); this.classList.add('active'); }); }); // Add subtle hover effect to stat items const statItems = document.querySelectorAll('.stat-item'); statItems.forEach(item => { item.addEventListener('mouseover', function() { this.classList.add('pulse-animation'); }); item.addEventListener('mouseout', function() { this.classList.remove('pulse-animation'); }); }); }); </script> </body> </html>
<html> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Dreamscape Gallery</title> <style> @import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;700&family=Montserrat:wght@300;400;500&display=swap'); :root { --glass-bg: rgba(255, 255, 255, 0.15); --glass-border: rgba(255, 255, 255, 0.2); --glass-shadow: rgba(0, 0, 0, 0.1); --accent: #8a5fff; --text: #333; --light-text: #f5f5f7; } * { margin: 0; padding: 0; box-sizing: border-box; } body { font-family: 'Montserrat', sans-serif; background: linear-gradient(135deg, #f5f7fa, #e8ecf1); color: var(--text); height: 100vh; width: 100%; overflow: hidden; display: flex; flex-direction: column; align-items: center; justify-content: center; cursor: none; } .container { width: 100%; max-width: 700px; height: 700px; display: flex; flex-direction: column; position: relative; padding: 1.5rem; } header { z-index: 10; display: flex; justify-content: space-between; align-items: center; padding: 0.5rem 1rem; margin-bottom: 1rem; } .logo { font-family: 'Playfair Display', serif; font-weight: 700; font-size: 1.5rem; color: var(--accent); letter-spacing: 1px; text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); } nav { display: flex; gap: 1.5rem; } nav a { font-size: 0.9rem; color: var(--text); text-decoration: none; position: relative; transition: color 0.3s; } nav a::after { content: ''; position: absolute; bottom: -3px; left: 0; width: 0; height: 2px; background-color: var(--accent); transition: width 0.3s ease; } nav a:hover { color: var(--accent); } nav a:hover::after { width: 100%; } .gallery { display: grid; grid-template-columns: repeat(2, 1fr); grid-auto-rows: minmax(180px, auto); gap: 1.5rem; flex: 1; z-index: 1; } .artwork { border-radius: 12px; overflow: hidden; position: relative; cursor: none; transform: translateY(0); transition: transform 0.5s cubic-bezier(0.19, 1, 0.22, 1); } .artwork:hover { transform: translateY(-5px); } .artwork:nth-child(1) { grid-row: span 2; } .artwork:nth-child(4) { grid-column: span 2; } .artwork img { width: 100%; height: 100%; object-fit: cover; transition: filter 0.5s ease; } .artwork-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: var(--glass-bg); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border: 1px solid var(--glass-border); border-radius: 12px; display: flex; flex-direction: column; justify-content: flex-end; padding: 1.5rem; opacity: 0; transform: translateY(20px); transition: all 0.5s cubic-bezier(0.19, 1, 0.22, 1); } .artwork:hover .artwork-overlay { opacity: 1; transform: translateY(0); } .artwork-title { font-family: 'Playfair Display', serif; font-size: 1.2rem; font-weight: 700; color: var(--light-text); margin-bottom: 0.5rem; text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2); } .artwork-artist { font-size: 0.85rem; font-weight: 300; color: var(--light-text); opacity: 0.9; margin-bottom: 0.75rem; } .artwork-desc { font-size: 0.8rem; line-height: 1.5; color: var(--light-text); opacity: 0.8; max-height: 0; overflow: hidden; transition: max-height 0.5s ease; } .artwork:hover .artwork-desc { max-height: 100px; } .custom-cursor { position: fixed; width: 40px; height: 40px; border-radius: 50%; border: 2px solid var(--accent); pointer-events: none; transform: translate(-50%, -50%); z-index: 9999; transition: width 0.3s, height 0.3s, background 0.3s, transform 0.1s; display: flex; align-items: center; justify-content: center; color: transparent; font-size: 0.75rem; text-align: center; } .custom-cursor.hover { width: 80px; height: 80px; background: rgba(138, 95, 255, 0.2); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); color: white; } .blur-vignette { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: radial-gradient(circle at center, transparent 30%, rgba(232, 236, 241, 0.8) 100%); pointer-events: none; z-index: 0; } .light-effect { position: absolute; width: 500px; height: 500px; border-radius: 50%; filter: blur(100px); background: linear-gradient(45deg, rgba(138, 95, 255, 0.3), rgba(255, 102, 196, 0.3)); opacity: 0.5; pointer-events: none; z-index: -1; transition: all 1s ease; } .exhibition-info { position: absolute; bottom: 1rem; left: 1rem; right: 1rem; padding: 1rem 1.5rem; background: var(--glass-bg); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border: 1px solid var(--glass-border); border-radius: 12px; display: flex; justify-content: space-between; align-items: center; z-index: 2; box-shadow: 0 4px 30px var(--glass-shadow); transform: translateY(100%); opacity: 0; transition: transform 0.6s cubic-bezier(0.19, 1, 0.22, 1), opacity 0.6s ease; } .exhibition-info.active { transform: translateY(0); opacity: 1; } .exhibition-text { flex: 1; } .exhibition-text h3 { font-family: 'Playfair Display', serif; font-size: 1rem; margin-bottom: 0.25rem; } .exhibition-text p { font-size: 0.8rem; opacity: 0.8; } .exhibition-button { background: rgba(138, 95, 255, 0.2); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); color: var(--accent); border: 1px solid var(--accent); padding: 0.5rem 1rem; border-radius: 50px; font-size: 0.75rem; font-weight: 500; cursor: pointer; transition: all 0.3s ease; } .exhibition-button:hover { background: var(--accent); color: white; } @media (max-width: 700px) { .gallery { grid-template-columns: 1fr; } .artwork:nth-child(4) { grid-column: span 1; } nav { gap: 1rem; } nav a { font-size: 0.8rem; } .logo { font-size: 1.2rem; } } @media (max-width: 480px) { .container { padding: 1rem; } header { flex-direction: column; align-items: flex-start; gap: 0.75rem; } .exhibition-info { flex-direction: column; gap: 1rem; align-items: flex-start; } .exhibition-button { width: 100%; text-align: center; } } </style> </head> <body> <div class="container"> <header> <div class="logo">Dreamscape</div> <nav> <a href="#">Current</a> <a href="#">Artists</a> <a href="#">About</a> <a href="#">Contact</a> </nav> </header> <div class="gallery"> <div class="artwork"> <img src="https://images.unsplash.com/photo-1618005182384-a83a8bd57fbe?q=80&w=2064&auto=format&fit=crop" alt="Digital Art Piece"> <div class="artwork-overlay"> <h3 class="artwork-title">Ethereal Fragments</h3> <p class="artwork-artist">by Sophia Chen</p> <p class="artwork-desc">A procedurally generated landscape exploring the boundary between the natural and the digital. Each viewing reveals new patterns in the neural network's interpretation.</p> </div> </div> <div class="artwork"> <img src="https://images.unsplash.com/photo-1604871000636-074fa5117945?q=80&w=1974&auto=format&fit=crop" alt="Abstract Digital Art"> <div class="artwork-overlay"> <h3 class="artwork-title">Quantum Pulse</h3> <p class="artwork-artist">by Marcus Rivera</p> <p class="artwork-desc">Visualizing the invisible rhythms of quantum mechanics through generative algorithms, creating patterns that subtly shift based on real-time data.</p> </div> </div> <div class="artwork"> <img src="https://images.unsplash.com/photo-1633627243100-2d9f1011fdd5?q=80&w=1974&auto=format&fit=crop" alt="Immersive Digital Art"> <div class="artwork-overlay"> <h3 class="artwork-title">Memory Cascade</h3> <p class="artwork-artist">by Eliza James</p> <p class="artwork-desc">An exploration of how digital media preserves and transforms memories, rendered through a custom diffusion process that mimics neural pathways.</p> </div> </div> <div class="artwork"> <img src="https://images.unsplash.com/photo-1633186710895-309db2dfb12c?q=80&w=1974&auto=format&fit=crop" alt="Interactive Digital Art"> <div class="artwork-overlay"> <h3 class="artwork-title">Chromatic Symphony</h3> <p class="artwork-artist">by Akira Tanaka</p> <p class="artwork-desc">A synesthetic experience merging sound and color through AI interpolation. Each hue represents a specific frequency in this audio-visual composition.</p> </div> </div> </div> <div class="exhibition-info"> <div class="exhibition-text"> <h3>Algorithmic Realities</h3> <p>A special exhibition exploring the intersection of human creativity and computational processes. Open through October 30th.</p> </div> <button class="exhibition-button">View Exhibition</button> </div> </div> <div class="custom-cursor">View</div> <div class="blur-vignette"></div> <div class="light-effect"></div> <script> document.addEventListener('DOMContentLoaded', () => { const cursor = document.querySelector('.custom-cursor'); const artworks = document.querySelectorAll('.artwork'); const lightEffect = document.querySelector('.light-effect'); const exhibitionInfo = document.querySelector('.exhibition-info'); // Custom cursor document.addEventListener('mousemove', (e) => { cursor.style.left = `${e.clientX}px`; cursor.style.top = `${e.clientY}px`; // Move light effect with some lag for dreamy effect setTimeout(() => { lightEffect.style.left = `${e.clientX - 250}px`; lightEffect.style.top = `${e.clientY - 250}px`; }, 100); }); // Artwork hover effects artworks.forEach(artwork => { artwork.addEventListener('mouseenter', () => { cursor.classList.add('hover'); cursor.innerHTML = 'View<br>Details'; }); artwork.addEventListener('mouseleave', () => { cursor.classList.remove('hover'); cursor.innerHTML = ''; }); }); // Make cursor disappear when leaving window document.addEventListener('mouseleave', () => { cursor.style.display = 'none'; }); document.addEventListener('mouseenter', () => { cursor.style.display = 'flex'; }); // Show exhibition info after a delay setTimeout(() => { exhibitionInfo.classList.add('active'); }, 1500); // Exhibition button const exhibitionButton = document.querySelector('.exhibition-button'); exhibitionButton.addEventListener('click', () => { // Pulse animation on click exhibitionButton.style.transform = 'scale(0.95)'; setTimeout(() => { exhibitionButton.style.transform = 'scale(1)'; }, 150); // Toggle exhibition info exhibitionInfo.classList.toggle('active'); setTimeout(() => { exhibitionInfo.classList.add('active'); }, 3000); }); // Random artwork "breathing" animation setInterval(() => { const randomArtwork = artworks[Math.floor(Math.random() * artworks.length)]; randomArtwork.style.transform = 'translateY(-8px)'; setTimeout(() => { randomArtwork.style.transform = 'translateY(0)'; }, 1000); }, 3000); }); </script> </body> </html>
<html> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Social Media Notification Panel</title> <style> :root { --bg-color: #101520; --glass-bg: rgba(255, 255, 255, 0.08); --glass-border: rgba(255, 255, 255, 0.1); --glass-shadow: rgba(0, 0, 0, 0.1); --primary-color: #6c5ce7; --secondary-color: #00cec9; --accent-color: #fd79a8; --text-color: #f1f1f1; --text-secondary: rgba(255, 255, 255, 0.7); --text-muted: rgba(255, 255, 255, 0.5); } * { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif; } body { display: flex; justify-content: center; align-items: center; min-height: 100vh; background-color: var(--bg-color); background-image: radial-gradient(circle at 20% 30%, rgba(108, 92, 231, 0.15) 0%, transparent 30%), radial-gradient(circle at 80% 70%, rgba(0, 206, 201, 0.1) 0%, transparent 30%); overflow: hidden; padding: 20px; } .container { width: 100%; max-width: 360px; height: auto; position: relative; } .notification-bell { background: var(--glass-bg); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border: 1px solid var(--glass-border); border-radius: 50%; width: 56px; height: 56px; display: flex; justify-content: center; align-items: center; position: relative; cursor: pointer; box-shadow: 0 8px 32px var(--glass-shadow); transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1); margin-left: auto; } .notification-bell:hover { transform: scale(1.05); } .notification-bell svg { width: 24px; height: 24px; fill: var(--text-color); } .notification-badge { position: absolute; top: 0; right: 0; background: var(--accent-color); color: white; border-radius: 50%; width: 20px; height: 20px; display: flex; justify-content: center; align-items: center; font-size: 12px; font-weight: 600; box-shadow: 0 4px 8px rgba(253, 121, 168, 0.4); transform: translate(30%, -30%); } .notification-panel { position: absolute; top: 70px; right: 0; width: 360px; background: var(--glass-bg); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border: 1px solid var(--glass-border); border-radius: 16px; box-shadow: 0 8px 32px var(--glass-shadow); padding: 20px; transform-origin: top right; transform: scale(0.95); opacity: 0; visibility: hidden; transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1); z-index: 10; overflow: hidden; max-height: 550px; display: flex; flex-direction: column; } .notification-panel.active { transform: scale(1); opacity: 1; visibility: visible; } .panel-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; padding-bottom: 16px; border-bottom: 1px solid var(--glass-border); } .panel-title { font-size: 18px; font-weight: 600; color: var(--text-color); } .panel-actions { display: flex; gap: 12px; } .action-btn { background: transparent; border: none; cursor: pointer; color: var(--text-secondary); font-size: 14px; transition: color 0.2s; } .action-btn:hover { color: var(--text-color); } .notification-list { display: flex; flex-direction: column; gap: 12px; margin-bottom: 10px; overflow-y: auto; flex-grow: 1; scrollbar-width: thin; scrollbar-color: var(--glass-border) transparent; } .notification-list::-webkit-scrollbar { width: 6px; } .notification-list::-webkit-scrollbar-track { background: transparent; } .notification-list::-webkit-scrollbar-thumb { background-color: var(--glass-border); border-radius: 20px; } .notification-item { display: flex; padding: 12px; border-radius: 12px; position: relative; transition: background-color 0.2s, transform 0.2s; overflow: hidden; } .notification-item:hover { background: rgba(255, 255, 255, 0.05); transform: translateX(4px); } .notification-item.unread::before { content: ''; position: absolute; left: 0; top: 50%; transform: translateY(-50%); width: 4px; height: 50%; background: var(--primary-color); border-radius: 0 4px 4px 0; } .notification-item.unread { background: rgba(108, 92, 231, 0.08); } .notification-avatar { width: 42px; height: 42px; border-radius: 50%; overflow: hidden; margin-right: 12px; flex-shrink: 0; background: var(--glass-bg); border: 1px solid var(--glass-border); display: flex; justify-content: center; align-items: center; } .notification-avatar img { width: 100%; height: 100%; object-fit: cover; } .notification-content { flex-grow: 1; } .notification-text { font-size: 14px; line-height: 1.4; color: var(--text-color); margin-bottom: 4px; } .notification-text span { font-weight: 600; } .notification-time { font-size: 12px; color: var(--text-muted); display: flex; align-items: center; } .notification-time svg { width: 12px; height: 12px; margin-right: 4px; opacity: 0.7; } .notification-action { display: flex; align-items: center; margin-left: 12px; } .notification-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--primary-color); margin-left: 4px; } .panel-footer { padding-top: 12px; border-top: 1px solid var(--glass-border); text-align: center; } .view-all-btn { background: var(--glass-bg); color: var(--text-color); border: 1px solid var(--glass-border); padding: 8px 16px; border-radius: 8px; font-size: 14px; cursor: pointer; transition: all 0.2s; width: 100%; } .view-all-btn:hover { background: rgba(255, 255, 255, 0.1); } /* Notification type icons */ .notification-type { position: absolute; bottom: 0; right: 0; transform: translate(30%, 30%); width: 18px; height: 18px; border-radius: 50%; display: flex; justify-content: center; align-items: center; } .notification-type svg { width: 10px; height: 10px; fill: white; } .type-like { background: linear-gradient(45deg, #fd79a8, #e84393); } .type-comment { background: linear-gradient(45deg, #0984e3, #6c5ce7); } .type-follow { background: linear-gradient(45deg, #00b894, #00cec9); } .type-mention { background: linear-gradient(45deg, #fdcb6e, #e17055); } /* Animation for new notifications */ @keyframes popIn { 0% { transform: scale(0.8); opacity: 0; } 50% { transform: scale(1.05); } 100% { transform: scale(1); opacity: 1; } } .notification-item.new { animation: popIn 0.5s forwards; } /* Bell animation */ @keyframes bellRing { 0%, 100% { transform: rotate(0); } 20%, 60% { transform: rotate(-5deg); } 40%, 80% { transform: rotate(5deg); } } .ring { animation: bellRing 0.6s ease; } /* Tab styling */ .tab-control { display: flex; gap: 8px; margin-bottom: 16px; border-bottom: 1px solid var(--glass-border); padding-bottom: 12px; } .tab-btn { background: transparent; border: none; color: var(--text-muted); padding: 6px 12px; border-radius: 6px; font-size: 14px; cursor: pointer; transition: all 0.2s; position: relative; } .tab-btn.active { color: var(--text-color); } .tab-btn.active::after { content: ''; position: absolute; bottom: -13px; left: 0; width: 100%; height: 2px; background: var(--primary-color); border-radius: 2px; } .tab-btn:hover:not(.active) { background: rgba(255, 255, 255, 0.05); } /* Ghost badge for empty state */ .ghost-badge { display: flex; flex-direction: column; justify-content: center; align-items: center; padding: 30px 0; color: var(--text-muted); display: none; } .ghost-badge svg { width: 60px; height: 60px; margin-bottom: 16px; fill: var(--text-muted); opacity: 0.6; } .ghost-badge p { font-size: 14px; text-align: center; line-height: 1.5; } /* Responsive adjustments */ @media (max-width: 400px) { .container { max-width: 100%; } .notification-panel { width: calc(100vw - 40px); right: 0; } } /* Filter feature highlight */ .filter-highlight { position: absolute; top: -6px; right: -6px; background: var(--secondary-color); border-radius: 50%; width: 16px; height: 16px; display: flex; justify-content: center; align-items: center; font-size: 10px; color: white; opacity: 0; transform: scale(0); transition: all 0.3s ease; } .filter-highlight.active { opacity: 1; transform: scale(1); } /* Notification Groups */ .notification-group { margin-bottom: 16px; } .group-header { font-size: 12px; color: var(--text-muted); margin-bottom: 8px; padding-left: 4px; } .interaction-buttons { display: flex; gap: 8px; margin-top: 8px; } .interaction-btn { padding: 4px 10px; background: rgba(255, 255, 255, 0.05); border: 1px solid var(--glass-border); border-radius: 4px; font-size: 12px; color: var(--text-secondary); cursor: pointer; transition: all 0.2s; } .interaction-btn:hover { background: rgba(255, 255, 255, 0.1); color: var(--text-color); } .notification-media { margin-top: 8px; border-radius: 8px; overflow: hidden; border: 1px solid var(--glass-border); } .notification-media img { width: 100%; height: auto; display: block; } /* Blurred highlight effect */ .highlight-glow { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: radial-gradient(circle at center, var(--primary-color) 0%, transparent 70%); opacity: 0; z-index: -1; transition: opacity 0.3s ease; } .notification-item:hover .highlight-glow { opacity: 0.1; } </style> </head> <body> <div class="container"> <div class="notification-bell" id="notificationBell"> <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"> <path d="M12 22c1.1 0 2-.9 2-2h-4c0 1.1.9 2 2 2zm6-6v-5c0-3.07-1.64-5.64-4.5-6.32V4c0-.83-.67-1.5-1.5-1.5s-1.5.67-1.5 1.5v.68C7.63 5.36 6 7.92 6 11v5l-2 2v1h16v-1l-2-2z"/> </svg> <div class="notification-badge" id="notificationBadge">5</div> </div> <div class="notification-panel" id="notificationPanel"> <div class="panel-header"> <h2 class="panel-title">Notifications</h2> <div class="panel-actions"> <button class="action-btn" id="filterBtn"> <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"> <polygon points="22 3 2 3 10 12.46 10 19 14 21 14 12.46 22 3"></polygon> </svg> <div class="filter-highlight" id="filterHighlight">!</div> </button> <button class="action-btn" id="markAllReadBtn">Mark all read</button> </div> </div> <div class="tab-control"> <button class="tab-btn active" data-tab="all">All</button> <button class="tab-btn" data-tab="mentions">Mentions</button> <button class="tab-btn" data-tab="comments">Comments</button> </div> <div class="notification-list" id="notificationList"> <div class="notification-group"> <div class="group-header">New</div> <div class="notification-item unread new"> <div class="notification-avatar"> <img src="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMDAgMjAwIj48cmVjdCB3aWR0aD0iMjAwIiBoZWlnaHQ9IjIwMCIgZmlsbD0iIzZjNWNlNyIvPjx0ZXh0IHg9IjUwJSIgeT0iNTAlIiBmb250LXNpemU9IjgwIiB0ZXh0LWFuY2hvcj0ibWlkZGxlIiBkeT0iLjNlbSIgZm9udC1mYW1pbHk9IkFyaWFsIiBmaWxsPSJ3aGl0ZSI+SlM8L3RleHQ+PC9zdmc+" alt="Jamie Smith"> <div class="notification-type type-like"> <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"> <path d="M12 21.35l-1.45-1.32C5.4 15.36 2 12.28 2 8.5 2 5.42 4.42 3 7.5 3c1.74 0 3.41.81 4.5 2.09C13.09 3.81 14.76 3 16.5 3 19.58 3 22 5.42 22 8.5c0 3.78-3.4 6.86-8.55 11.54L12 21.35z"/> </svg> </div> </div> <div class="notification-content"> <p class="notification-text"><span>Jamie Smith</span> liked your photo from the "Summer Vibes" album</p> <div class="notification-time"> <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"> <circle cx="12" cy="12" r="10"></circle> <polyline points="12 6 12 12 16 14"></polyline> </svg> Just now </div> <div class="notification-media"> <img src="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAzMDAgMTUwIj48cmVjdCB3aWR0aD0iMzAwIiBoZWlnaHQ9IjE1MCIgZmlsbD0iIzAwY2VjOSIvPjxjaXJjbGUgY3g9IjgwIiBjeT0iNDAiIHI9IjI1IiBmaWxsPSIjZmRjYjZlIi8+PHBhdGggZD0iTTAsOTUgTDUwLDgwIEwxMDAsMTEwIEwxNTAsNzAgTDIwMCwxMDAgTDI1MCw4MCBMMzAwLDEyMCBMMzAwLDE1MCBMMCwxNTAgWiIgZmlsbD0iIzZjNWNlNyIvPjwvc3ZnPg==" alt="Summer Vibes photo"> </div> </div> <div class="highlight-glow"></div> </div> <div class="notification-item unread"> <div class="notification-avatar"> <img src="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMDAgMjAwIj48cmVjdCB3aWR0aD0iMjAwIiBoZWlnaHQ9IjIwMCIgZmlsbD0iIzAwYmZhNSIvPjx0ZXh0IHg9IjUwJSIgeT0iNTAlIiBmb250LXNpemU9IjgwIiB0ZXh0LWFuY2hvcj0ibWlkZGxlIiBkeT0iLjNlbSIgZm9udC1mYW1pbHk9IkFyaWFsIiBmaWxsPSJ3aGl0ZSI+QVA8L3RleHQ+PC9zdmc+" alt="Alex Parker"> <div class="notification-type type-comment"> <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"> <path d="M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z"></path> </svg> </div> </div> <div class="notification-content"> <p class="notification-text"><span>Alex Parker</span> commented on your post about the new design system</p> <div class="notification-time"> <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"> <circle cx="12" cy="12" r="10"></circle> <polyline points="12 6 12 12 16 14"></polyline> </svg> 10 minutes ago </div> <p class="notification-text" style="color: var(--text-secondary); font-style: italic; margin-top: 6px; padding-left: 8px; border-left: 2px solid var(--glass-border);"> "Love the glassmorphism approach! The transparency effects are quite stunning." </p> <div class="interaction-buttons"> <button class="interaction-btn">Reply</button> <button class="interaction-btn">Like</button> </div> </div> <div class="highlight-glow"></div> </div> </div> <div class="notification-group"> <div class="group-header">Earlier today</div> <div class="notification-item unread"> <div class="notification-avatar"> <img src="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMDAgMjAwIj48cmVjdCB3aWR0aD0iMjAwIiBoZWlnaHQ9IjIwMCIgZmlsbD0iI2ZkNzlhOCIvPjx0ZXh0IHg9IjUwJSIgeT0iNTAlIiBmb250LXNpemU9IjgwIiB0ZXh0LWFuY2hvcj0ibWlkZGxlIiBkeT0iLjNlbSIgZm9udC1mYW1pbHk9IkFyaWFsIiBmaWxsPSJ3aGl0ZSI+RVI8L3RleHQ+PC9zdmc+" alt="Emily Rodriguez"> <div class="notification-type type-mention"> <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"> <path d="M16.5 12a4.5 4.5 0 1 1-9 0 4.5 4.5 0 0 1 9 0z"/> <path d="M12 2a10 10 0 1 0 10 10A10 10 0 0 0 12 2zm0 16.5a6.5 6.5 0 1 1 6.5-6.5 6.51 6.51 0 0 1-6.5 6.5z"/> </svg> </div> </div> <div class="notification-content"> <p class="notification-text"><span>Emily Rodriguez</span> mentioned you in a comment on the "Design Trends 2023" discussion</p> <div class="notification-time"> <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"> <circle cx="12" cy="12" r="10"></circle> <polyline points="12 6 12 12 16 14"></polyline> </svg> 3 hours ago </div> </div> <div class="highlight-glow"></div> </div> <div class="notification-item"> <div class="notification-avatar"> <img src="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMDAgMjAwIj48cmVjdCB3aWR0aD0iMjAwIiBoZWlnaHQ9IjIwMCIgZmlsbD0iIzA5ODRlMyIvPjx0ZXh0IHg9IjUwJSIgeT0iNTAlIiBmb250LXNpemU9IjgwIiB0ZXh0LWFuY2hvcj0ibWlkZGxlIiBkeT0iLjNlbSIgZm9udC1mYW1pbHk9IkFyaWFsIiBmaWxsPSJ3aGl0ZSI+TUw8L3RleHQ+PC9zdmc+" alt="Marcus Lee"> <div class="notification-type type-follow"> <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"> <path d="M16 21v-2a4 4 0 0 0-4-4H5a4 4 0 0 0-4 4v2"></path> <circle cx="8.5" cy="7" r="4"></circle> <line x1="20" y1="8" x2="20" y2="14"></line> <line x1="23" y1="11" x2="17" y2="11"></line> </svg> </div> </div> <div class="notification-content"> <p class="notification-text"><span>Marcus Lee</span> started following you</p> <div class="notification-time"> <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"> <circle cx="12" cy="12" r="10"></circle> <polyline points="12 6 12 12 16 14"></polyline> </svg> 5 hours ago </div> <div class="interaction-buttons"> <button class="interaction-btn">Follow back</button> <button class="interaction-btn">Dismiss</button> </div> </div> <div class="highlight-glow"></div> </div> <div class="notification-item"> <div class="notification-avatar"> <img src="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAyMDAgMjAwIj48cmVjdCB3aWR0aD0iMjAwIiBoZWlnaHQ9IjIwMCIgZmlsbD0iI2UxN2Q3NCIvPjx0ZXh0IHg9IjUwJSIgeT0iNTAlIiBmb250LXNpemU9IjgwIiB0ZXh0LWFuY2hvcj0ibWlkZGxlIiBkeT0iLjNlbSIgZm9udC1mYW1pbHk9IkFyaWFsIiBmaWxsPSJ3aGl0ZSI+U088L3RleHQ+PC9zdmc+" alt="Sofia Ortiz"> <div class="notification-type type-like"> <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"> <path d="M12 21.35l-1.45-1.32C5.4 15.36 2 12.28 2 8.5 2 5.42 4.42 3 7.5 3c1.74 0 3.41.81 4.5 2.09C13.09 3.81 14.76 3 16.5 3 19.58 3 22 5.42 22 8.5c0 3.78-3.4 6.86-8.55 11.54L12 21.35z"/> </svg> </div> </div> <div class="notification-content"> <p class="notification-text"><span>Sofia Ortiz</span> and 12 others liked your UI component showcase</p> <div class="notification-time"> <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"> <circle cx="12" cy="12" r="10"></circle> <polyline points="12 6 12 12 16 14"></polyline> </svg> 8 hours ago </div> </div> <div class="highlight-glow"></div> </div> </div> <div class="ghost-badge" id="emptyState"> <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"> <path d="M21 11.5a8.38 8.38 0 0 1-.9 3.8 8.5 8.5 0 0 1-7.6 4.7 8.38 8.38 0 0 1-3.8-.9L3 21l1.9-5.7a8.38 8.38 0 0 1-.9-3.8 8.5 8.5 0 0 1 4.7-7.6 8.38 8.38 0 0 1 3.8-.9h.5a8.48 8.48 0 0 1 8 8v.5z"></path> </svg> <p>No notifications to show.<br>Check back later!</p> </div> </div> <div class="panel-footer"> <button class="view-all-btn">View all notifications</button> </div> </div> </div> <script> document.addEventListener('DOMContentLoaded', function() { const notificationBell = document.getElementById('notificationBell'); const notificationPanel = document.getElementById('notificationPanel'); const notificationBadge = document.getElementById('notificationBadge'); const filterBtn = document.getElementById('filterBtn'); const filterHighlight = document.getElementById('filterHighlight'); const markAllReadBtn = document.getElementById('markAllReadBtn'); const tabButtons = document.querySelectorAll('.tab-btn'); const notificationList = document.getElementById('notificationList'); const emptyState = document.getElementById('emptyState'); let isOpen = false; let activeFilter = 'all'; let hasUnreadNotifications = true; let filterActive = false; // Toggle notification panel notificationBell.addEventListener('click', function(e) { e.stopPropagation(); isOpen = !isOpen; if (isOpen) { notificationPanel.classList.add('active'); // Reset badge count when panel opens if (hasUnreadNotifications) { notificationBadge.textContent = '0'; hasUnreadNotifications = false; } } else { notificationPanel.classList.remove('active'); } }); // Close panel when clicking outside document.addEventListener('click', function(e) { if (isOpen && !notificationPanel.contains(e.target) && e.target !== notificationBell) { notificationPanel.classList.remove('active'); isOpen = false; } }); // Prevent panel closing when clicking inside notificationPanel.addEventListener('click', function(e) { e.stopPropagation(); }); // Toggle filter highlight filterBtn.addEventListener('click', function() { filterActive = !filterActive; if (filterActive) { filterHighlight.classList.add('active'); // Simulate filtering to only show unread const items = document.querySelectorAll('.notification-item'); items.forEach(item => { if (!item.classList.contains('unread')) { item.style.display = 'none'; } }); // Show empty state if no unread notifications const visibleItems = document.querySelectorAll('.notification-item[style="display: none;"]'); if (visibleItems.length === items.length) { emptyState.style.display = 'flex'; } } else { filterHighlight.classList.remove('active'); // Reset display const items = document.querySelectorAll('.notification-item'); items.forEach(item => { item.style.display = 'flex'; }); emptyState.style.display = 'none'; } }); // Mark all as read markAllReadBtn.addEventListener('click', function() { const unreadItems = document.querySelectorAll('.notification-item.unread'); unreadItems.forEach(item => { item.classList.remove('unread'); }); // Update badge notificationBadge.textContent = '0'; hasUnreadNotifications = false; }); // Tab switching tabButtons.forEach(button => { button.addEventListener('click', function() { // Update active state tabButtons.forEach(btn => btn.classList.remove('active')); this.classList.add('active'); // Get tab type activeFilter = this.dataset.tab; // Filter notifications const items = document.querySelectorAll('.notification-item');