/* ------- Search ------- */

#search {
    padding: 0 2.4rem;
    width: 100%;
    color: #000000;
    font-size: 1.5rem;
    text-align: left;
}


/* -- Search input --*/

#search .searchField {
    margin-top: 1.4rem;
}

#search .searchField input[type=text] {
    display: block;
    margin: 0 0 0 0;
    padding: 1.2rem 3.5rem 1.2rem 0;
    width: 100%;
    color: #3F3F3F;
    font-family: 'Roboto Medium', sans-serif;
    font-size: 1.5rem;
    text-align: left;
    border: none;
    border-bottom: solid 0.1rem var(--clr-gold);
}


/* -- Nearest --*/

#search .nearest {
    margin-top: 2.2rem;
    padding: 2.0rem 4.0rem;
    width: 100%;
    font-family: 'Roboto Medium', sans-serif;
    font-size: 1.5rem;
    line-height: 1.5rem;
    background-color: #F6F0E5;
    background-image: url('/public/images/map/icon-nearest-pin.svg?v=1');
    background-size: 1.5rem 1.5rem;
    background-position: right 4.0rem center;
    transition: 0.5s;
}

#search .nearest.active {
    margin-left: -2.4rem;
    padding: 2.0rem 6.4rem;
    width: calc(100% + 4.8rem);
    background-position: right 6.4rem center;
}

#search .nearest .turnOffButton {
    display: none;
    position: absolute;
    top: 0rem;
    left: 3.0rem;
    height: 5.4rem;
    width: 1.4rem;
    background-image: url('/public/images/map/icon-cross.svg?v=1');
}

#search .nearest.active .turnOffButton {
    display: block;
}


/* -- Search results --*/

#search .results {
    margin: 0;
    padding: 2.2rem 0 0 0;
    background-color: #ffffff;
    border-radius: 0.7rem;
    z-index: 20;
}

#search .results .item {
    display: flex;
    padding: 1.2rem 0;
    margin: 0;
    width: 100%;
    border-bottom: solid 0.1rem #E0D1B188;
    align-items: center;
    justify-content: space-between;
}

#search .results .item:last-child {
    border: none;
}

#search .results .item .name {
    margin-bottom: 0.6rem;
    font-family: 'Roboto Medium', sans-serif;
    font-size: 1.5rem;
}

#search .results .item .address {
    color: #868686;
    font-family: 'Roboto Light', sans-serif;
    font-size: 1.3rem;
}

#search .results .item .detail {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
}

#search .results .item .distance {
    margin-left: 1.2rem;
    color: #6C6C6C;
    font-family: 'Roboto Light', sans-serif;
    font-size: 1.5rem;
    text-wrap: nowrap;
}

#search .results .item .arrow {
    margin-left: 1.2rem;
    height: 1.2rem;
    width: 1.2rem;
    background-image: url('/public/images/page/icons/arrow-right-gold.svg?v=1');
}


#searchMobile {
    display: none;
}
    

/* ----------------- Tablet 720px ----------------- */
@media only screen and ((max-width: 1000px) or (orientation: portrait)) {

    #menu {
        display: none;
    }


    /* ------- Mobile Header ------- */

    #mobileHeader,
    #indexHeader {
        display: flex;
        padding: 0 2.4rem;
        width: 100%;
        min-height: 7.5rem;
        height: 7.5rem;
        background-color: var(--clr-white);
        box-shadow: 0 1.1rem 3.55rem 0 #99773B26;
        flex-wrap: nowrap;
        align-items: center;
        justify-content: space-between;
        z-index: 60;
    }

    #mobileHeader .homeLink,
    #indexHeader .homeLink {
        display: flex;
        flex-wrap: nowrap;
        align-items: center;
        align-content: center;
    }
    
    #mobileHeader .homeLink .back {
        margin-right: 2.4rem;
        height: 1.6rem;
        width: 1.6rem;
        background-image: url('/public/images/page/icons/arrow-left-gold.svg?v=1');
    }
    
    #mobileHeader .homeLink .logo,
    #indexHeader .homeLink .logo {
        height: 4.3rem;
        width: 15.7rem;
        background-image: url('/public/images/logo.svg?v=1');
    }

    #mobileHeader .friendLinkCont,
    #indexHeader .friendLinkCont {
        max-width: 22.0rem;
        display: flex;
        flex-wrap: nowrap;
        align-items: center;
        justify-content: center;
        flex-direction: row;
        gap: 1.7rem;
    }
    
    #mobileHeader .beerLink,
    #indexHeader .beerLink {
        height: 2.6rem;
        min-width: 2.6rem;
        width: 2.6rem;
        background-image: url('/public/images/page/icons/beer-gold.svg?v=1');
    }

    #mobileHeader .friendLinkCont .text,
    #indexHeader .friendLinkCont .text {
        color: var(--clr-black);
        font-family: 'Roboto', sans-serif;
        font-size: 1.4rem;
        line-height: 1.65rem;
        text-decoration: underline;
        text-align: left;
    }

    

    /* ------- Search ------- */

    #searchMobile {
        display: block;
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        color: #000000;
        font-size: 1.5rem;
        text-align: left;
        transform: none;
        transition: transform 0.5s;
    }

    #searchMobile.hide {
        transform: translateY(-30rem);
    }

    #searchMobile,
    #searchMobile .results {
        pointer-events: none;
    }

    #searchMobile .searchField,
    #searchMobile .nearest,
    #searchMobile .results .item {
        pointer-events: auto;
    }


    /* -- Search input --*/

    #searchMobile .searchField {
        display: flex;
        background-color: var(--clr-white);
        border-top: solid 0.1rem var(--clr-gold);
        z-index: 60;
        box-shadow: 
            0px 1.1rem 2.4rem 0px #0000001A,
            0px 4.3rem 4.3rem 0px #0000000D,
            0px 17.3rem 6.9rem 0px #00000003,
            0px 27.0rem 7.6rem 0px #00000000;
        justify-content: space-between;
        align-items: center;
    }
    
    #searchMobile .searchField input[type=text] {
        display: block;
        margin: 0 0 0 0;
        padding: 2.3rem 2.3rem 2.3rem 2.3rem;
        width: 100%;
        color: #3F3F3F;
        font-family: 'Roboto Medium', sans-serif;
        font-size: 1.6rem;
        line-height: 2.0rem;
        text-align: left;
        border: none;
    }

    #searchMobile .searchField .closeButton {
        display: none;
        right: 2.3rem;
        height: 1.6rem;
        width: 1.6rem;
        background-image: url('/public/images/map/icon-cross.svg?v=1');
    }

    #searchMobile.active .searchField .closeButton {
        display: block;
    }


    /* -- Nearest --*/

    #searchMobile .nearestContainer {
        display: none;
        padding: 2.2rem;
        background-color: var(--clr-white);
    }

    #searchMobile.active .nearestContainer {
        display: block;
    }

    #searchMobile .nearest {
        display: none;
        padding: 2.0rem 4.0rem;
        width: 100%;
        font-family: 'Roboto Medium', sans-serif;
        font-size: 1.5rem;
        line-height: 1.5rem;
        background-color: #F6F0E5;
        background-image: url('/public/images/map/icon-nearest-pin.svg?v=1');
        background-size: 1.5rem 1.5rem;
        background-position: right 4.0rem center;
        transition: 0.5s;
    }

    #searchMobile.active .nearest {
        display: block;
    }
    
    #searchMobile .nearest.active {
        margin-left: -2.4rem;
        padding: 2.0rem 6.4rem;
        width: calc(100% + 4.8rem);
        background-position: right 6.4rem center;
    }
    
    #searchMobile .nearest .turnOffButton {
        display: none;
        position: absolute;
        top: 0rem;
        left: 3.0rem;
        height: 5.4rem;
        width: 1.4rem;
        background-image: url('/public/images/map/icon-cross.svg?v=1');
    }
    
    #searchMobile .nearest.active .turnOffButton {
        display: block;
    }


    /* -- Search results --*/

    #searchMobile .results {
        display: none;
        margin: 0;
        padding: 0.6rem 0 0 0;
        height: calc(100% - 6.6rem - 5.4rem - 4.0rem);
        background-color: #ffffff;
        border-radius: 0;
        z-index: 20;
        overflow-x: hidden;
        overflow-y: auto;
    }
    
    #searchMobile.active .results {
        display: block;
    }
    
    #searchMobile .results .item {
        display: flex;
        padding: 1.4rem 0;
        margin: 0 2.3rem;
        width: calc(100% - 4.6rem);
        border-bottom: solid 0.1rem #E0D1B188;
        align-items: center;
        justify-content: space-between;
    }
    
    #searchMobile .results .item:last-child {
        border: none;
    }
    
    #searchMobile .results .item .name {
        margin-bottom: 0.5rem;
        font-family: 'Roboto Medium', sans-serif;
        font-size: 1.5rem;
    }
    
    #searchMobile .results .item .address {
        color: #868686;
        font-family: 'Roboto Light', sans-serif;
        font-size: 1.3rem;
    }

    #searchMobile .results .item .detail {
        display: flex;
        flex-wrap: nowrap;
        align-items: center;
    }

    #searchMobile .results .item .distance {
        margin-left: 1.2rem;
        color: #6C6C6C;
        font-family: 'Roboto Light', sans-serif;
        font-size: 1.5rem;
        text-wrap: nowrap;
    }

    #searchMobile .results .item .arrow {
        margin-left: 1.2rem;
        height: 1.2rem;
        width: 1.2rem;
        background-image: url('/public/images/page/icons/arrow-right-gold.svg?v=1');
    }
}


/* ----------------- Mobile 360px ----------------- */
@media only screen and (max-width: 500px) {
    

    /* ------- Mobile Header ------- */

    #mobileHeader,
    #indexHeader {
        padding: 0 2.4rem;
        min-height: 7.5rem;
        height: 7.5rem;
    }
    
    #mobileHeader .homeLink .back {
        margin-right: 2.4rem;
        height: 1.6rem;
        width: 1.6rem;
    }
    
    #mobileHeader .homeLink .logo,
    #indexHeader .homeLink .logo {
        height: 4.3rem;
        width: 15.7rem;
    }

    #mobileHeader .friendLinkCont,
    #indexHeader .friendLinkCont {
        max-width: 9.8rem;
        gap: 1.2rem;
    }
    
    #mobileHeader .beerLink,
    #indexHeader .beerLink {
        height: 2.6rem;
        min-width: 2.6rem;
        width: 2.6rem;
    }

    #mobileHeader .friendLinkCont .text,
    #indexHeader .friendLinkCont .text {
        font-size: 1.4rem;
        line-height: 1.65rem;
    }
}