:root {
    --hival-color:#aa4444;
    --loval-color:#4444aa;
    /* --ok-color:#44aa44; */
    --ok-color:#84D862;
    /* --ok-on-color:#aa4444; */
    --ok-on-color:#FF0000;
    /* --ok-off-color:#44aa44; */
    --ok-off-color:#84D862;
    /* --low-color:#aa4444; */
    --low-color:#FF0000;
    --middle-color:#FF8800;
    /* --unknown-color:#dfdfdf; */
    --unknown-color:#FF0000;
    --link-color:#337ab7;
    --tooltip-color:#fff;
    --tooltip-backgroud-color:#337ab7;
}
/*
link color
TODO dark
Belchertown default: #e5554e
Royal Blue: #4169e1
Bootstrap Button: #337ab7
*/

a {
    color: var(--link-color);
    text-decoration: none;
}

a:hover {
    color: var(--link-color);
    text-decoration: revert;
}

.sun-moon-modal a {
    text-decoration: none;
}

.sun-moon-modal a:hover {
    color: var(--link-color);
    text-decoration: revert;
}

.station-observation-extras-modal-link a {
    text-decoration: none;
}

.station-observation-extras-modal-link a:hover {
    color: var(--link-color);
    text-decoration: revert;
}

.genesis-nav-menu a:hover, .dark .genesis-nav-menu a:hover {
    color: var(--link-color);
    display: block;
    padding: 30px 24px;
}

/* 
Tooltips
https://osvaldas.info/elegant-css-and-jquery-tooltip-responsive-mobile-friendly
*/

abbr[title] {
    border-bottom: none;
    text-decoration: none !important;
    -webkit-text-decoration: none !important;
    -moz-text-decoration: none !important;
    text-decoration: none !important;
}

#tooltip
{
    text-align: center;
    color: var(--tooltip-color);
    background: var(--tooltip-backgroud-color);
    position: absolute;
    z-index: 100;
    padding: 15px;
    border-radius: 10px;
}
 
    #tooltip:after /* triangle decoration */
    {
        width: 0;
        height: 0;
        border-left: 10px solid transparent;
        border-right: 10px solid transparent;
        border-top: 10px solid var(--tooltip-backgroud-color);
        content: '';
        position: absolute;
        left: 50%;
        bottom: -10px;
        margin-left: -10px;
    }
 
        #tooltip.top:after
        {
            border-top-color: transparent;
            border-bottom: 10px solid var(--tooltip-backgroud-color);
            top: -20px;
            bottom: auto;
        }
 
        #tooltip.left:after
        {
            left: 10px;
            margin: 0;
        }
 
        #tooltip.right:after
        {
            right: 10px;
            left: auto;
            margin: 0;
        }
/*
.wind-speed-beaufort{
}
*/
		.wind-run {
		    text-align: center;
		    padding-top: 10px;
		}
/* Online Marker */

		.onlineMarkerOuter {
		    padding: 6px 0 0 15px;
		    float: left;
		}

		.loadingMarker:before {
		    content: '';
		    position: absolute;
		    width: 8px;
		    height: 8px;
		    margin: 10px 0 0 -13px;
		    background: #ffbe00;
		    border-color: #ffbe00;
		    border-radius: 50%;
		}

		.offlineMarker:before {
		    content: '';
		    position: absolute;
		    width: 8px;
		    height: 8px;
		    margin: 10px 0 0 -13px;
		    background: #ff0000;
		    border-color: #ff0000;
		    border-radius: 50%;
		}

		.onlineMarker:before {
		    content: '';
		    position: absolute;
		    width: 8px;
		    height: 8px;
		    margin: 10px 0 0 -13px;
		    background: #00bb00;
		    border-color: #00bb00;
		    border-radius: 50%;
		}

		.onlineMarker:after {
		    content: '';
		    position: absolute;
		    width: 32px;
		    height: 32px;
		    margin: -2px 0 0 -25px;
		    border: 1px solid #00bb00;
		    border-radius: 50%;
		    box-shadow: 0 0 4px #00bb00, inset 0 0 4px rgb(56, 111, 169);
		    -webkit-transform: scale(0);
		    -webkit-animation: online 2.5s ease-in-out infinite;
		    animation: online 2.5s ease-in-out infinite;
		}
/* reports */

.history-headline, .noaa-headline {
    text-align: left;
    font-size: calc(14px + 0.3vw);
    margin-top: 20px;
    margin-bottom: 10px;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

.dark .history-headline, .dark .noaa-headline {
    text-align: left;
    font-size: calc(14px + 0.3vw);
    margin-top: 20px;
    margin-bottom: 10px;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

.history-info-icon:before {
    color: royalblue;
}

.history-table-container, .history-table-noaa-container {
    padding-right: 0px;
    padding-left: 0px;
}

.dark .history-table-container, .dark .history-table-noaa-container {
    padding-right: 0px;
    padding-left: 0px;
}

.history-table, .history-table-noaa {
    font-size: calc(9px + 0.4vw);
    margin-bottom: 0px;
}

.dark .history-table, .dark .history-table-noaa {
    font-size: calc(9px + 0.4vw);
    margin-bottom: 0px;
}

.history-table >thead>tr>th, .history-table >thead>tr>td, .history-table >tbody>tr>th, .history-table >tbody>tr>td {
    vertical-align: middle;
    padding: 4px 0px 4px 0px;
    border-top: 1px solid #ddd;
}

.dark .history-table >thead>tr>th, .dark .history-table >thead>tr>td, .dark .history-table >tbody>tr>th, .dark .history-table >tbody>tr>td {
    vertical-align: middle;
    padding: 4px 0px 4px 0px;
    border-top: 1px solid #ddd;
}

.history-table-noaa >thead>tr>th, .history-table-noaa >thead>tr>td, .history-table-noaa >tbody>tr>th, .history-table-noaa >tbody>tr>td {
    vertical-align: middle;
    padding: 4px 0px 4px 0px;
    border-top: 1px solid #ddd;
}

.dark .history-table-noaa >thead>tr>th, .dark .history-table-noaa >thead>tr>td, .dark .history-table-noaa >tbody>tr>th, .dark .history-table-noaa >tbody>tr>td {
    vertical-align: middle;
    padding: 4px 0px 4px 0px;
    border-top: 1px solid #ddd;
}

a.history-table-body-year-nav-noaa, a.history-table-body-month-nav-noaa {
    text-decoration: none !important;
}

#noaa_contents {
    width: 100%;
    margin: 0 auto;
}
/* Wind */

.wind-row {
    border-top: 1px solid #D7D7D7;
    padding: 0px 15px 0px;
    margin: 0 -15px 0 -15px;
}

.obs-wind-divider {
    width: 104%;
}

.current_wind {
    /* padding: 15px 0 0 0px!important; */
}

.compass {
    margin-left: auto;
    margin-top: 0;
    float: left;
}

.compassbox {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 50%;
    float: left;
    /* margin-top: 6px; */
    margin-bottom: 10px;
}

.wx-stn-info-current-obs {
    display: grid;
    justify-content: center;
    align-items: center;
}

.windspeedtable {
    padding-top: 0px;
    width: 50%;
    float: right;
}

.wind-table-title td {
}

.wind-speed-unit {
    text-align:center;
}
/*
.wind-speed-beaufort{
}
*/
.wind-run {
    text-align: center;
    padding-top: 10px;
}

/* records */

.records-table {
    font-size: calc(11px + 0.3vw);
    padding-right: 0px;
    padding-left: 0px;
}

/* extreme */

.extreme-table-container {
    padding-right: 0px;
    padding-left: 0px;
}

.dark .extreme-table-container {
    padding-right: 0px;
    padding-left: 0px;
}

.extreme-table {
    font-size: calc(10px + 0.4vw);
}

.dark .extreme-table {
    font-size: calc(10px + 0.4vw);
}

.extreme-table >thead>tr>th, .extreme-table >thead>tr>td, .extreme-table >tbody>tr>th, .extreme-table >tbody>tr>td {
    vertical-align: middle;
    padding: 4px 0px 4px 0px;
    border-top: 1px solid #ddd;
}

.dark .extreme-table >thead>tr>th, .dark .extreme-table >thead>tr>td, .dark .extreme-table >tbody>tr>th, .dark .extreme-table >tbody>tr>td {
    vertical-align: middle;
    padding: 4px 0px 4px 0px;
    border-top: 1px solid #ddd;
}

.extreme-table-head-headline {
    text-align:center;
    background:#D7D7D7;
    color:#000;
}

.dark .extreme-table-head-headline {
    text-align:center;
    background:#D7D7D7;
    color:#000;
}

.extreme-table-head-subheadline {
    text-align:center;
}

.dark .extreme-table-head-subheadline {
    text-align:center;
}

.extreme-table-head-year {
    text-align: center;
    background: #3da5f4;
    color: #fff;
}

.dark .extreme-table-head-year {
    text-align: center;
    background: #3da5f4;
    color: #fff;
}

.extreme-table-head-alltime {
    text-align: center;
    background: #375a7f;
    color: #fff;
}

.dark .extreme-table-head-alltime {
    text-align: center;
    background: #375a7f;
    color: #fff;
}

.extreme-table-body-obs {
    padding-left: 10px !important;
}

.dark .extreme-table-body-obs {
    padding-left: 10px !important;
}

.extreme-table-body-obs-val-year, .extreme-table-body-obs-val-alltime {
    text-align: right;
    padding-right: 20px !important;
}

.dark .extreme-table-body-obs-val-year, .extreme-table-body-obs-val-alltime {
    text-align: right;
    padding-right: 20px !important;
}

.extreme-table-body-obs-ts-year, .extreme-table-body-obs-ts-alltime {
    font-size: calc(10px + 0.4vw);
    text-align: right;
    padding-right: 20px !important;
}

.dark .extreme-table-body-obs-ts-year, .dark .extreme-table-body-obs-ts-alltime {
    font-size: calc(10px + 0.4vw);
    text-align: right;
    padding-right: 20px !important;
}

/*
.extreme-table-body-obs-descr-year, .extreme-table-body-obs-descr-alltime {
    font-size: calc(8px + 0.4vw);
}
.dark .extreme-table-body-obs-descr-year, .dark .extreme-table-body-obs-descr-alltime {
    font-size: calc(8px + 0.4vw);
}
*/

/* sup und sub */

sup, sub {
   position: relative;
   vertical-align: baseline;
   top: -0.4em;
}
sub { top: 0.4em; }

/* Back to top button */

#btn-back-to-top {
    position: fixed;
    transform: scale(0);
    bottom: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    z-index: 99;
}

#btn-back-to-top:focus, #btn-back-to-top:hover {
    outline: none;
}

#btn-back-to-top:hover .fa-arrow-up {
    animation: jump 800ms infinite;
    animation-iteration-count: 3;
}

@keyframes jump {
    50% {
      transform: translateY(-10px);
    }
    100% {
      transform: translateY(0);
    }
}
/* TODO: media queries */

/* https://www.w3schools.com/css/css_rwd_mediaqueries.asp */
/* Extra small devices (phones, 600px and down) */
@media only screen and (max-width: 600px) {
    .dummy {
        text-align: center;
    }
}

/* Small devices (portrait tablets and large phones, 600px and up) */
@media only screen and (min-width: 600px) {
    .dummy {
        text-align: center;
    }
}

/* Medium devices (landscape tablets, 768px and up) */
@media only screen and (min-width: 768px) {
    .dummy {
        text-align: center;
    }
}

/* On the Samsung Galaxy S10+ it is 3.5 */
/* https://www.webmobilefirst.com/en/devices/samsung-galaxy-s10-plus/ */
/*
@media only screen and (-webkit-min-device-pixel-ratio: 3.5) {
    .dummy {
        text-align: center;
    }
}
*/

@media only screen and (max-width: 800px) {
    .dummy {
        text-align: center;
    }
    .site-inner, .wrap {
        /* padding-top:20px; */
        padding-left: 2%;
        padding-right: 2%;
    }
    .obs-header-icon {
        width: auto;
    }
    .wx-stn-info-current-obs img{
        max-width: 40%;
    }
    .current_temp .outtemp_outer {
        padding-top: 15px!important;
        min-height: auto;
        font-size: 60px;
        min-height: 103px;
    }
    .currentSwitchLabel {
        margin-top: 10px;
    }
    .toprow-height, .dark.toprow-height {
        min-height: 0 !important;
    }
    .obs-row-middle {
        border-top: 1px solid #D7D7D7;
        padding: 0px 10px 0px;
        margin: 0 -15px 0 -15px;
    }
    .current_obs_top, .dark .current_obs_top {
        padding-right: 0px;
        padding-left: 0px;
    }
    .current_obs_top img, .dark .current_obs_top img {
        float: none;
        width: 30%;
        height: auto;
    }
    .weather-obs-top, .dark .weather-obs-top {
        min-height: 160px!important;
    }
    .weather-obs-middle-top, .dark .weather-obs-middle-top {
        min-height: max-content!important;
        padding: 0px 15px 0px;
    }
    .obs-aqi-divider, .obs-aqi-divider, .aqi-wind-divider {
        height: 1px;
        width: 104%;
        background-color: #D7D7D7;
    }
    .current_wind {
        padding: 10px 0 0 0px!important;
    }
    .windspeedtable {
        padding-top: 0px;
        width: 50%;
        float: right;
    }
    .earthquake-container {
        min-height: max-content!important;
    }
    .earthquake-container .earthquake-distance-outer {
        min-height: max-content!important;
    }
    .extreme-table-body-obs {
        padding-left: 2px !important;
    }
    .dark .extreme-table-body-obs {
        padding-left: 2px !important;
    }
    .extreme-table-body-obs-val-year, .extreme-table-body-obs-val-alltime {
        text-align: right;
        padding-right: 2px !important;
    }
    .dark .extreme-table-body-obs-val-year, .extreme-table-body-obs-val-alltime {
        text-align: right;
        padding-right: 2px !important;
    }
    .extreme-table-body-obs-ts-year, .extreme-table-body-obs-ts-alltime {
        font-size: calc(9px + 0.4vw);
        text-align: right;
        padding-right: 2px !important;
    }
    .dark .extreme-table-body-obs-ts-year, .dark .extreme-table-body-obs-ts-alltime {
        font-size: calc(9px + 0.4vw);
        text-align: right;
        padding-right: 2px !important;
    }
    .wbx-issued, .forecast-wbx-subtitle, .issued-DWD {
        font-size: calc(10px + 0.3vw);
        display: block;
    }
/* Online Marker */
    .onlineMarkerOuter {
        padding: 6px 0 0 15px;
        float: none;
    }
    .loadingMarker:before {
        content: '';
        position: absolute;
        width: 8px;
        height: 8px;
        margin: 8px 0 0 -13px;
        background: #ffbe00;
        border-color: #ffbe00;
        border-radius: 50%;
    }
    .offlineMarker:before {
        content: '';
        position: absolute;
        width: 8px;
        height: 8px;
        margin: 8px 0 0 -13px;
        background: #ff0000;
        border-color: #ff0000;
        border-radius: 50%;
    }
    .onlineMarker:before {
        content: '';
        position: absolute;
        width: 8px;
        height: 8px;
        margin: 8px 0 0 -13px;
        background: #00bb00;
        border-color: #00bb00;
        border-radius: 50%;
    }
    .onlineMarker:after {
        content: '';
        position: absolute;
        width: 32px;
        height: 32px;
        margin: -4px 0 0 -25px;
        border: 1px solid #00bb00;
        border-radius: 50%;
        box-shadow: 0 0 4px #00bb00, inset 0 0 4px rgb(56, 111, 169);
        -webkit-transform: scale(0);
        -webkit-animation: online 2.5s ease-in-out infinite;
        animation: online 2.5s ease-in-out infinite;
    }
    /* forecast */
    .forecast-conditions {
        min-height: 110px;
    }
    /* Additional Station Observations */
    .page .station-observation-extras-modal a {
        font-size: 20px;
    }
    .observations-extras-label {
        min-width: 170px;
    }
    .station-observation-extras-modal-link a {
        font-size: 20px;
    }
}

@media only screen and (max-width: 834px) and (orientation : landscape) {
    .dummy {
        text-align: center;
    }
    .site-inner, .wrap {
        padding-left: 5%;
        padding-right: 5%;
    }
}

/* iPad Landscape */
/*
@media only screen and (min-device-width : 768px) and (max-device-width : 1024px) and (orientation : landscape) {
    .dummy {
        text-align: center;
    }
    .24hr_forecasts .forecast-24hour {
        width: 144px;
    }
}
*/

/* Large devices (laptops/desktops, 992px and up) */
@media only screen and (min-width: 992px) {
    .dummy {
        text-align: center;
    }
}

@media only screen and (min-width: 1196px) {
    .dummy {
        text-align: center;
    }
}

@media only screen and (max-width: 1199px) {
    .dummy {
        text-align: center;
    }
    .site-inner, .wrap {
        max-width: 960px;
    }
    .genesis-nav-menu a {
        padding: 10px 10px;
    }
    .border-left {
        border-left: 0px !important;
    }
    .border-right {
        border-right: 0px !important;
    }
}

/* Extra large devices (large laptops and desktops, 1200px and up) */
@media only screen and (min-width: 1200px) {
    .dummy {
        text-align: center;
    }
}
.dwdforecasttable {
    line-height: 1.0;
}
.dwdforecasttable td {
    text-align: center;
    padding-left: 3px;
    padding-right: 3px;
    line-height: 1.2;
}
.dwdforecasttable .icons td {
    padding-top: 5px;
    padding-bottom: 0px;
}
.dwdforecasttable .topdist td {
    padding-top: 5px;
}
.light .dwdforecasttable td.weekend {
    background-color: #ffe;
}
.dark .dwdforecasttable td.weekend {
    background-color: #333;
}

/* forecast */

.forecast-3hour, .forecast-24hour {
    position: relative;
    min-height: 270px;
    padding-left: 10px;
    padding-right: 10px;
    display: inline-block;
    width: 144px;
    font-size: 100%;
}

.forecast-conditions {
    min-height: 184px;
    word-wrap: break-word;
}

.forecast-source-container {
    margin-top: 5px;
    margin-bottom: 5px;
}

.forecast-container {
    overflow: hidden;
    margin-bottom: 15px;
}

.forecast-title {
    font-size: calc(18px + 0.3vw);
    text-align: left;
    margin-bottom: 12px;
    padding-right: 0 !important;
    float: left;
}

.forecast-headline {
    font-size: calc(20px + 0.3vw);
    text-align: left;
    margin-top: 15px;
    margin-bottom: 5px;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

.dark .forecast-headline {
    font-size: calc(20px + 0.3vw);
    text-align: left;
    margin-top: 15px;
    margin-bottom: 5px;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

.forecast-subheadline {
    font-size: calc(16px + 0.3vw);
    text-align: left;
    margin-top: 5px;
    margin-bottom: 0px;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

.dark .subforecast-headline {
    font-size: calc(16px + 0.3vw);
    text-align: left;
    margin-top: 5px;
    margin-bottom: 0px;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

.forecast-content {
    margin-bottom: 10px;
    padding-left: 0;
}

.dark .forecast-content {
    margin-bottom: 10px;
    padding-left: 0;
}

.forecast-menu {
    display: inline-block;
    position: relative;
    height: 40px;
    padding-left: 0 !important;
    text-align: right;
    font-size: 16px;
    float: right;
}

.eq-stats-row {
    border-bottom: 1px solid #D7D7D7;
    /* margin-top: 15px; */
}

.snow-precip, .rain-precip, .humidity-forecast {
    color:#42b5e7;
}

.forecast-avg {
    font-size:20px;
    font-weight:500;
}

.dark .forecastweekend {
    color: orange;
}

.forecast-pressure, .forecast-dewpoint, .forecast-humidity, .forecast-winddirdeg{
    font-size:15px;
}

.forecast-source {
    font-size: calc(10px + 0.3vw);
    text-align: center;
}

/* graphs */

.wx-graph-front {
    font-size: 24px;
    padding-top: 20px;
    padding-bottom: 10px;
    text-align: center;
}
