html, body {
    padding: 0;
    margin: 0;
    font: 14px Helvetica, sans-serif;
}

html, body, #map {
    height: 100%;
    width: 100vw;
    overflow: hidden;
}

a {
    color: inherit;
    text-decoration: none;
}

#login {
    position: absolute;
    top: 0;
    right: 0;
    width: 10px;
    height: 10px;
    z-index: 5000;
}
#login:hover {
    background: rgba(150,150,150,.5);
}

#loginDialog {
    display: none;

    position: absolute;
    top: 50%;
    left: 50%;
    width: 150px;
    height: 60px;
    z-index: 5000;

    margin: -30px 0 0 -75px;
    padding: 20px;
    border: 1px solid black;
    background: #fff;
}

#timeline {
    position: absolute;
    top: 0;
    left: auto;
    right: 0;
    height: 100%;
    width: 30%;
    min-width: 400px;
    padding: 0 0 0 20px;
    z-index: 999;
    color: #222;
    overflow-y: scroll;
    transition: left;
    transition-duration: 500ms;
}

#timeline.hidden {
    left: calc(100% - 45px);
    padding-left: 45px;
}

#timeline header.post {
    padding: 4rem 2rem 2rem;
    margin: 0 0 -2rem 0;
    position: relative;
    top: -2rem;
}

#timeline header .logo {
    width: 35%;
    float: left;
    padding-right: 4vh;
}

#timeline header img.emo {
    height: 15px;
}

#tripSelectWrap {
    display: none;

    clear: both;
    position: relative;
    top: 20px;

    width: 100%;
    margin: 0 auto 20px;
    padding-top: 20px;
    font-size: 1.1rem;
    text-align: center;
    border-top: 1px solid #000;
}

#tripSelectWrap label {
    display: inline-block;
    position: relative;
    font-size: 1.1rem;
    border: 1px solid #000;
    padding: 3px 0 3px 6px;
    margin-top: 10px;
    background: #fff;
}

#tripSelectWrap label i {
    position: absolute;
    right: 0;
    top: 0;
    color: #ddd;
    padding: 0;
    background: #107b3e;
    /*z-index: 1;*/
    text-align: center;
    width: 25px;
    height: 100%;
    pointer-events: none;
    box-sizing: border-box;
}

#tripSelectWrap select {
    border: 0;
    padding: 0 30px 0 0;
    margin: 0;
    font-size: 1rem;
    -webkit-appearance: none;
}

#countersWrap {
    width: 80%;
    margin: 1.5em auto;
    padding: 1em 0;
    text-align: center;
    color: #444;
    background: rgba(255,255,255,.8);
    border-radius: 2px;
}

#daysCounter::after, #kmCounter::after {
    content: ' • ';
}
#daysCounter:empty::after, #kmCounter:empty::after {
    content: '';
}

#flagWrap {
    display: inline-block;
    margin-bottom: 1em;
}

.toggle-timeline {
    position: fixed;
    top: 50%;
    width: 30px;
    height: 35px;
    margin: -18px 0 0 -18px;
    padding-left: 5px;
    z-index: 5;
    background: rgba(33,33,33,.8);
    color: #eee;
    font-size: 32px;
    border-radius: 50%;
    cursor: pointer;

    box-shadow: 0 0 6px 1px #fff;
}

#show-timeline {
    display: none;
    margin-left: -40px;
}

.fa-angle-double-left {

}

.links {
    text-align: center;
}

.links a {
    display: inline-block;
    margin: 15px 10px 0;
    width: 10%;
}
.links a:hover {
    color: #0d6632;
}

.text {
    padding: 0 2rem;
}

.text .caption {
    cursor: pointer;
}

.text p {
    margin: .3em 0;
}

.text a {
    color: #0d6632;
}

.text .more {
    float: right;
    position: relative;
    top: -4px;
    padding: 3px 5px;
    margin-top: .5em;
    font-size: .9em;
    color: #888;
    border: 1px solid rgba(0,0,0,0);
    border-radius: 5px;
}

.text .caption:hover .more {
    color: #222;
    border: 1px solid #222;
}

.text .full {
    height: 0;
    transition: height;
    overflow: hidden;
}

#lightbox {
    display: none;
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100%;
    text-align: center;
    background: rgba(0, 0, 0, .75);
    z-index: 1001;
}

#lightbox img {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    margin: auto;
    max-width: 95%;
    max-height: 95%;
    border-radius: 5%;
}

.post {
    position: relative;
    padding: 2rem 0;
    margin: 1vh 0;
    background: rgba(255,255,255,.8);
    border-radius: 2px;
    box-shadow: 0 0 10px 0 rgba(130,130,130,1);
}

.post.active {
    background: rgba(255,255,255,.9);
    box-shadow: 0 0 10px 1px #ff9e9e;
}

.imagePost {
    position: relative;
    overflow: hidden;
    margin: 1vh 0;
    box-shadow: 0 0 10px 0 rgba(130,130,130,1);
}

.post header, .imagePost header {
    display: flex;
    flex-flow: row nowrap;
}

.post header > *,
.imagePost header > * {
    flex: 1 100%;
}

.imagePost header {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    background: #000;
    color: #ddd;
    opacity: .6;
    padding: .6rem 0;
    transition: top 500ms;
}

.imagePost:hover header {
    top: 0;
}

@media (hover: hover) {
    .imagePost header {
        top: -3rem;
    }
}

.imagePost > a {
    /* fixes whitespace below image.. */
    display: flex;
    flex-direction: column;
}

.imagePost img {
    width: 100%;
}

.post header {
    padding: 0 2rem;
    font-size: 1.1rem;
    font-weight: bold;
    margin-bottom: 10px;
}

.location-link {
    font-size: 1rem;
    font-weight: normal;
}
.location-edit, .location-pick {
    display: none;
}

.imagePost .date {
    margin-left: 2rem;
}

.imagePost .location-link {
    text-align: right;
    margin-right: 2rem;
}

.likes {
    text-align: right;
}

.likes .fa-heart {
    font-size: 1.1rem;
    color: #fb4a57;
}
.likes .fa-instagram {
    font-size: 1.3rem;
}

.likes img {
    width: 17px;
    position: relative;
    top: 1px;
    margin-left: 5px;
}

.photoscroll {
    width: 100%;
    white-space: nowrap;
    overflow-x: auto;
    padding: 2vh 0;
}

.photoscroll a {
    display: inline-block;
    min-width: 17vh;
}

.photoscroll img,
.photoscroll video {
    height: 17vh;
    border-right: 2px solid #444;
}

.photoscroll a:last-child  img {
    border: 0;
}

.leaflet-container.crosshair-cursor-enabled {
    cursor: crosshair;
}

.leaflet-marker-icon.photo {
    background: #8d8d8d;
    color: #fff;
    padding: 6px 2px 6px 6px;
    border: 2px solid #fff;
    border-radius: 50%;
    overflow: hidden;
}

.leaflet-marker-icon.photo.active {
    border: 2px solid #fb4a57;
    box-shadow: 0 0 8px 7px #9E3037;
}

.leaflet-marker-icon.photo-notext {
    border-color: #000;
}

.leaflet-marker-icon.photo img {
    position: absolute;
    top: 0;
    left: 0;
    height: 35px;
}

.leaflet-marker-icon.tipi.small-icon {
    width: 25px !important;
    height: 25px !important;
    padding: 4px 4px 9px 4px;
}

.leaflet-marker-icon.photo.small-icon {
    width: 13px !important;
    height: 9px !important;
    padding: 2px 4px 9px 4px;
}

.leaflet-marker-icon.photo.small-icon .fa-2x {
    font-size: .9rem;
}

.leaflet-marker-icon.photo.small-icon img {
    height: 22px;
}

.flag-icon {
    font-size: .9em;
    box-shadow: 2px 1px 2px 0 rgba(0,0,0,0.45);
}

.media-tb {
    display: none !important;
}
.media-lr {
}

#forceRefresh {
    display: none;
}

@media only screen and (max-width: 800px) {
    html, body {
        font-size: 13px;
    }

    .media-tb {
        display: inherit !important;
    }
    .media-lr {
        display: none !important;
    }

    .toggle-timeline {
        top: auto;
        right: 5vw;
        width: 29px;
        height: 34px;
        padding: 3px 0 0 9px;
    }

    #show-timeline {
        bottom: 2vh;
    }

    #timeline {
        width: 100%;
        height: 50%;
        min-width: auto;
        top: auto;
        bottom: 0;
        left: 0;
        padding: 20px 0 0 0;
        transition: height;
        transition-duration: 500ms;
    }

    #timeline.hidden {
        width: 100%;
        height: 0;
        left: 0;
        padding: calc(2vh + 45px) 0 0 0;
    }

    #timeline header.post {
        margin-top: 2rem;
        padding: 2rem;
    }

    #timeline .textLinks {
        float: left;
        width: 70%;
    }

    #timeline #tripSelectWrap {
        font-size: 1rem;
    }

    #timeline #tripSelectWrap select {
        font-size: 0.9rem;
    }

}

@media only screen and (max-width: 800px) and (min-width: 551px) {
    #timeline header .logo {
        width: 15%;
        padding-right: 5%;
    }

    #timeline .textLinks {
        width: 30%;
    }

    #timeline #tripSelectWrap {
        clear: none;
        float: left;
        width: 50%;
        top: 0;
        border: 0;
    }

}

@media only screen and (max-width: 550px) {
    #timeline header .logo {
        width: 25%;
        padding-right: 5%;
    }


    #timeline #tripSelectWrap {
        top: 10px;
        margin-bottom: 0;
        padding-top: 10px;
    }

}

.clearfix::after {
    display: block;
    content: "";
    clear: both;
}

#loading {
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100%;
    z-index: 1002;

    color: #fff;
    font-size: 3rem;
    font-weight: bold;
    background: rgba(0, 0, 0, .85);

    padding-top: 30vh;
    text-align: center;
}

.loader,
.loader:before,
.loader:after {
    background: #ffffff;
    -webkit-animation: load1 1s infinite ease-in-out;
    animation: load1 1s infinite ease-in-out;
    width: 1em;
    height: 4em;
}
.loader {
    color: #ffffff;
    text-indent: -9999em;
    margin: 88px auto;
    position: relative;
    font-size: 11px;
    -webkit-transform: translateZ(0);
    -ms-transform: translateZ(0);
    transform: translateZ(0);
    -webkit-animation-delay: -0.16s;
    animation-delay: -0.16s;
}
.loader:before,
.loader:after {
    position: absolute;
    top: 0;
    content: '';
}
.loader:before {
    left: -1.5em;
    -webkit-animation-delay: -0.32s;
    animation-delay: -0.32s;
}
.loader:after {
    left: 1.5em;
}
@-webkit-keyframes load1 {
    0%,
    80%,
    100% {
        box-shadow: 0 0;
        height: 4em;
    }
    40% {
        box-shadow: 0 -2em;
        height: 5em;
    }
}
@keyframes load1 {
    0%,
    80%,
    100% {
        box-shadow: 0 0;
        height: 4em;
    }
    40% {
        box-shadow: 0 -2em;
        height: 5em;
    }
}
