/**
 * CSS for Staff Directory search
 *
 * This file is in version control:
 * https://github.com/uofa/global-environment
 *
 * Created 18 Jul 2012
 * Updated 20 Apr 2021
 *
 * Last update: amend spacing of elements.
 *
 * @author Allan A Beattie
 */


/* search form
------------------------------------------------------------ */

.directory_search {
    margin: 0 0 2em;
}

.directory_search,
.directory_search * {
    box-sizing: border-box;
}

.primary_options {
    margin-bottom: 1em;
}

.primary_options label[for=st] {
    display: block;
    font-weight: 700;
}

#st {
    width: 100%;
    padding: 0.3em;
}

#st:focus {
    background: #fdffce;
}

.directory_search_term,
.directory_search_type,
.directory_search_category {
    margin: 0 0 0.5em;
    padding: 0;
    border: 0;
}

.directory_search_term legend,
.directory_search_category legend {
    font-weight: 700;
}


/* results
------------------------------------------------------------ */

.directory_results {
    margin: 0;
    padding: 0;
    list-style: none;
}

.directory_results li {
    padding: 1em;
    overflow: auto;
}

.directory_results li:nth-of-type(odd) {
    background-color: #f5f5f5;
}

.directory_results dl,
.directory_results dd {
    margin: 0;
}

.directory_results dl:first-of-type dd:nth-of-type(1) {
    font-weight: 700;
}

.directory_results dl:first-of-type dd:nth-of-type(1)::before {
    font-family: 'Font Awesome 5 Pro';
    content: '\f007';
    padding-right: 0.3em;
    color: #f4c900;
}

main .directory_results a::after {
    display: none;
}


@media screen and (min-width: 360px) {
    .directory_search_type .field {
        float: left;
        margin-right: 0.6em;
    }

    #st,
    #sf {
        width: 100%;
    }
}


@media screen and (min-width: 680px) {
    .primary_options,
    .directory_search_category {
        float: left;
        width: 48%;
    }

    .primary_options {
        margin-right: 4%;
        margin-bottom: 0;
    }

    .directory_search_type .field {
        float: none;
    }

    .directory_search_go {
        display: block;
        clear: left;
    }
}


@media screen and (min-width: 960px) {
    .directory_search_type .field {
        float: left;
    }

    .directory_results dl {
        float: left;
        width: 48.75%;
    }

    .directory_results dl:first-child {
        margin-right: 2.5%;
    }
}
