  /* global */
body{
    font-family: Verdana, Geneva, Tahoma, sans-serif;
    font-size: 1.3em;
    margin: 0;
}

/* header  */

header{
    margin: 0;
    top: 0;
    padding: 0;
    position: fixed;
    width: 100%;
    background-color: #fff;
    z-index: 100;
    -webkit-box-shadow: 0px 0px 16px 1px rgba(92, 92, 92, 0.25);
    -moz-box-shadow: 0px 0px 16px 1px rgba(92, 92, 92, 0.25);
    box-shadow: 0px 0px 16px 1px rgba(92, 92, 92, 0.25);
}

/* navigation */

nav{
    /* width: 100%; */
    margin-top: 1em;
    margin-bottom: 1em;
    display: grid;
}
nav .logo {
    grid-area: logo;
}
.logo img{
    display: inline-flex;
    align-self: center;
    top: .5em;
    position: relative;
    width: min(35vw, 200px);
}
nav .link {
    grid-area: links;
    text-align: right;
    padding-top:1em;
    /* background-color: grey; */
}
nav .link a{
    font-weight: bolder;
    text-decoration: none;
    background-color: #efefef;
    border-radius: .4em;
    color: black;
}
nav .link a:hover {
    background-color: #f4f4f4;
    color:green
}

/* main */



/* footer */
footer{
    margin-top: 3em;
    margin-bottom: 2em;
    border-top: 1px solid #efefef;
}

.contact {
    text-align: center;
    font-size: 1em;
    display: block;
}

.contact .info {
    display: inline-block;
    line-height: 1em;
    /* background-color: aqua; */
    width: 100%;
    margin-top:1em;

}

/* objects */
.icon{
    height: 1.2em;
    width: 1.2em;
    /* background-color:burlywood; */
    display: inline-flex;
    align-self: center;
    top: .125em;
    position: relative;
}
.email{
    background-image: url('/images/email.svg');
    background-size:100% 100%;

}
.phone{
    background-image: url('/images/phone.svg');
    background-size:100% 100%;
}

/* main */
article {
    font-size: 1.2;
    margin-top: 3em;
}
article p {
    line-height: 1.5em;
}

/* listing */
.listings {
    display: grid;
    gap: 1.5em 1.5em;
}
.listings .title {
    grid-area: title;
}

.listing{
    position: relative;
    background-color: white;
    box-shadow: 0 0 .5em rgba(92, 92, 92, 0.25);
    border-radius: .5em;
}
.listing .brand{
    font-weight: bold;
    vertical-align: middle;
    color: white;
    text-align: center;
}
.listing .brand a{
    text-decoration: none;
    color: rgb(72, 72, 72);
}

.listing .brand p {
    color: 000;
    font-weight: normal;
    color:#000;
}

.listing .buy{
    font-weight: bold;
    display: inline;
    padding: 1.4em;
    display: grid;
    grid-template-areas: "price button";
    grid-template-columns: 2fr 2fr;
    font-size: .8em;
    /* background-color: cadetblue; */
}
.buy .price {
    display: inline;
    padding: .4em;
    grid-area: price;
    /* background-color: yellow; */
}
.buy .button{
    background-color: green;
    width: 100%;
    text-align: center;
    padding: .4em;
    color: white;
    border-radius: .5em;
    grid-area:button;
    /* background-color: aqua; */
    display: inline-flex;
    align-self: center;
    position: relative;
}
.buy .button a{
    color: white;
    font-weight:bold;
}
.button a {
    display: block;
    height: 100%;
    width: 100%;
    text-decoration: none;
}
main section {
    margin-top: 2em;
}

/* links */
a {
    color: blue;
}
a:visited{
    color: blue;
}
a:hover{
    text-decoration: underline;
    color:crimson
}

/* sold */
.sold {
    text-decoration: line-through;
    text-decoration: #000;
    pointer-events: none;
    cursor: not-allowed;
    /* background-color: #efef; */
    color: black;
}

.sold a, .sold a:visited {
    text-decoration: none;
}

.buy .button.sold {
    background-color: gray;
}

  /* mmobile phone */
@media (min-width: 320px) and (max-width: 480px) {
  
    /* CSS */

    body{
        font-size: 1em;
    }
    nav, main, footer {
        max-width: 90%; 
        /* margin: 0 auto;  */
        margin-left: auto;
        margin-right: auto;
    }
    main{
        margin-top: 6em;
    }
    nav{
        grid-template-areas:   "logo links links";
        grid-template-columns: 1fr 1fr 1fr;
    }
    .listings {
        grid-template-areas: "title"
                             "listing";
        grid-template-columns: 1fr;
        /* grid-gap: 1em; */
    }
    .listing .brand a {
            font-size: 1.4em;
            height: 3em;
            line-height: 3em;
    }

    .listing .brand p {
        line-height: .8em;
        font-size:.8em;

    }
    nav .link a {
        padding: .75em;
        margin-top: 1em;
    }
    
  }

  /* larger than phone */
  @media (min-width: 481px) {
  
    /* CSS */
    
    body{
        font-size: 1em;
    }
    nav, main, footer {
        max-width: 1080px; 
        margin-left: auto;
        margin-right: auto;
    }
    main{
        margin-top: 9em;
    }
    nav{
        grid-template-areas: "logo links";
        grid-template-columns: 2fr 1fr;
    }
    .listings {
        grid-template-areas: "title title title title"
                             "listing listing listing listing";
        grid-template-columns: 1fr 1fr 1fr 1fr;
        /* grid-gap: 1em; */
    }
    .listing .brand a{
        font-size: 1.5em;
        height: 5em;
        line-height: 5em;
    }

    .listing .brand p {
        line-height: 1em;
        font-size: 1em;
    }

    nav .link a {
        padding: 1em;
        margin-top: 1em;
    }
  }