Pure CSS Slide Out Menu
How do I make an pure css slide out menu?
A slide out menu that does not require JS to function properly - all handled by CSS and 100% functional.. What is a pure css slide out menu? How do you make a pure css slide out menu? This script and codes were developed by James Zedd on 11 October 2022, Tuesday.
Pure CSS Slide Out Menu - Script Codes HTML Codes
<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>Pure CSS Slide Out Menu</title> <link rel='stylesheet prefetch' href='https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css'> <link rel="stylesheet" href="css/style.css">
</head>
<body> <input type="checkbox" id="menu-toggle" />
<label for="menu-toggle" class="menu-icon"><i class="fa fa-bars"></i></label>
<div class="content-container"> <div class="site-title"> <h1>Elite World Explorer</h1> </div> <div class="content"> <h1>5 Best Desinations in the World</h1> <img src="https://placehold.it/700x250" alt="" class="" /> <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Suspendisse eget nulla mollis, efficitur urna nec, viverra dolor. Nulla facilisi. Interdum et malesuada fames ac ante ipsum primis in faucibus. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Praesent efficitur finibus eros sit amet sagittis. Ut sollicitudin sodales neque et volutpat. Curabitur dictum ante vel fermentum volutpat. Curabitur ac neque et erat viverra egestas.</p> </div>
</div>
<div class="slideout-sidebar"> <ul> <li>Home</li> <li>Catalog</li> <li>About Us</li> <li>Blog</li> <li>Contact</li> </ul>
</div> <script src="js/index.js"></script>
</body>
</html>
Pure CSS Slide Out Menu - Script Codes CSS Codes
body { font-family: 'Lato', arial, sans-serif; margin: 0;
}
/* -- main content -- */
.content-container { position: relative; z-index: 0; padding: 20px; max-width: 700px; margin: 0 auto; overflow: hidden; transition: all 300ms ease-in-out;
}
.site-title { text-align: center; border-bottom: 1px solid #111111; margin-bottom: 24px;
}
.site-title h1 { font-weight: 300; text-transform: uppercase; letter-spacing: 10px;
}
img { width: 100%;
}
.content p { line-height: 1.6em; margin-bottom: 24px;
}
/* -- Slideout Sidebar -- */
.slideout-sidebar { position: fixed; top: 0; left: -190px; z-index: 0; width: 150px; height: 100%; padding: 20px; background-color: #212121; transition: all 300ms ease-in-out;
}
.slideout-sidebar ul { list-style: none; margin: 0; padding: 0;
}
.slideout-sidebar ul li { cursor: pointer; padding: 18px 0; border-bottom: 1px solid rgba(244,244,244,0.4); color: rgba(244,244,244,0.7);
}
.slideout-sidebar ul li:last-child { border-bottom: 0;
}
.slideout-sidebar ul li:hover { color: rgba(244,244,244,1);
}
/* -- Menu Icon -- */
#menu-toggle { display: none;
}
.menu-icon { position: absolute; top: 18px; left: 30px; font-size: 24px; z-index: 1; transition: all 300ms ease-in-out;
}
/*-- The Magic --*/
#menu-toggle:checked ~ .slideout-sidebar { left: 0px;
}
#menu-toggle:checked + .menu-icon { left: 210px;
}
#menu-toggle:checked ~ .content-container { padding-left: 190px;
}
/* -- Media Queries -- */
@media (max-width: 991px) { .content-container { max-width: 480px; }
}
@media (max-width: 767px) { .content-container { max-width: 100%; margin: 30px auto 0; } #menu-toggle:checked ~ .content-container { padding-left: 0; } .slideout-sidebar ul { text-align: center; max-width: 200px; margin: 30px auto 0; } .menu-icon { left: 20px } #menu-toggle:checked ~ .slideout-sidebar { width: 100%; } #menu-toggle:checked + .menu-icon { left: 87%; color: #fafafa; } @media screen and (max-width: 736px) and (orientation: landscape) { .slideout-sidebar { padding: 0; } .slideout-sidebar ul { max-width: 100%; margin: 60px auto 0; } .slideout-sidebar ul li { display: inline-block; border-bottom: 0; width: 72px; padding: 18px 24px; margin: 0 6px 12px; color: #ffffff; background-color: #777; } }
}
Pure CSS Slide Out Menu - Script Codes JS Codes
// nothing to see here :P

Developer | James Zedd |
Username | james_zedd |
Uploaded | October 11, 2022 |
Rating | 4 |
Size | 2,907 Kb |
Views | 14,161 |
Find the perfect freelance services for your business! Fiverr's mission is to change how the world works together. Fiverr connects businesses with freelancers offering digital services in 500+ categories. Find Developer!
Name | Size |
HTML for IID | 1,792 Kb |
Responsive Advert | 2,354 Kb |
Flex | 2,796 Kb |
The Lonely Planet | 8,286 Kb |
Modern Responsive Product Comparison Table | 2,952 Kb |
Responsive Multi-Column Table with Links | 4,956 Kb |
Flex Chart | 4,111 Kb |
Pure CSS Pop Up Modal | 2,858 Kb |
Price | 3,043 Kb |
Simple Package Tier Display | 2,522 Kb |
Jasper is the AI Content Generator that helps you and your team break through creative blocks to create amazing, original content 10X faster. Discover all the ways the Jasper AI Content Platform can help streamline your creative workflows. Start For Free!
Name | Username | Size |
Content Changer | Cliffpyles | 4,538 Kb |
Simple search using AngularJS | Haykou | 1,802 Kb |
Login with flip 3d animation | Mariusbalaj | 3,014 Kb |
Popup Modal | Aldlevine | 3,696 Kb |
Simple Carousel Pure CSS | Dangvanthanh | 4,080 Kb |
Mondrian | Chrisarmstrong | 2,787 Kb |
Responsive Table-less Shopping Cart | Alex_rodrigues | 6,637 Kb |
Simple content swap | Snografx | 1,859 Kb |
Calculator | Rzencoder | 4,572 Kb |
Loader | MikitaLisavets | 3,321 Kb |
Surf anonymously, prevent hackers from acquiring your IP address, send anonymous email, and encrypt your Internet connection. High speed, ultra secure, and easy to use. Instant setup. Hide Your IP Now!