DevPlatform
Home
Components
Search
Submit
Earn
Login
Sign Up Free
Layered 3D Card - Preview | DevPlatform
DevPlatform
Categories
Accordion
Animation
Box Shadow
Button
Card
Footer
Form
Gallery
Hero Section
Inputs
Loader
Marquee
Modal
Modules
Navbar
Progress Bar
Radio Buttons
Search-Bar
Sections
Slider
Tab
Timeline
Toggle
Layered 3D Card
abhishek001
Jan 25, 2026
2
0
Share
Live Preview
Refresh
Live Editor
HTML
CSS
JS
HTML
CSS
JavaScript
1
<div class="container"> <div class="layered-card"> <div class="layer layer-3"></div> <div class="layer layer-2"></div> <div class="layer layer-1"> <div class="card-header"> <span class="badge">New Release</span> <span class="card-number">01</span> </div> <div class="card-icon">⚡</div> <h3 class="card-title">Layered Depth Effect</h3> <p class="card-description"> This card has multiple layers that separate when you hover, creating a stunning depth effect with smooth animations. </p> <div class="card-stats"> <div class="stat"> <div class="stat-value">3</div> <div class="stat-label">Layers</div> </div> <div class="stat"> <div class="stat-value">60fps</div> <div class="stat-label">Smooth</div> </div> <div class="stat"> <div class="stat-value">100%</div> <div class="stat-label">CSS</div> </div> </div> <button class="card-btn"> <span>Explore More</span> <svg width="16" height="16" viewBox="0 0 16 16" fill="none"> <path d="M3 8H13M13 8L9 4M13 8L9 12" stroke="currentColor" stroke-width="2" stroke-linecap="round"/> </svg> </button> </div> </div> </div>
1
* { margin: 0; padding: 0; box-sizing: border-box; } body { font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 2rem; } .container { max-width: 450px; width: 100%; perspective: 1000px; } h1 { text-align: center; color: white; font-size: 2.5rem; margin-bottom: 3rem; text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2); } .layered-card { position: relative; width: 100%; min-height: 500px; transform-style: preserve-3d; transition: all 0.5s ease; cursor: pointer; } .layer { position: absolute; width: 100%; height: 100%; border-radius: 20px; box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3); transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275); } .layer-1 { position: relative; transform: translateZ(0px); padding: 2.5rem; z-index: 3; background: white; display: flex; flex-direction: column; gap: 1.5rem; } .layer-2 { transform: translateZ(-20px) scale(0.95); background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); opacity: 0.5; } .layer-3 { transform: translateZ(-40px) scale(0.90); background: linear-gradient(135deg, #764ba2 0%, #667eea 100%); opacity: 0.3; } .layered-card:hover .layer-1 { transform: translateZ(40px); } .layered-card:hover .layer-2 { transform: translateZ(-5px) scale(0.97); opacity: 0.7; } .layered-card:hover .layer-3 { transform: translateZ(-25px) scale(0.93); opacity: 0.5; } .card-header { display: flex; justify-content: space-between; align-items: center; } .badge { display: inline-block; padding: 0.5rem 1rem; background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); color: white; border-radius: 20px; font-size: 0.85rem; font-weight: 600; } .card-number { font-size: 3rem; font-weight: 700; color: #f0f0f0; } .card-icon { width: 70px; height: 70px; background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); border-radius: 14px; display: flex; align-items: center; justify-content: center; font-size: 2.25rem; box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4); } .card-title { font-size: 1.75rem; font-weight: 700; color: #1a202c; line-height: 1.3; } .card-description { color: #718096; line-height: 1.7; font-size: 1.05rem; } .card-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; padding: 1.5rem 0; border-top: 1px solid #e2e8f0; border-bottom: 1px solid #e2e8f0; } .stat { text-align: center; } .stat-value { font-size: 1.5rem; font-weight: 700; color: #667eea; margin-bottom: 0.25rem; } .stat-label { font-size: 0.85rem; color: #718096; text-transform: uppercase; letter-spacing: 0.5px; } .card-btn { display: flex; align-items: center; justify-content: center; gap: 0.5rem; padding: 1rem 1.75rem; background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); color: white; border: none; border-radius: 10px; font-weight: 600; font-size: 1rem; cursor: pointer; transition: all 0.3s ease; box-shadow: 0 5px 20px rgba(102, 126, 234, 0.3); } .card-btn:hover { transform: translateY(-3px); box-shadow: 0 10px 30px rgba(102, 126, 234, 0.5); } @media (max-width: 768px) { h1 { font-size: 2rem; margin-bottom: 2rem; } .layered-card { min-height: 450px; } .layer-1 { padding: 2rem; } .card-stats { gap: 0.75rem; } .stat-value { font-size: 1.25rem; } }
1
Comments
0
Want to comment?
Please
login
or
sign up
to post comments.
No comments yet
Be the first to comment on this component!
Comments 0
Want to comment?
Please login or sign up to post comments.
No comments yet
Be the first to comment on this component!