
/* FM MENU */

#menuToggle input.menuInput {
  display: none;
}

@media (max-width: 1200px) {
  body {
    overflow: hidden;
  }

  #menuToggle {
    display: block;
    position: absolute;
    top: 35px;
    right: 0;

    z-index: 30;

    -webkit-user-select: none;
    user-select: none;
  }

  #menuToggle nav#block-fm-main-menu {
    position: relative;
    left: auto;
    transform: none;
    bottom: auto;
  }

  #menuToggle input.menuInput:checked ~ .menuContent nav ul {
    padding: 0;
  }
  #menuToggle input.menuInput:checked ~ .menuContent nav ul li {
    display: block;
    margin: 0;
  }
  #menuToggle input.menuInput:checked ~ .menuContent nav ul li {
    display: block;
  }
  #menuToggle input.menuInput:checked ~ .menuContent #block-fm-search,
  #menuToggle input.menuInput:checked ~ .menuContent #block-social {
    display: block;
    position: relative;
    margin: 10px 0;
    left: auto;
    right: auto;
    top: auto;
    bottom: auto;
  }

  #menuToggle input.menuInput {
    display: block;
    width: 32px;
    height: 32px;
    position: absolute;
    top: -7px;
    left: -5px;

    cursor: pointer;

    opacity: 0; /* hide this */
    z-index: 99; /* and place it over the hamburger */

    -webkit-touch-callout: none;
  }

  /*
   * Just a quick hamburger
   */
  #menuToggle span {
    display: block;
    width: 33px;
    height: 4px;
    margin-bottom: 5px;
    position: relative;

    background: #cdcdcd;
    border-radius: 3px;

    z-index: 90;

    transform-origin: 4px 0px;

    transition: transform 0.5s cubic-bezier(0.77, 0.2, 0.05, 1.0),
    background 0.5s cubic-bezier(0.77, 0.2, 0.05, 1.0),
    opacity 0.55s ease;
  }

  #menuToggle span:first-child {
    transform-origin: 0% 0%;
  }

  #menuToggle span:nth-last-child(2) {
    transform-origin: 0% 100%;
  }

  /*
   * Transform all the slices of hamburger
   * into a crossmark.
   */
  #menuToggle input.menuInput:checked ~ span {
    opacity: 1;
    transform: rotate(45deg) translate(-1px, -1px);
    background: #232323;
  }

  /*
   * But let's hide the middle one.
   */
  #menuToggle input.menuInput:checked ~ span:nth-of-type(2) {
    opacity: 0;
    transform: rotate(0deg) scale(0.2, 0.2);
  }

  /*
   * Ohyeah and the last one should go the other direction
   */
  #menuToggle input.menuInput:checked ~ span:nth-of-type(3) {
    transform: rotate(-45deg) translate(0, -3px);
  }

  /*
   * Make this absolute positioned
   * at the top left of the screen
   */
  #menuToggle .menuContent {
    position: fixed;
    right: 0;
    top: 0;
    z-index: 20;
    width: 30%;
    height: 100%;
    padding: 200px 50px;

    background: #ededed;
    list-style-type: none;
    -webkit-font-smoothing: antialiased;
    /* to stop flickering of text in safari */

    transform-origin: 0% 0%;
    transform: translate(200%, 0);

    transition: transform 0.5s cubic-bezier(0.77, 0.2, 0.05, 1.0);
  }

  /*#menuToggle ul li*/
  /*{*/
  /*  padding: 10px 0;*/
  /*  font-size: 22px;*/
  /*}*/
  /*
   * And let's slide it in from the left
   */
  #menuToggle input.menuInput:checked ~ .menuContent {
    transform: none;
  }
}


/* END FM MENU */
