
/* any smaller than the max width */
@media only screen and (max-width: 1290px) {
    .container { width: 90%; margin: 0 2.5%; padding: 35px 2.5%; }
    header .banner-content { width: 90%; }
    nav.stuck > div { width: 90%; }
    nav .logo { width: 150px; }
    nav .nav a { padding: 10px 2px; font-size: 13px; }
    nav .nav.test a { padding: 10px 2px; }
}

@media only screen and (min-width: 1024px) and (max-width: 1080px) {
    nav .nav.test a { padding: 10px 3px; font-size: 12px; }
}

@media only screen and (min-width: 1024px) {
    nav .nav.test li.social { position: relative; width: 0; height: 0; }
    nav .nav.test li.social .social-container { width: 101px; position: absolute; top: -35px; right: 0; }
}

/* small height screens */
@media only screen and (min-width: 768px) and (max-height: 1024px) {
    nav { padding: 35px; }
    header .banner-content { bottom: 50px; }
    header .banner-content h1 { font-size: 28px; line-height: 32px; }
}


/* nav has a lot of content, so activate the mobile menu sooner */
@media only screen and (max-width: 1100px) {

    nav {
        background: rgba(255, 255, 255, .95);
    }

    nav .nav {
        width: 100%;
        display: none;
    }

    nav .nav.is-active {
        display: block;
    }

    nav .nav ul {
        margin-top: 35px;
    }

    nav .nav li {
        float: none;
    }

    nav .nav a {
        display: block;
        padding: 10px 0;
    }

    nav.container {
        width: 80%;
        margin: 0 4.5%;
        padding: 20px 5.5%;
        height: auto;
    }

    nav.container.stuck {
        margin: 0;
        padding: 20px 0;
    }

    nav .logo {
        padding: 0;
        border: 0;
        width: 150px;
    }

    nav.container.stuck .logo {
        padding-left: 20px;
    }

    nav.container.stuck .nav ul {
        margin-left: 20px;
    }

    nav.stuck > div {
        width: auto;
    }

    nav .hamburger {
        position: absolute;
        right: 20px;
        top: 17px;
        padding: 0;
        display: inline-block !important;
        opacity: 1 !important;
    }

    .hamburger-inner, .hamburger-inner:after, .hamburger-inner:before {
        background-color: #00446A;
    }

    nav .hamburger:after {
        content: 'Menu';
        text-transform: uppercase;
        font-size: 7px;
        position: absolute;
        bottom: -12px;
        left: 0;
        color: #666666;
        right: 0;
        letter-spacing: 1.5px;
        font-family: 'AvenirNextBold', sans-serif;
    }

    nav a.facebook {
        font-size: 40px; /*position: absolute; top: 13px; right: 90px;  margin-left: 0;*/
    }

    .header-phone a {color: #00446a; font-weight: bold;}

}
/* all mobile */
@media only screen and (max-width: 1023px) {

    body.fixed { overflow: hidden; }

    .container { width: 80%; margin: 0 10%; padding: 0; }

    header,
    header .flexslider,
    header ul.slides,
    header ul.slides li { height: 250px; }
    body#home header,
    body#home header .flexslider,
    body#home header ul.slides,
    body#home header ul.slides li { height: 100%; }

    header .banner-content { width: auto; bottom: 40px; margin: 0 10%; }
    header .banner-content > div { width: 100%; }
    header .banner-content h1 { font-size: 20px; line-height: 28px;  }
    header .banner-content p { display: none; }

    section article.noheading { padding-top: 0; }

    section article,
    section aside { float: left; width: auto; }
    section article { margin-bottom: 40px; }

    section aside.noheading { float: none; width: auto; }
    section article.noheading { float: none; width: auto; }

    /* estate animation */
    .estates .estate { height: 340px; }
    @keyframes estate-content {
        from { right: -65%; }
        to { right: 0; }
    }
    .estates .estate.animation .content > a {
        animation-name: estate-content;
        animation-duration: 1s;
        animation-fill-mode: forwards;
    }
    .estates .estate .content > a { z-index: 50; width: 65%; }
    .estates .estate .content > a > div { bottom: 10px; right: 20px; margin-left: 30px; }
    /* end estate animation */

    article.estates { display: none; }
    body#land-estates section article { width: 45%; }
    body#land-estates section aside.noheading { float: right; width:100%; position: relative;}
    body#land-estates section article { font-size: inherit; line-height: inherit; }

    .quote-block {width: 100%; text-align: center;}

}

@media only screen and (max-width: 767px) {
    .estates .estate .content > a > div h3 {
        font-size: 20px;
        line-height: 24px;
    }
    .estates .estate .content > a > div {
        font-size: 12px;
        line-height: 16px;
    }
    body#land-estates section article { width: 100%; }
    body#land-estates section aside.noheading { min-width: 70%; position: relative; }
    body#land-estates section article { font-size: inherit; line-height: inherit; }
}


/* mobile portrait */
@media only screen and (max-width: 479px) {

    nav .logo { width: 120px; }

    /* header animation */
    body#home header .primary-triangle { width: 115%; left: -115%; }
    body#home header .secondary-triangle { width: 155%; left: -155%; }
    @keyframes primary-triangle {
        from { left: -115%; }
        to { left: 0; }
    }
    @keyframes secondary-triangle {
        from { left: -155%; }
        to { left: 0; }
    }
    /* end header animation */


    /* estate animation */
    .estates .estate .logo { width: 30%; }
    .estates .estate { height: 540px; }
    @keyframes estate-content {
        from { bottom: -400px; }
        to { bottom: 0; }
    }
    .estates .estate.animation .content > a {
        animation-name: estate-content;
        animation-duration: 1s;
        animation-fill-mode: forwards;
    }
    .estates .estate .content > a { right: 0; width: 100%; bottom: -370px; height: 370px; }
    .estates .estate .content > a > div { display: flex; flex-direction: column; justify-content: center;}
    .estates .estate .logo,
    .estates .estate .primary-triangle,
    .estates .estate .secondary-triangle,
    .estates .estate .top-triangle { bottom: 370px; }
    /* end estate animation */

}


/* allow for iphone 5 and smaller devices */
@media only screen and (max-width: 320px) {
    section.footer2 a.facebook { position: relative; right: auto; bottom: auto; margin-top: 20px; display: block; }
    .estates .estate .content > a > div h3 { font-size: 20px; line-height: 22px;  }
}


/* fit all nav items on landscape phones */
@media only screen and (max-height: 375px) {
    nav .nav li { float: left; width: 50%; }
}

/* tablet portrait */
@media only screen and (min-height: 769px) and (max-width: 1023px) {
    header .banner-content { bottom: 70px; }
    header .banner-content p { display: block; }
    header .banner-content > div { width: 80%; }
    header .banner-content h1 { font-size: 38px; line-height: 41px; }

    /* header animation */
    body#home header .primary-triangle { width: 110%; left: -110%; }
    body#home header .secondary-triangle { width: 145%; left: -145%; }
    @keyframes primary-triangle {
        from { left: -110%; }
        to { left: 0; }
    }
    @keyframes secondary-triangle {
        from { left: -145%; }
        to { left: 0; }
    }
    /* end header animation */
}


@media only screen and (max-height: 700px) {

    header .banner-content > div { width: 70%; }

}


@media only screen and (max-height: 580px) {

    header .banner-content { font-size: 12px; line-height: 16px; }
    header .banner-content h1 { font-size: 25px; line-height: 26px; }
    header .banner-content h1, header .banner-content p { margin-bottom: 12px; }

}

@media only screen and (max-height: 700px) and (min-width: 1024px) {

    header, header .flexslider, header ul.slides, header ul.slides li { height: 395px; }
    section { padding: 60px 0; }
    section .container { padding-top: 0; }

}

/*LAND ESTATE PAGE*/
@media only screen and (max-width: 1023px) {
    body#land-estates section article {
        width:100%;
    }
    .page-landestates {
        grid-template-columns: 100%;
    }
    body#land-estates section aside.noheading {
        grid-template-columns: 100%;
        grid-row-gap: 3em;
    }
    .map {
        top:0;
    }
}