/*
Theme Name:   Storefront - Feldhof Edition
Theme URI:    http://example.com/twenty-fifteen-child/
Description:  Storefront - Feldhof Edition
Author:       Fabian von Allmen
Template:     storefront
Version:      1.0.0
Text Domain:  storefront
*/ 

h1, h2, h3 {
  font-weight: bold;
}

.footer-widgets {
  border-bottom: none;
  padding: 0px;
}

.site-footer {
  padding: 1.618em 0; 
}

.site-branding {
  margin: 1em 0 0 0 !important;
}

.site-header {
  padding-top: 0px;
  border: none;
}

.site-header .site-branding img {
  width: auto;
  max-width: none;
  max-height: 4.5em;
}


.site-header-cart .cart-contents {
  text-align: right;
}

.site-header-cart .cart-contents .count {
  margin-right: .75em;
}

.storefront-secondary-navigation.woocommerce-active .site-header .secondary-navigation {
  margin-right: 0px;
  width: 70%; 
  margin-top: 2.2em;
  margin-bottom: .75em;
  float: right;
}

.secondary-navigation .menu {
  font-size: 1em;
}

.site-search {
  margin-top: 2.5em;
  margin-bottom: .75em;
}

.storefront-breadcrumb {
  margin: 0 0 1em 0;
  padding: 0;
}

.woocommerce-breadcrumb a:first-of-type::before {
  display: none;
}

.woocommerce-products-header {
  text-align: left !important;
}

.storefront-sorting {
  display: none;
}

.category-title > * {
  padding: .25em .5em .35em;
  border: 4px solid white;
  font-weight: 300;
}

/* body.page header.entry-header {
  display: none;
} */

#main {
  margin-top: 3em !important;
}

body.page-template-headerless #main {
  margin-top: 0em !important;
}

#content #main > header,
#content #main > article > header {
  padding-bottom: 3.5em !important;
}

body.page-template-headerless #content #main > header,
body.page-template-headerless #content #main > article > header {
  display: none;
}

.alignwide {
  margin-left: 0 !important;
  margin-right: 0 !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
}

.feldhof-cart-count {
  font-size: 0.70em;
  display: inline-block;
  width: 1.7em;
  background-color: #85B350;
  height: 1.7em;
  /* padding-top: 100%; */
  position: absolute;
  border-radius: 50%;
  text-align: center;
  vertical-align: middle;
  line-height: 1.7em;
  font-weight: bold;
  position: absolute;
  right: 0.25em;
  top: 0.75em;
  color: white;
}

.site-header {
  margin: 0 !important;
}

@media only screen and (max-width: 1080px) {
  .site-header {
    padding: 1em 0 0 !important;
    height: 5em;
  }
  .site-header .site-branding {
    position: absolute;
    top: .25em;
    left: 50%;
    width: auto;
    margin: 0 !important;
    transform: translateX(-50%);
    z-index: 9999;
  }
  .site-header .site-branding img {
    max-height: 4.5em;
  }

  #mega-menu-wrap-primary .mega-menu-toggle + #mega-menu-primary {
    top: 4.5em;
  }
}

/*
 * Some elements are mobile-styled by default and the
 * mobile properties are removed at the hardcoded
 * breakpoint of 768px, we have to adjust the styling
 * in two steps
 * 1. Make sure, that at the original breakpoint the e
 *    elemnents are still in 'mobile-mode'
 * 2. Activate mobile styling at the new breakpoint
 */

@media (min-width: 768px) {
  .site-search,
  .main-navigation, .secondary-navigation,
  .site-header-cart .cart-contents {
    display: none;
  }
  .col-full {
    max-width: none;
  }
  .site-header .site-branding {
    width: auto !important;
  }
  .woocommerce-active .site-header #mega-menu-wrap-primary {
    width: auto !important;
    margin-right: 0 !important;
    float: none !important;
  }

  .storefront-full-width-content .site-main ul.products.columns-4 li.product {
    width: auto;
    margin-right: 0;
    float: none;
  }
}

@media (min-width: 1080px) {
  .col-full {
    max-width: 1080px;
  }
  .site-search,
  .main-navigation, .secondary-navigation,
  .site-header-cart .cart-contents {
    display: block;
  }
  .woocommerce-active .site-header #mega-menu-wrap-primary {
    width: 100% !important;
    margin-right: 0 !important;
    float: left !important;
  }
  .storefront-full-width-content .site-main ul.products.columns-4 li.product {
    width: 21.7391304348%;
    float: left;
    margin-right: 4.347826087%;
  }

  body.sticky .storefront-primary-navigation {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background-color: #fafafa;
  }

  body.sticky {
    padding-top: 50px;
  }

  /* body.sticky .secondary-navigation {
    position: fixed;
    top: 0;
    width: 140px;
    left: calc( 50% + 300px );
    margin: 0 !important;
  } */
  
  /* body.sticky #mega-menu-wrap-primary {
    padding-left: 6em;
  } */

  /* body.sticky .site-branding {
    position: fixed;
    top: 0;
    z-index: 1000;
    margin-top: .4em !important;
  }
  body.sticky .site-branding img {
    max-height: 3.8em;
  } */
}