
/* 1: main nav bar settings 
/* 2: top level options (home/counties/competitions/players/news/beyond cc)
/* 3: dropdown arrows
/* 4: dropdown interactions
/* 5: dropdown options
/* 6: dropdown player list & selection
/* 7: menu button
/* 8: responsive layout 

/* ************************ */
/* 1: main nav bar settings */
/* ************************ */
#sitenav_bar   { 
    height: 100%;
    background-color: rgba(var(--sitedark)); }
#sitenav_bar a { 
    text-decoration: none;
    color: rgba(var(--sitecream)); }
#sitenav_bar p { user-select: none; }

/* ****************************************************************************** */
/* 2: style top level options (home/counties/competitions/players/news/beyond cc) */
/* ****************************************************************************** */
#sn_mainoptions {
    display: flex;
    height: 100%;
    text-align: center;
    align-items: center;
    font-size: var(--fs-medium);
}
#sn_mainoptions li {
    display: block;
    line-height: 2rem; 
}
#sn_home         { width: 15%; }
#sn_counties     { width: 15%; }
#sn_competitions { width: 15%; }
#sn_players      { width: 15%; }
#sn_news         { width: 15%; }
#sn_beyond       { width: 15%; }
.sn_bookends     { width: 5%; }
#sn_mobilemenu_staticarea { 
    width: 100%;
    display: flex;
    height: 100%;
    text-align: center;
    align-items: center;
}
#sn_home a {
    display: block;
    width: 100%;
    height: 100%; 
}
.sn_button {
    cursor: pointer;
}
#sitenav_bar hr { 
    height: 1rem;
    width: 1px;
    border-color: rgba(var(--sitewhite), 0.5);
}
/* ************************ */
/* 3: style dropdown arrows */
/* ************************ */
.sn_dd_text:before {
    font-size: 0.6rem;
    position: relative;
    top: -1px;
    padding-right: 0.3rem;
}
.sn_uparrow:before   { content: "▲"; }
.sn_downarrow:before { content: "▼"; }

/* ****************************** */
/* 4: style dropdown interactions */
/* ****************************** */
.sn_dd_active{
    position: absolute; 
    display: block;
}
.sn_dd_inactive{ display: none; }

/* ************************* */
/* 5: style dropdown options */
/* ************************* */
.sn_dropdown{ 
    margin-top: 0.5%;
    width: 100%; }

.sn_dd_option{
    border-top: 1px solid rgba(var(--sitegold));
    z-index: 100; 
}
.sn_dd_option a {
    display: block;
    width: 100%;
    height: 100%
}
.sn_dropdown li:last-child { border-bottom: 1px solid rgba(var(--sitegold)); }
.sn_dropdown div,
.sn_dropdown li{
    background-color: rgba(var(--sitedark)); 
}

.player_selection:focus,
.sn_dd_option a:focus {
    background: rgba(var(--siteselect), 0.8);
    outline: none;
}
.player_selection:hover,
/*.sn_dd_option a:hover,           leaving for now in case there are knock on consequences! */
.sn_dd_option:hover {
    background: rgba(var(--siteselect), 0.8); 
}

/* *********************************** */
/* 6: dropdown player list & selection */
/* *********************************** */
#sn_dd_player_name {
    margin-top: 2%; 
    display: flex;
    font-size: 1.2rem;
    border: 3px solid rgba(var(--sitegold));
    z-index: 100; 
}
#sn_dd_player_list {
    margin-top: 0.3rem;
    color: rgba(var(--sitewhite));
    font-size: 0.9rem;
    text-align: left;
    max-height: 40ch;
    overflow: auto;
    z-index: 100;
}
.player_optionline {
    background: rgba(var(--sitedark), 0.8);
    border-top: 1px solid rgba(var(--sitegold));
    user-select: none;
}
.player_selection {
    width: 100%;
    padding: 0.2rem 0 0 0.4rem;
}

/* ******************** */
/* 7: style menu button */
/* ******************** */
.sn_menu_button {
    visibility: hidden;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
}
#sn_menu_button_burgerwrapper {
    width: 10dvw;
    height: 6dvh;
}
#sn_menu_button_burger {
    left: 10%;
    width: 80%;
    top: 46.5%;
    height: 3px;
    background: rgba(var(--sitewhite));
    border-radius: 1px;
    transition: all .5s ease-in-out;
}
#sn_menu_button_burger::before,
#sn_menu_button_burger::after {
    content: '';
    position: absolute;
    left: 0;
    width: 100%;
    height: 3px;
    background: rgba(var(--sitewhite));
    border-radius: 1px;
    transition: all .5s ease-in-out; 
  }

#sn_menu_button_burger::before { transform: translateY(-0.45rem); }
#sn_menu_button_burger::after  { transform: translateY(0.45rem); }

#sn_menu_button_burger.sn_mobilemenu_open         { height: 0; }
#sn_menu_button_burger.sn_mobilemenu_open::before { transform: rotate(45deg); }
#sn_menu_button_burger.sn_mobilemenu_open::after  { transform: rotate(-45deg); }

/* ******************** */
/* 8: responsive layout */
/* ******************** */
@media (max-width: 800px) {
    .sn_menu_button{ visibility: visible; }
    #sn_home,
    #sn_counties,
    #sn_competitions,
    #sn_players,
    #sn_news,
    #sn_beyond,
    #sitenav_bar hr { 
        visibility: hidden;
    }
    #sn_menubookend { 
        width: 10dvw;
        height: 6dvh; 
    }
    .sn_button {
        cursor: default;
    }
    #sitenav_bar.fullmobilemenu {
        height: 100dvh;
        background-attachment: fixed;
        background-size: cover;
        z-index: 200; 
    }
    #sitenav_bar.fullmobilemenu.men {
        background-image: url(../images/lyth.jpg);
    }
    #sitenav_bar.fullmobilemenu.women {
        background-image: url(../images/umpire.jpg);
    }
    .fullmobilemenu #sn_mainoptions {
        background: rgba(var(--sitedark), 0.4);
        font-size: 1.1rem;
        display: block;
    }
    .fullmobilemenu .sn_button {
        padding-left: 10dvw;
        padding-top: 3dvh;
        text-align: left;
        width: 100dvw;
    }
    .fullmobilemenu #sn_home {
        padding-top: 8dvh;
        width: 100%;
    }
    .fullmobilemenu .sn_buttonwithoptions { padding-left: 15dvw;}
    
    .fullmobilemenu #sn_counties     { width: 100%; }
    .fullmobilemenu #sn_competitions { width: 100%; }
    .fullmobilemenu #sn_players      { width: 100%; }
    .fullmobilemenu #sn_news         { width: 100%; } 
    .fullmobilemenu #sn_beyond       { width: 100%; }
    .fullmobilemenu .sn_bookends     { width: 100%; } 
    .fullmobilemenu #sn_menubookend  { width: 100dvw; height: 6dvh; }
    
    .fullmobilemenu .sn_menu_button      { 
        background: rgba(var(--sitedark));
        justify-content: left;
        z-index: 999;
        height: 100%;
    } 
    .fullmobilemenu .sn_dd_active { position: relative; }
    .fullmobilemenu #sn_mainoptions li { line-height: 2.8rem; }
    .fullmobilemenu .sn_dropdown li:last-child { border-bottom: 0; }
    .fullmobilemenu .sn_dd_option { 
        background: rgba(var(--sitedark), 0);
        padding-left: 10dvw;
        border-width: 0 0 0 0;
        line-height: 1.7rem;
        width: 30ch;
    } 
    .fullmobilemenu .sn_dd_option a:hover,
    .fullmobilemenu .sn_button:focus, 
    .fullmobilemenu #sn_mainoptions li a:focus,
    .fullmobilemenu .sn_dd_option a:focus {
        background: rgba(var(--sitedark), 0);
        color: rgba(var(--sitewhite));
        font: bold;
        text-shadow: 2px 2px 4px rgba(var(--siteblack), 1);
        outline: none;
    }
    .fullmobilemenu #sn_mobilemenu_staticarea {
        height: 94dvh;
        width: 100dvw;
        position: absolute;
        display: block;
        top: 0;
        overflow: auto;
    }
    .fullmobilemenu #sn_dd_playerinput_wrapper {
        padding-left: 10dvw;
        width: 70dvw;
        line-height: 1.3rem;
    }
    .fullmobilemenu #sn_home a,
    .fullmobilemenu .sn_dd_option a { height: auto }
    .fullmobilemenu #sn_dd_playerinput_wrapper li { color: rgba(var(--sitecream)); }
    #sn_dd_player_list::-webkit-scrollbar { width: 30px; }
    #sn_dd_player_list::-webkit-scrollbar-thumb { background: rgba(var(--sitegold), 0.6); }
}
