* {
    outline: none;
}

html, body {
    width: 100%;
    height: 100%;
    font-family: 'Montserrat', sans-serif;
}

/* Horizontal Layout */

#title,
#navigation,
#intro,
#impact-intro,
#controls,
#stat,
#search,
#map,
#overlay,
#overlay #loading,
#overlay #start,
#trend,
#impact,
#timeline,
#footer {
    position: absolute;
}

#title, #navigation, #intro, #impact-intro, #search {
    left: 20px;
    right: 20px;
}

#controls, #stat {
    width: 50%;
    display: none;
}

#controls {
    left: 20px;
}

#stat {
    right: 20px;
}
#controls #forward,
#controls #back{
    display: none !important;
}

#after-animation{
    display: none;
    position: absolute;
    top: 160px;
    height: 60px;
    width: 49%;
    left: 8%;
    text-align: center;
    color: rgb(249, 148, 0);
    font-size: 13px;
    line-height: 34px;
}

#map, #overlay, #timeline, #footer {
    left: 0;
    right: 0;
}

#trend {
    left: 15%;
    right: 15%;
}

#impact {
    left: 20px;
    right: 20px;
}

/* Vertical Layout */

#title {
    top: 20px;
    height: 50px;
    font-size: 45px;
    line-height: 50px;
}

#navigation {
    top: 90px;
    height: 40px;
}

#navigation > div {
    line-height: 40px;
}

#intro, #impact-intro, #controls, #stat {
    top: 160px;
    height: 60px;
}

#search {
    top: 135px;
    height: 60px;
}

#map {
    top: 220px;
    height: 350px;
}

#overlay #start, #overlay #loading {
    top: 175px;  /* half of #map height */
}

#overlay {
    top: 220px;  /* from #map */
    bottom: 65px;  /* to #timeline */
}

#trend {
    top: 240px;
    height: 300px;
}

#impact {
    top: 240px;
}

#trend-graph {
    height: 280px;
}

#timeline {
    bottom: 65px;
    height: 56px;  /* .decade height + .decade border x2 */
}

#timeline .decade {
    width: 50px;
    height: 50px;
    line-height: 50px;
    cursor: default;
    transition: background-color 0.35s ease, color 0.35s ease;
    /*transition: color 0.5s ease;*/
    /*transition-delay: 0.25s;*/
    /*-webkit-transition-delay: 0.5s;*/
    background-color: #fff;
    color: rgb(141, 191, 213);
}
#timeline .decade.filled {
    background-color: rgb(116, 167, 195);
    color: rgb(255, 255, 255);
}

#footer {
    bottom: 5px;
    height: 25px;
    padding-top: 5px;
}

/* Styles */

#title {
    font-weight: bold;
    color: rgb(54, 76, 92);
    text-align: center;
    text-transform: uppercase;
}

#navigation {
    font-size: 0;
}

#navigation > div {
    width: 33.3%;
    box-sizing: border-box;
    display: inline-block;
    color: white;
    background-color: rgb(181, 212, 221);
    cursor: pointer;
    font-size: 18px;
    font-weight: bold;
    text-align: center;
    text-transform: uppercase;
    border-left: 2px rgb(162, 189, 198) solid;
    border-right: 2px rgb(162, 189, 198) solid;
}

#navigation > div.active {
    background-color: rgb(82, 133, 155);
}

#navigation > div:first-child, #navigation > div:last-child {
    border: none;
}

#intro, #impact-intro {
    color: rgb(56, 76, 94);
    text-align: center;
}

#intro p, #impact-intro p {
    margin: 0;
    font-size: 13px;
}

#stat {
    text-align: right;
    font-weight: bold;
    color: rgb(68, 117, 138);
}

#stat .number {
    font-size: 40px;
    line-height: 40px;
}

#stat .units {
    font-size: 20px;
    line-height: 1px;
}

#controls .button {
    width: 36px;
    height: 36px;
    border-radius: 18px;
    display: inline-block;
    background-color: rgb(249, 148, 0);
    text-align: center;
    line-height: 36px;
    color: white;
    font-size: 18px;
    cursor: pointer;
    vertical-align: middle;
}

#controls .button:hover {
    opacity: 0.9;
}

#controls .button.button-small {
    width: 26px;
    height: 26px;
    line-height: 26px;
    font-size: 12px;
}

#search {
    color: rgb(68, 117, 138);
    font-size: 30px;
    line-height: 30px;
    text-align: center;
    display: none;
}

#search .search-intro {
    color: gray;
    font-size: 13px;
    line-height: 26px;
}

#search .input {
    margin-top: 0px;
    /*display: inline-block;*/
    display: none;
}

#search input {
    border: none;
    box-shadow: none;
    border-bottom: 2px solid gray;
    text-align: center;
    color: rgb(249, 148, 0);
}

#search input::-webkit-input-placeholder {
    color: rgb(249, 148, 0);
    font-size: 26px;
}

#search input:-moz-placeholder {
   color: rgb(249, 148, 0);
   font-size: 26px;
   opacity: 1;
}

#search input::-moz-placeholder {
   color: rgb(249, 148, 0);
   font-size: 26px;
   opacity: 1;
}

#search input:-ms-input-placeholder {
   color: rgb(249, 148, 0);
   font-size: 26px;
}

#map {
    background-color: #fff;
}

#dot-legend {
    display: none;
    position: absolute;
    width: 400px;
    height: 30px;
    left: 20px;
    top: 540px;
    font-size: 12px;
    line-height: 12px;
    color: rgb(68, 117, 138);
    vertical-align: top;
}

#dot-legend .dot {
    font-size: 30px;
    line-height: 16px;
    vertical-align: bottom;
}

#dot-legend .more {
    color: gray;
    font-size: 10px;
    margin-left: 15px;
    width: 350px;
}

.tooltip {
    display: none;
    background-color: rgb(54, 76, 93);
    padding: 8px;
    color: rgb(241, 242, 244);
    margin-top: 3px;
    margin-left: 15px;
    font-size: 10px;
    line-height: 15px;
}

#gradient-legend {
    display: none;
    position: absolute;
    width: 500px;
    height: 40px;
    left: 50%;
    margin-left: -250px;
    bottom: 100px;
    font-size: 11px;
    line-height: 13px;
}

#gradient-legend .title {
    line-height: 25px;
    color: gray;
}

#gradient-legend .step, #gradient-legend .label {
    width: 20%;
    height: 25px;
    float: left;
    text-align: center;
}

#gradient-legend .label {
    font-size: 12px;
    line-height: 15px;
    color: rgb(13, 121, 145);
    padding-top: 4px;
}

#gradient-legend .step:nth-child(3) {
    background-color: rgb(237, 248, 249);
}

#gradient-legend .step:nth-child(4) {
    background-color: rgb(165, 205, 217);
}

#gradient-legend .step:nth-child(5) {
    background-color: rgb(136, 192, 211);
}

#gradient-legend .step:nth-child(6) {
    background-color: rgb(110, 168, 192);
}

#gradient-legend .step:nth-child(7) {
    background-color: rgb(13, 121, 145);
}

#overlay {
    background-color: rgba(255, 255, 255, 0.5);
}

#overlay #loading, #overlay #start {
    left: 50%;
    width: 80px;
    height: 80px;
    margin-top: -40px;
    margin-left: -40px;
    border-radius: 50px;
    color: #fff;
    background-color: rgb(68, 117, 138);
    font-size: 40px;
    line-height: 80px;
    text-align: center;
    position: absolute;
}

#overlay #start {
    display: none;
    cursor: pointer;
    background-color: rgb(249, 148, 0);
}

#trend {
    background-color: rgb(56, 76, 94);
    border-radius: 3px;
    padding-top: 20px;
    display: none;
}

#trend-title, #trend-graph p {
    width: 100%;
    text-align: center;
    text-transform: uppercase;
    color: #ccc;
    font-family: Montserrat;
    font-weight: 400;
    font-size: 16px;
}

#trend-graph {
    width: 97%;
    margin-top: -20px;
}

#impact-intro {
    display: none;
}

#impact {
    display: none;
    padding: 30px;
    background-color: rgb(56, 76, 94);
    color: #fff;
}

.impact-header .impact-location {
    font-size: 30px;
    border-bottom: 2px solid rgb(242, 163, 57);
    display: inline-block;
    margin-top: 10px;
}

.impact-header .impact-date {
    font-size: 15px;
    line-height: 30px;
}

.impact-header .box {
    width: 100px;
    border: 2px solid rgb(242, 163, 57);
    float: right;
    margin-left: 10px;
    padding: 5px;
    text-align: center;
}

.impact-header .box .box-top {
    padding: 0 10px;
    border-bottom: 2px solid rgb(242, 163, 57);
}

.impact-header .box .box-top .impact-inches, .impact-header .box .box-top .impact-percentage {
    font-size: 24px;
    line-height: 12px;
    font-weight: normal;
    vertical-align: bottom;
}

.impact-header .box .box-top span:last-child {
    font-size: 9px;
    line-height: 9px;
    display: inline-block;
    margin-left: -10px;
    margin-right: -10px;
}

.impact-header .box .box-bottom {
    font-size: 15px;
    line-height: 30px;
}

.impact-list {
    font-size: 14px;
    margin-top: 30px;
}

.impact-list .impact-icon {
    float: left;
    font-size: 25px;
    width: 25px;
    clear: both;
    text-align: center;
    margin-right: 20px;
}

.impact-list .impact-text {
    padding: 8px 0;
    vertical-align: center;
}

.impact-list .fa {
    color: rgb(242, 163, 57);
    text-align: center;
}

#timeline {
    padding: 0 20px;
    text-align: justify;
    background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAADCAMAAABlA5WwAAAAA1BMVEX5lAAIQjqbAAAACklEQVR4AWMAAwAABgABeV6XjwAAAABJRU5ErkJggg==);
    background-repeat: repeat-x;
    background-position: 0 50%;
}

#timeline:after {
    content: '';
    width: 100%;
    display: inline-block;
    font-size: 0;
    line-height: 0
}

#timeline .decade {
    display: inline-block;
    overflow: hidden;
    background-color: #fff;
    border: 3px rgb(183, 205, 215) solid;
    border-radius: 40px;
    color: rgb(141, 191, 213);
    text-align: center;
    position: relative;
}

#timeline .decade span {
    display: inline-block;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    margin-top: 6px;
    line-height: 40px;
}

#timeline .decade.decade-pre span {
    font-size: 15px;
    line-height: 18px;
}

#footer {
    border-top: 1px solid #ddd;
    box-sizing: border-box;
    text-align: center;
}

#footer img {
    max-height: 100%;
}

.leaflet-container {
    cursor: inherit;
}

.leaflet-container .leaflet-control-attribution {
    background-color: inherit;
}

.impact-icon-0,
.impact-icon-1,
.impact-icon-2,
.impact-icon-3,
.impact-icon-4,
.impact-icon-5,
.impact-icon-6,
.impact-icon-7,
.impact-icon-8,
.impact-icon-9 {
    background-color: rgb(76, 134, 153);
    width: 30px !important;
    height: 30px !important;
    border-radius: 15px;
    color: #fff;
}

.impact-icon-0:before {
    content: "1";
    text-align: center;
    width: 100%;
    display: inline-block;
    font-size: 18px;
    font-weight: bold;
}

.impact-icon-1:before {
    content: "2";
    text-align: center;
    width: 100%;
    display: inline-block;
    font-size: 18px;
    font-weight: bold;
}

.impact-icon-2:before {
    content: "3";
    text-align: center;
    width: 100%;
    display: inline-block;
    font-size: 18px;
    font-weight: bold;
}

.impact-icon-3:before {
    content: "4";
    text-align: center;
    width: 100%;
    display: inline-block;
    font-size: 18px;
    font-weight: bold;
}

.impact-icon-4:before {
    content: "5";
    text-align: center;
    width: 100%;
    display: inline-block;
    font-size: 18px;
    font-weight: bold;
}

.impact-icon-5:before {
    content: "6";
    text-align: center;
    width: 100%;
    display: inline-block;
    font-size: 18px;
    font-weight: bold;
}

.impact-icon-6:before {
    content: "7";
    text-align: center;
    width: 100%;
    display: inline-block;
    font-size: 18px;
    font-weight: bold;
}

.impact-icon-7:before {
    content: "8";
    text-align: center;
    width: 100%;
    display: inline-block;
    font-size: 18px;
    font-weight: bold;
}

.impact-icon-8:before {
    content: "9";
    text-align: center;
    width: 100%;
    display: inline-block;
    font-size: 18px;
    font-weight: bold;
}

.impact-icon-9:before {
    content: "10";
    text-align: center;
    width: 100%;
    display: inline-block;
    font-size: 18px;
    font-weight: bold;
}

.mg-line1-color {
    stroke: rgb(249, 167, 55);
    stroke-width: 3px !important;
}

.mg-line2-color{
    stroke: #ccc;
    stroke-width: 1.75px !important;
}

.mg-x-axis text, .mg-y-axis text, .mg-histogram .axis text {
    fill: #fff;
}

.mg-line-rollover-circle {
    opacity: 0 !important;
}

.close-popup {
    display: block;
    position: absolute;
    top: 5px;
    right: 8px;
    font-size: 15px;
    color: black;
    cursor: pointer;
}

@media (max-width: 630px) {
  #title {
    font-size: 42px;
  }

  #trend {
    left: 10%;
    right: 10%;
  }

  #search .input {
    margin-top: 10px;
  }

  .impact-header .impact-location {
    margin-top: 18px;
    font-size: 24px;
  }
}

@media (max-width: 550px) {
  #title {
    font-size: 38px;
  }

  #search {
    font-size: 25px;
  }

  #trend {
    left: 20px;
    right: 20px;
  }

  #search .input {
    margin-top: 19px;
  }

  .impact-header .impact-location {
    margin-top: 22px;
    font-size: 20px;
  }
}
