@media only screen 
  and (max-device-width: 812px){

    /* GLOBALS */
    .desktop_layout{
      display: none !important;
    }
    .phone_layout{
      display: block !important;
    }

    body{
      max-width: 100vw;
    }
    .global_global_div{
        min-width: 0;
        width: 100vw;
        min-height: 100vh;
    }

    .global_frame_div{
        width: 100vw;
        min-width: 0px;
        max-width: 100vw;
        min-height: 0px;
        min-height: 100vh;
        background-color: #e5e5e5;
    }

    .body{
        max-width: 100vw;
        padding-bottom: 10px;
        background-color: #e5e5e5;
    }

    input[type="color"],
    input[type="date"],
    input[type="datetime"],
    input[type="datetime-local"],
    input[type="email"],
    input[type="month"],
    input[type="number"],
    input[type="password"],
    input[type="search"],
    input[type="tel"],
    input[type="text"],
    input[type="time"],
    input[type="url"],
    input[type="week"],
    select:focus,
    textarea {
      font-size: 17px !important;
    }

  .infoHelpBtn {
      position: absolute;
      top: 12px;
      right: 0px;
      height: 50px;
      width: 50px;
  }

  .infoHelp_inner {
    position: relative;
    margin: 90px auto;
    width: 90vw;
    height: auto;
    padding: 40px 10px;
    background-color: #ffffff;
    font-size: 16px;
    border: 1px solid black;
    border-radius: 15px;
    box-shadow: #000000 2px 2px 4px;
  }

  .login_form:focus{
    border: 1px solid rgba(0,0,0,0.2);
    box-shadow: 0px 0px 8px #fa7545;
  }

  .peche_button {
    width: 120px;
    height: 40px;
    line-height: 35px;
    background-color: #ffffff;
    border: 1px solid #fa7545;
    border-radius: 10px;
    color: #fa7545;
    text-align: center;
    font-weight: bold;
  }

  .newdeck_spec_button{
    background-color: #ffffff;
    color: #fa7545;
    border: 1px solid #fa7545;
  }

  .newspec_button{
    background-color: #ffffff;
    color: #fa7545;
    border: 1px solid #fa7545;
  }

  .phone_element_horizontal{
    width: 100%;
    height: auto;
    padding: 20px 10px;
    border-top: 1px solid #fa7545;
    border-bottom: 1px solid #fa7545;
    box-shadow: 0px 1px 3px #fa7545;
    background-color: #ffffff;
    margin: 15px auto;
    position: relative;
    overflow: hidden;
  }

  /* NAVBAR MOBILE */
  .navbar_peche{
    display: none !important;
  }

  .navbar_peche_mobile{
    width: 100vw;
    height: 60px;
    background-color: #ffffff;
    border-bottom: 1px solid #fa7545;
    box-shadow: 0px 1px 3px #fa7545;
    display: flex !important;
  }

  .navbar_mobile_element{
    flex: auto;
    width: 100%;
  }

  .navbar_brand_mobile{
   text-align: center;
   margin: auto;
   min-width: 100%;
  }

  .mobile_settings{
    height: 54px;
    position: absolute;
    right: 5px;
    top: 3px;
  }
  .mobile_menu{
    height: 56px;
    position: absolute;
    left: 5px;
    top: 4px;
  }

  .main_index_headerimg{
    height: 50px;
    width: auto;
    margin: 5px auto;
  }

  .navbar_mobile_loggedout{
    color: #fa7545;
    line-height: 60px;
    font-size: 18px;
    width: 100%;
    margin-left: 5px;
  }

  /* MENU BAR */
  .menubar_peche_mobile{
    width: 0vw;
    height: 100vh !important;
    display: none;
    background-color: #ffffff;
    height: auto;
    display: block !important;
    position: absolute;
    top: 64px;
    left: 0;
    z-index: 1000;
    overflow: hidden;
    transition: 0.5s ease-out;
  }

  .settingsbar_peche_mobile{
    width: 0vw;
    height: 100vh !important;
    display: none;
    background-color: #ffffff;
    height: auto;
    display: block !important;
    position: absolute;
    top: 64px;
    right: 0;
    z-index: 1000;
    overflow: hidden;
    transition: 0.5s ease-out;
  }

  .menubar_mobile_element{
    width: 100%;
    height: 90px;
    font-size: 28px;
    line-height: 90px;
    color: #000000;
    text-align: center;
    background-color: #ffffff;
    box-shadow: 3px 3px 6px -2px #fa7545;
    margin: 2px 0;
    border: none;
    color: #35a32c;
    overflow: hidden;
  }

    /* INDEX MAIN */
    .main_index_topdiv{
      width: 100vw;
      padding: 0;
      margin: 0;
    }

    .login_message{
      padding: 10px;
    }

    .welcome{
      border: none;
      margin-top: 20px;
      padding: 10px;
    }

    .login_form{
      height: 50px;
      margin: auto;
    }

    .register_topdiv{
      padding: 5px;
    }

    form > .col-12{
      padding-right: 0;
      padding-left: 0;
    }

    .register_text{
      padding: 10px;
      margin-left: 10px;
    }

    .signupcode{
      width: 80%;
      margin: auto;
      text-align: center;
    }

    /* INDEX DASHBOARD*/
    .phone_menu_button{
      width: 100px;
      border: 2px solid black;
      border-top: none;
      border-radius: 0 0 15px 15px;
      background-color: #fa7545;
      text-decoration: underline;
      height: 35px;
      margin: auto;
      text-align: center;
      line-height: 35px;
    }

    .user_dashboard_header_name{
      font-size: 20px;
      text-align: center;
    }

    .user_dashboard_extra{
      overflow: hidden;
      height: 40px;
      transition: 1s ease-in-out;
    }
    .user_dashboard_extra:hover{
      overflow: hidden;
      height: 300px;
      border-bottom: 2px solid black;
    }

    .extra_button{
      width: 100px;
      height: 70px;
    }

    .dashboard_progress_deck{
      display: flex;
      flex-direction: row;
      margin-top: 15px;
      text-align: center;
    }

    .progress_deck_text{
      width: 40%;
      margin-left: 5%;
      text-align: left;
    }

    .progress_deck_select{
      flex: auto;
      width: 80%;
      margin-right: 10%;
      border: 1px solid black;
      border-radius: 10px;
      background-color: transparent;
      padding-left: 5px;
    }

    #progress_bar_target{
      margin-top: 20px;
    }

    #deckProgressTarget{
      padding-top: 20px;
    }

    .deckProgressSubHeader{
      text-align: center;
      margin-top: 15px;
    }

    .deckProgressOuter{
      width: 80%;
    }

    .deckProgressBar_title{
      width: 90%;
      margin: 0 auto;
    }

    .deckProgressBar_innerHeader{
      font-size: 14px;
      text-align: left;
    }

    .deckProgressBar_flex{
      display: flex;
      align-items: center;
      height: 20px;
    }

    .deckProgressBar_innerNums{
      width: 25%;
      padding-left: 10px;
      padding-bottom: 5px;
      font-size: 12px;
    }

    .dashboardProgressType{
      padding-top: 20px;
      margin: 0 auto;
      display: flex;
      justify-content: space-evenly;
      text-align: left;
    }

    .dashboardProgressTypeText{
      width: 30%;
      margin-left: 5%;
    }

    .dashboardProgressTypeSelector{
      width: 28%;
      margin-right: 10%;
      height: 30px;
      line-height: 28px;
      text-align: center;
      font-size: 14px;
      background-color: #ffffff;
      color: #fa7545;
      border: 1px solid #fa7545;
      border-radius: 10px;
    }

    .dashboardProgressTypeSelector_Adjust{
      margin-right: 2% !important;
      background-color: #fa7545;
      border: 1px solid black;
      color: black;
    }

    .indexNoDecks{
      text-align: center;
    }

    .indexNoDeck_buttonContainer{
      display: flex;
      justify-content: space-evenly;
      margin-top: 20px;
    }

    /* TRAINING */
    .training_topdiv{
      margin: 0 !important;
      width: 100%;
    }

    .training_topdiv > form{
      margin: 0;
      padding: 5px;
    }

    .training_switch_button{
      border: 1px solid #fa7545;
      background-color: #ffffff;
    }

    .switch_training_button_text{
      color: #fa7545 !important;
    }

    .slider{
      background: #35a32c;
    }

    .spectest_input_focus:focus{
      border: 1px solid rgba(0,0,0,0.2);
      box-shadow: 0px 0px 8px #fa7545;
      outline: none;
  }

    /* NEWSPEC */
    .newspec_newingredient_modal{
      height: 220vh;
    }

    .new_ingredient_topdiv{
      width: 100vw;
      margin: 0;
      margin-top: 15px;
    }
    .new_ingredient_topdiv > form{
      margin: 0;
      width: 100%;
      display: block;
    }

    #ingredient{
      width: 110%;
      margin-left: -10%;
    }

    .newspec_flex_div{
      display: flex;
      flex-direction: column-reverse;
    }

    .newspec_build{
      flex: auto;
      width: 100% !important;
      max-width: 100%;
    }

    .newspec_ingredients{
      flex: auto;
      width: 100% !important;
      max-width: 100%;
    }

    .newspec_button{
      width: 100% !important;
    }

    .request_ingredient_button{
      margin: 20px auto;
      width: 80% !important;
    }
 
    /* LIBRARY */
    .library_spec_topdiv{
      width: 100vw;
    }

    .library_section_bar{
      background-color: #ffffff;
    }

    .library_search_submit{
      background-color: #ffffff;
      color: #fa7545;
      border: 1px solid #fa7545;
    }

    .libraryCard_header{
      width: 100%;
      height: 90px;
      padding: 0 10px;
      position: relative;
    }

    .libraryCard_subHeader{
      font-size: 14px;
      font-weight: bold;
    }

    .libraryCard_headerDivide{
      position: absolute;
      z-index: 0;
      height: 40px;
      margin: 0 auto;
      width: 95%;
      border-bottom: 1px solid #000000;
    }

    .libraryCard_img{
      position: absolute;
      left: 40px;
      top: 0;
      height: 80px;
      background-color: #ffffff;
      z-index: 10;
      border: 1px solid #fa7545;
      border-radius: 50%;
    }

    .libraryCard_name{
      position: absolute;
      left: 150px;
      top: 22px;
      padding: 0 5px;
      font-size: 20px;
      background-color: #ffffff;
      z-index: 10;
    }

    .libraryCard_spec{
      min-height: 100px;
      width: 95%;
      margin: 0 auto;
      font-size: 14px;
      display: flex;
    }

    .libraryCard_ingredients{
      width: 60%;
    }

    .libraryCard_build{
      width: 40%;
    }

    .libraryCard_garnish{
      width: 95%;
      margin: 5px auto;
      font-size: 14px;
    }

    .libraryCard_menu{
      position: absolute;
      width: 70%;
      margin-right: -65%;
      border-bottom: 1px solid #fa7545;
      border-left: 1px solid #fa7545;
      border-radius: 10px 0 0 10px;
      height: 40px;
      top: 0;
      right: 0;
      display: flex;
      background-color: #ffffff;
      transition: 1s ease;
      overflow: hidden;
    }

    .libraryCard_DecksMenu{
      position: absolute;
      top: 40px;
      right: -100%;
      height: calc(100% - 40px);
      width: 100%;
      padding: 10px 5px;
      background: #ffffff;
      z-index: 100;
      border-top: 1px solid #fa7545;
      color: #35a32c;
      overflow-y: auto;
      overflow-x: hidden;
      transition: 0.6s ease-out;
    }

    .libraryCard_DecksMenuItem{
      text-align: center;
      font-size: 14px;
      margin: 0 auto;
      margin-top: 5px;
      width: 80%;
    }

    .libraryCard_DecksMenuNone{
      width: 95%;
      height: 60%;
      margin: 20px auto;  
      color: black;
      font-size: 14px;
      text-align: center !important;
    }

    

    .libraryCard_toggle{
      min-width: 25px;
      height: 100%;
      font-size: 20px;
      line-height: 40px;
      color: #fa7545;
      text-align: center;
    }

    .libraryCard_modal{
      position: absolute;
      top: -45px;
      left: 0;
      margin: auto;
      width: 100%;
      height: 40px;
      border-bottom: 1px solid #fa7545;
      background-color: #ffffff;
      color: #35a32c;
      text-align: center;
      font-weight: bold;
      font-size: 18px;
      line-height: 20px;
      padding: 10px;
      transition: 1s ease !important;
      z-index: 1000;
    }

    .libraryCard_menuItem{
      width: calc(40% - 25px);
      height: 80%;
      line-height: 30px;
      margin: auto 5%;
      border-radius: 10px;
      font-size: 14px;
      color: #35a32c;
      text-align: center;
      overflow: hidden;
    }

    .libraryDeckCard_content{
      width: 95%;
      font-size: 14px;
      margin: 0 auto;
    }

    .libraryDeckCard_specs{
      display: flex;
      height: 40px;
      overflow-x: auto;
      overflow-y: hidden;
    }

    .libraryDeckCard_specs::-webkit-scrollbar{
      background-color: #ffffff;
      width: 6px !important;
      height: 6px !important;
    }

    .libraryDeckCard_specs::-webkit-scrollbar-thumb {
      border-radius: 12px;
      max-width: 6px !important;
      max-height: 6px !important;
      background-color: #35a32c !important;
      border: 1px solid black;
    }

    .libraryDeckCard_spec{
      max-height: 25px;
      line-height: 25px;
      flex:none;
      width: auto;
      flex-wrap: nowrap;
      padding-right: 10px;
    }

    .libraryDeckCard_nav{
      width: 95%;
      margin: auto;
      margin-top: 10px;
      display: flex;
      justify-content: space-between;    }

    .libraryDeckCard_navItem{
      flex: auto;
      height: 40px;
      border: 1px solid #fa7545;
      border-radius: 10px;
      box-shadow: 0px 0px 3px #fa7545;
      padding: 5px 10px;
      margin: 0 10px;
      text-align: center;
      line-height: 30px;
      color: #fa7545;
      cursor: pointer;
    }
    /* SHAKYPEDIA */
    .shakypedia_profile_toolbar{
      display: none;
    }

    .shakypedia_profile_img {
      left: 10px;
    }

    .shakypedia_profile_name{
      font-size: 22px;
      left: 160px;
      bottom: -15px;
    }

    .shakypedia_profile_stats{
      left: 160px;
      bottom: -35px;
      font-weight: normal;
    }

    .shakypedia_profile_stats_2{
      left: 160px;
      bottom: -52px;
      font-weight: normal;
    }

    .shakypedia_profile_header_spacer{
      height: 80px;
    }

    .spec_table{
      width: calc(100vw - 40px);
    }

    .spec_table_ingredients{
      flex-direction: column;
    }

      /***** Slide Menu *****/
      .shakypedia_slide_menu{
        display: block;
        position: absolute;
        left: 0;
        width: 100vw;
        height: 75px;
        z-index: 200;
        overflow: hidden;
      }

      .shakypedia_slide_menu_inner{
        height: 100%;
        width: 100vw;
        padding: 5px 0;
        border: 1px solid #fa7545;
        border-radius: 10px 0 0 10px;
        margin-left: calc(100vw - 30px);
        display: flex;
        justify-content: flex-start;
        background-color: #ffffff;
        transition: 1s ease-in-out;
      }

      .shakypedia_slide_menu_item{
        flex:content;
        width: 80px;
        padding: 5px;
        border: 1px solid #fa7545;
        border-radius: 10px;
        text-align: center;
        font-size: 12px;
        margin: 0 5px;
        color: #fa7545;
        background-color: #ffffff;
      }

      .slide_menu_icon{
        height: 32px;
      }

      .shakypedia_slide_button{
        transform: rotate(-90deg);
        margin-top: 19px;
        margin-left: -27px;
        font-size: 14px;
        border-top: 1px solid #fa7545;
        border-left: 1px solid #fa7545;
        border-right: 1px solid #fa7545;
        border-radius: 10px 10px 0 0;
        background-color: #ffffff;
        color: #fa7545;
        width: 75px;
        height: 25px;
        text-align: center;
      }

      .shakypedia_slide_close{
        width: 75px;
        height: 35px;
        margin-top: 15px;
        text-align: center;
        transform: rotate(90deg);
      }

      .slide_menu_close{
        height: 30px;
        transform: rotate(90deg);
      }

      /* FLASH CARD */
      .flashcard_form{
        width: 100vw;
      }

      .flashcard_front{
        margin-left: 20px !important;
      }

      .flashCardContent{
        font-size: 14px;
      }

      .flashcard_results_top{
        width: 100%;
      }

      /* 404 */
      .error_img{
        margin: auto;
        margin-top: 40%;
        height: 90vw;
    }

  }/* END OF MAIN MEDIA QUERY */


@media only screen 
and (max-device-width: 812px) and (orientation : portrait){
  /* SPEC CARDS / TESTS PORTRAIT */
  .traintest_top {
    margin: 20px 5px;
    text-align: center;
  }

  .traintest_results{
    margin: auto;
  }

  .spectest_card{
    width: calc(99vw - 20px);
    padding: 30px 10px;
    margin: 10px 2px;
  }

  .spectest_card_body{
    width: 100%;
    font-size: 14px;
    flex-direction: column-reverse;
  }

  .spectest_card_build{
    width: 100%;
  }

  .spectest_card_ingredients{
    width: 100%;
    margin-top: 20px;
  }

  .spectest_card_ingredient{
    width: 100%;
    padding: 0 10px;
  }

  .level2_left{
    width: 30%;
    line-height: 35px;
  }

  .level2_right{
    width: 220px;
    min-width: 220px;
    max-width: 220px;
    margin: 0;
  }

  .level3_measure{
    margin: 0;
    margin-right: 10px;
  }

  .spectest_datalist_div{
    width: 100%;
    padding: 0 10px;
  }

  .spectest_card_subtitles{
    font-size: 18px;
  }

  .specCard_large_top{
    padding: 2px;
    min-height: 200px;
  }

  .specCard_large_name{
    font-size: 16px;
  }

  .specCard_large_item{
    font-size: 12px;
    overflow: hidden;
  }

  .specCard_large_ingredient{
    margin-left: 10px;
  }

  .specCard_large_flipButton{
    width: 100px;
    height: 18px;
    font-size: 12px;
    line-height: 18px;
    border: 1px solid black;
    border-radius: 10px;
    background-color: #fa7545;
    position: absolute;
    top: 5px;
    right: 5px;
    cursor: pointer;
}

  .flashcard_container{
    width: 100vw;
    padding: 0 10px;
    margin: auto;
  }

  .flashcard_main{
    width: 99%;
    margin: auto;
  }

  .showspec_topdiv{
    width: 95%;
    margin: 20px auto;
    min-height: 300px;
    height: auto;
  }

  .showspec_innerdiv{
    margin: 0;
    padding: 0;
    padding-bottom: 10px;
  }

  .flipbtn{
    position: absolute;
    top: 5px;
    right: 5px;
    width: 80px;
    height: 18px;
    line-height: 14px;
    border: 1px solid black;
    border-radius: 10px;
    background-color: #fa7545;
    font-size: 12px;
    text-align: center;
    cursor: pointer;
    z-index: 100;
    display: none;
  }

  /* FLASH CARDS / PORTRAIT */
  .flashcard_container{
    width: 95vw;
    min-height: 380px;
  }

  #flash_name{
    font-size: 24px;
  }

  #flash_ingredients{
    min-width: 230px;
  }

  #flash_build{
    margin-left: 40px;
    max-width: 140px;
  }

}


@media only screen 
  and (max-device-width: 812px) and (orientation : landscape){
  /* SPEC CARDS / TESTS LANDSCAPE */
  .traintest_top {
    margin: 20px 5px;
    text-align: center;
  }
  .spectest_card{
    width: 99vw;
    padding: 5px 15px;
    margin: 10px 2px;
  }

  .spectest_card_body{
    width: 100%;
    font-size: 14px;
  }

  .spectest_card_subtitles{
    font-size: 18px;
  }

  /* FLASH CARDS / LANDSCAPE */
  .flashcard_container{
    min-height: 300px;
  }

  .flashcard_front_name{
    padding-top: 10px;
  }
}