JSFiddle - React, Tailwind, and code Playground
HTML
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
<script src="https://code.jquery.com/jquery-3.2.1.min.js"></script>
<nav class="navbar-fixed-top sticky-nav">
<div class="container box-shadow">
<div class="row">
<div class="header-menu">
<div class="col-lg-2 col-md-2 col-sm-2 col-xs-2">
<a href="javascript:void(0)" id="expandBar"><img src="http://fakeimg.pl/50x50" class="logo-image" alt="logo" title="logo-image"></a>
</div>
<div class="col-lg-10 col-md-10 col-sm-10 col-xs-10">
<div>
<button class="btn btn-order btn-default btn-lg">order the
.a1</button>
</div>
</div>
</div>
</div>
</div>
</nav>
<div class="container box-shadow main-content" >
<div class="row">
<div id="sidebar" class="sidenav" >
<a href="index.html">home</a>
<a href="index.html">products</a>
<a href="index.html"><span>.a1 power amp</span></a>
<a href="about.html">about</a>
<a href="mailto:sayhi.ruby@gmail.com">contact</a>
<a href="https://www.instagram.com/ruby_audio" target="_blank">instagram</a>
<a href="https://www.facebook.com/ruby.audio" target="_blank">facebook</a>
</div>
</div>
<div class="row">
<img src="https://fakeimg.pl/1240x620/" class="img-responsive" alt="hero-image" title="ruby .a1">
</div>
<div class="row section">
<blockquote class="line">The a1 is our affordable 35W power amplifier, it's highly optimized hybrid design based
on a 6922 tube buffer stage and services feedback provides a delicately transparent, yet lush and music
reproduction with zero harsness....
CSS
body {
font-family: "HelveticaNeue-Light", "Helvetica Neue Light", "Helvetica Neue",
Helvetica, Arial, sans-serif;
}
.sticky-nav
{
background-color: #fff !important;
border: none;
}
.main-content
{
margin-top: 80px;
}
.box-shadow{
/*box-shadow: 12px 0 25px 0 #f1f1f1,
-12px 0 25px 0 #f1f1f1;*/
/*box-shadow: 12px 0 15px -6px #c1c1c1,
-12px 0 8px -6px #c1c1c1;*/
box-shadow: 0px 0px 16px 08px rgba(0, 0, 0, 0.2);
}
.box-shadow1{
/*box-shadow: 12px 0 25px 0 #f1f1f1,
-12px 0 25px 0 #f1f1f1;*/
/*box-shadow: 12px 0 15px -6px #c1c1c1,
-12px 0 8px -6px #c1c1c1;*/
box-shadow: 0px 0px 16px 08px rgba(0, 0, 0, 0.2);
}
/* The side navigation menu */
.sidenav {
height: 100%; /* 100% Full-height */
width: 0; /* 0 width - change this with JavaScript */
position: fixed; /* Stay in place */
z-index: 99; /* Stay on top */
background-color: #ff5844; /* Black*/
overflow-x: hidden; /* Disable horizontal scroll */
padding-top: 15px; /* Place content 60px from the top */
transition: 0.5s; /* 0.5 second transition effect to slide in the sidenav */
overflow-y: visible;
}
/* The navigation menu links */
.sidenav a {
padding: 10px 8px 0px 35px;
text-decoration: none;
font-size: 41px;
color: #ffffff;
display: block;
transition: 0.3s;
font-family: "Helvetica Light",Helvetica,sans-serif;
font-weight: 200;
}
.sidenav a span
{
font-size: 18px;
}
/* When you mouse over the navigation links, change their color */
.sidenav a:hover, .offcanvas a:focus{
color: #f1f1f1;
}
/* Position and style the close button (top right corner) */
.sidenav .closebtn {
position: absolute;
top: 0;
right: 25px;
font-size: 36px;
margin-left: 50px;
}
/* Style page content - use this if you want to push the page content to the right when you open the side navigation */
#main {
transition: margin-left .5s;
padding: 20px;
}
/* On smaller screens, where height is less than 450px, change the style of the sidenav (less padding and a smaller...
JavaScript
var expanded = false;
function openNav() {
var $device_width = $( window ).width();
if($device_width < 767 )
{
document.getElementById("sidebar").style.width = "250px";
}else {
document.getElementById("sidebar").style.width = "350px";
}
expanded = true;
}
/* Set the width of the side navigation to 0 */
function closeNav() {
document.getElementById("sidebar").style.width = "0";
expanded = false;
};
/* Set the width of the side navigation to 350px */
document.getElementById("expandBar").addEventListener("click", function() {
if(expanded) {
closeNav();
} else {
openNav();
}
});