LOADING...

Preview

Pen ID
Unlock Campus Themeforest adv

 

Code
CSS
* {
  box-sizing: border-box;
  -webkit-box-sizing: border-box;
}

body {
  font-size: 14px;
  font-family: "Poppins", sans-serif;
  line-height: normal;
  margin: 0;
  padding: 0;
  background-color: #ddd;
}

.header {
  background: #0984e3;
  height: 60px;
}
.header .container {
  position: relative;
  padding: 0;
}
.header .container > * {
  position: static !important;
  padding: 0;
}
.header .container .logo a {
  font-size: 2.5em;
  font-weight: 600;
  letter-spacing: 1px;
  color: #fff;
  text-decoration: none;
  text-transform: uppercase;
  line-height: 60px;
}
.header .container .menu > ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.header .container .menu > ul > li {
  float: left;
}
.header .container .menu > ul > li:hover > a {
  background-color: rgba(255, 255, 255, 0.1);
}
.header .container .menu > ul > li:hover > div.sub-menu {
  pointer-events: auto;
  transform: translateY(0);
  opacity: 1;
}
.header .container .menu > ul > li > a {
  font-size: 1em;
  letter-spacing: 1px;
  color: #fff;
  text-decoration: none;
  text-transform: uppercase;
  padding: 0 15px;
  line-height: 60px;
  display: block;
  -webkit-transition: all 0.2s linear;
  -moz-transition: all 0.2s linear;
  -o-transition: all 0.2s linear;
  transition: all 0.2s linear;
}
.header .container .menu > ul > li > a i {
  font-size: 17px;
  display: inline-block;
  vertical-align: middle;
  margin: -2px 0 0 -4px;
}
.header .container .menu > ul > li .sub-menu {
  position: absolute;
  height: 280px;
  background-color: #fff;
  display: block;
  left: 0;
  padding: 0;
  pointer-events: none;
  transform: translateY(10px);
  opacity: 0;
  -webkit-transition: all 0.3s linear;
  -moz-transition: all 0.3s linear;
  -o-transition: all 0.3s linear;
  transition: all 0.3s linear;
  box-shadow: 0 3px 5px rgba(0, 0, 0, 0.05);
  overflow: hidden;
}
.header .container .menu > ul > li .sub-menu.none-tab .content {
  width: 100%;
  display: block;
}
.header .container .menu > ul > li .sub-menu.none-tab .content .tab-panel-left > ul.categories {
  height: 100%;
  overflow-x: hidden;
}
.header .container .menu > ul > li .sub-menu .tabs-icon {
  width: 5%;
  float: left;
  height: 100%;
}
.header .container .menu > ul > li .sub-menu .tabs-icon a {
  display: block;
  height: calc(100% / 6);
  background-color: #032e50;
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
  color: #fff;
  font-size: 24px;
  text-align: center;
  -webkit-transition: all 0.2s linear;
  -moz-transition: all 0.2s linear;
  -o-transition: all 0.2s linear;
  transition: all 0.2s linear;
}
.header .container .menu > ul > li .sub-menu .tabs-icon a em {
  position: relative;
  top: 50%;
  transform: translateY(-50%);
  display: inline-block;
}
.header .container .menu > ul > li .sub-menu .content {
  width: 95%;
  float: right;
  height: 100%;
  display: none;
}
.header .container .menu > ul > li .sub-menu .content[data-content="windows"] {
  display: block;
}
.header .container .menu > ul > li .sub-menu .content > * {
  float: left;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-left {
  width: 20%;
  height: 100%;
  background-color: #03a9f4;
  padding: 10px 0;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-left > ul {
  list-style: none;
  margin: 0 5px 0 0;
  padding: 0 5px 0 0;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-left > ul.popular {
  height: 40%;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  margin-bottom: 20px;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-left > ul.popular > li > a i {
  font-size: 17px;
  display: inline-block;
  vertical-align: top;
  margin-right: 5px;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-left > ul.categories {
  height: calc(60% - 20px);
  overflow-x: hidden;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-left > ul::-webkit-scrollbar-track {
  background-color: transparent;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-left > ul::-webkit-scrollbar {
  width: 8px;
  background-color: transparent;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-left > ul::-webkit-scrollbar-thumb {
  background-color: rgba(255, 255, 255, 0.2);
  border-radius: 5px;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-left > ul > li > a {
  font-size: .9em;
  font-weight: 500;
  letter-spacing: .02em;
  color: #fff;
  text-decoration: none;
  text-transform: uppercase;
  padding: 8px 15px;
  display: block;
  -webkit-transition: all 0.2s linear;
  -moz-transition: all 0.2s linear;
  -o-transition: all 0.2s linear;
  transition: all 0.2s linear;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-left > ul > li > a:hover {
  background-color: rgba(255, 255, 255, 0.1);
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-right {
  width: 80%;
  height: 100%;
  background-color: #fff;
  padding: 20px;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-right .list {
  text-align: center;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-right .list .item {
  width: 30%;
  height: auto;
  display: inline-block;
  vertical-align: top;
  margin: 0 10px;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-right .list .item a {
  text-decoration: none;
  display: block;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-right .list .item a:hover .name {
  border-color: #ddd;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-right .list .item a:hover .name strong.title {
  color: #0984e3;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-right .list .item a:hover .image .img {
  transform: scale(1.1, 1.1);
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-right .list .item a .image {
  width: 100%;
  height: 160px;
  overflow: hidden;
  position: relative;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-right .list .item a .image .img {
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center center;
  -webkit-transition: all 0.3s linear;
  -moz-transition: all 0.3s linear;
  -o-transition: all 0.3s linear;
  transition: all 0.3s linear;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-right .list .item a .image .time {
  position: absolute;
  right: 10px;
  bottom: 10px;
  background-color: rgba(0, 0, 0, 0.8);
  color: #fff;
  font-size: .8em;
  font-weight: 500;
  padding: 5px 8px;
  letter-spacing: 1px;
  border-radius: 2px;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-right .list .item a .image .icon {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translateY(-50%) translateX(-50%);
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background-color: #ff3333;
  text-align: center;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-right .list .item a .image .icon i {
  font-size: 32px;
  color: #fff;
  display: inline-block;
  margin-top: 8px;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-right .list .item a .name {
  text-align: left;
  position: relative;
  padding: 10px;
  border-bottom: 1px solid transparent;
  -webkit-transition: all 0.2s linear;
  -moz-transition: all 0.2s linear;
  -o-transition: all 0.2s linear;
  transition: all 0.2s linear;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-right .list .item a .name span.cat {
  display: block;
  font-size: .86em;
  color: #777;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 2px;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-right .list .item a .name strong.title {
  font-family: "Poppins", sans-serif;
  font-weight: 700;
  color: #333;
  font-size: 1em;
  -webkit-transition: all 0.2s linear;
  -moz-transition: all 0.2s linear;
  -o-transition: all 0.2s linear;
  transition: all 0.2s linear;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-right .list .item a .name p.capt {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: .9em;
  color: #888;
  margin: 0;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-right .list .item a .name .license {
  font-size: .92em;
  font-weight: 500;
  margin-top: 5px;
  display: block;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-right .list .item a .name .license.free {
  color: #1aff1a;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-right .list .item a .name .license.paid {
  color: #cc0000;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-right .list .item a .name .rating {
  position: absolute;
  right: 0;
  bottom: 9px;
}
.header .container .menu > ul > li .sub-menu .content .tab-panel-right .list .item a .name .rating i {
  font-size: 16px;
  display: inline-block;
  vertical-align: top;
  margin: 0 -2px;
  color: #777;
}
.header .container .search {
  position: relative;
  width: 80%;
  line-height: 60px;
}
.header .container .search input {
  font-family: "Poppins", sans-serif;
  font-weight: 300;
  color: #fff;
  width: 100%;
  border: 0 solid;
  background-color: rgba(255, 255, 255, 0.1);
  padding: 0 10px 0 15px;
  border-radius: 2px;
  letter-spacing: 1px;
  outline: none;
  -webkit-transition: all 0.2s linear;
  -moz-transition: all 0.2s linear;
  -o-transition: all 0.2s linear;
  transition: all 0.2s linear;
}
.header .container .search input::-webkit-input-placeholder {
  color: rgba(255, 255, 255, 0.5);
}
.header .container .search input::-moz-placeholder {
  color: rgba(255, 255, 255, 0.5);
}
.header .container .search input:-ms-input-placeholder {
  color: rgba(255, 255, 255, 0.5);
}
.header .container .search input:-moz-placeholder {
  color: rgba(255, 255, 255, 0.5);
}
.header .container .search input:focus {
  background-color: rgba(255, 255, 255, 0.2);
}
.header .container .search button {
  background-color: transparent;
  outline: none;
  border: 0 solid;
  position: absolute;
  right: 0;
  top: 0;
  cursor: pointer;
  padding: 0 10px;
  -webkit-transition: all 0.2s linear;
  -moz-transition: all 0.2s linear;
  -o-transition: all 0.2s linear;
  transition: all 0.2s linear;
}
.header .container .search button:hover {
  background-color: rgba(255, 255, 255, 0.1);
}
.header .container .search button i {
  color: #fff;
  line-height: 60px;
}
.header .container .user {
  width: 20%;
}
.header .container .user .icon a {
  text-decoration: none;
  display: block;
  text-align: center;
  -webkit-transition: all 0.2s linear;
  -moz-transition: all 0.2s linear;
  -o-transition: all 0.2s linear;
  transition: all 0.2s linear;
}
.header .container .user .icon a i {
  color: #fff;
  line-height: 60px;
}
.header .container .user .icon a:hover {
  background-color: rgba(255, 255, 255, 0.1);
}
.header .container .search,
.header .container .user {
  float: left;
}
JS
$(function(){
  
  var $tabIcon          = $('.sub-menu.tab-a > .tabs-icon > a');
  var $tabIconSelected  = $('.sub-menu.tab-a > .tabs-icon > a.selected');
  var $tabContent       = $('.sub-menu.tab-a > .content');
  var $mainColor        = "#032e50";
  
  var $dataColor = $tabIconSelected.data('color');
  $tabIconSelected.css('background-color', $dataColor);
  
  $tabIcon.hover(function(){
    var $dataTitle  = $(this).data('title');
    var $dataColor  = $(this).data('color');
    
    $tabIcon.removeClass('selected').css('background-color', $mainColor);
    $(this).addClass('selected').css('background-color', $dataColor);
    
    $tabContent.each(function(){
      var $dataContent = $(this).data('content');
      
      if($dataTitle == $dataContent){
        $tabContent.hide();
        $(this).fadeIn().find('>.tab-panel-left').css('background-color', $dataColor);
      }
    });
    
  },function(){
    $(this).not('.selected').css('background-color', $mainColor);
  });
});

Description

menu and drop-down menu
Term
Sat, 04/14/2018 - 20:48

Related Codes

Pen ID
Pen ID
Pen ID
Square Adv