/**
*
* fdci_weather.css  <connor@tcomeng.com>
* created  07/2026 CL
* 07/31/2026 CL Add weather dashboard styles
*
*/

/* Page frame */

.fdciWeatherPage {
    padding-bottom: 52px;
}

footer {
    height: auto;
    margin-top: 18px;
    padding-bottom: 10px;
    position: static;
}

.weatherUpdated,
.weatherPanelSubhead {
    color: #9fbad0;
    font-size: 12px;
}

.weatherStatus {
    color: #20ff54;
    font-size: 14px;
    min-height: 0;
}

.weatherStatus:empty {
    display: none;
}

/* Primary weather layout */

.weatherLayout {
    display: grid;
    gap: 12px;
    grid-template-columns: minmax(0, 2fr) minmax(320px, 1fr);
    margin-top: 0;
}

.weatherForecastLayout {
    display: grid;
    gap: 12px;
    grid-template-columns: minmax(0, 1fr) minmax(360px, 0.9fr);
    margin-top: 12px;
}

.weatherPanel,
.weatherCurrentCard {
    background-color: #102b41;
    border: 1px solid #2b5874;
    border-radius: 4px;
}

.weatherPanelHeader {
    align-items: center;
    border-bottom: 1px solid #2b5874;
    color: #ffcb52;
    display: flex;
    font-size: 16px;
    font-weight: 600;
    justify-content: space-between;
    min-height: 42px;
    padding: 8px 10px;
}

.weatherMapPanel {
    min-height: 480px;
}

#weather-map {
    background-color: #071927;
    height: 438px;
    width: 100%;
}

/* Dark treatment for the OSM base tiles only. */
.weatherBaseTile {
    filter: invert(1) hue-rotate(180deg) grayscale(0.45) brightness(0.58) contrast(0.92) saturate(0.32);
}

.leaflet-control-layers,
.leaflet-control-zoom a {
    background-color: #102b41;
    border-color: #2b5874;
    color: #ffffff;
}

.leaflet-control-layers-expanded {
    color: #ffffff;
}

.leaflet-control-attribution {
    background-color: rgba(7, 25, 39, 0.72) !important;
    color: #ffffff;
    text-shadow: none;
}

.leaflet-control-attribution a {
    color: #9ed0ff !important;
}

.weatherAlerts {
    max-height: 438px;
    overflow-y: auto;
}

.weatherAlert {
    border-bottom: 1px solid #244d66;
    padding: 10px;
}

.weatherAlert:last-child {
    border-bottom: 0;
}

.weatherAlertEvent {
    color: #ffffff;
    font-size: 15px;
    font-weight: 600;
}

.weatherAlertMeta {
    color: #9fbad0;
    font-size: 12px;
    margin-top: 4px;
}

.weatherSeverityExtreme,
.weatherSeveritySevere {
    border-left: 5px solid #ff0832;
}

.weatherSeverityModerate {
    border-left: 5px solid #ffcb52;
}

.weatherSeverityMinor,
.weatherSeverityUnknown {
    border-left: 5px solid #20ff54;
}

.weatherFirmsItem {
    border-left: 5px solid #ff8c1a;
}

.weatherEmpty,
.weatherError {
    color: #9fbad0;
    padding: 10px;
}

.weatherError {
    color: #ffcb52;
}

.weatherCurrentGrid {
    display: grid;
    gap: 12px;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    margin-top: 12px;
}

/* Current-condition cards */

.weatherCurrentCard {
    color: #ffffff;
    cursor: pointer;
    min-height: 150px;
    padding: 10px;
    text-align: left;
}

.weatherCurrentCard:hover {
    border-color: #ffcb52;
}

.weatherCurrentLocation {
    color: #ffcb52;
    font-size: 16px;
    font-weight: 600;
}

.weatherCurrentTemp {
    color: #ffffff;
    font-size: 34px;
    font-weight: 700;
    line-height: 1;
    margin-top: 8px;
}

.weatherCurrentDesc {
    color: #20ff54;
    font-size: 14px;
    margin-top: 6px;
    min-height: 20px;
}

.weatherCurrentMeta {
    color: #cbd7df;
    display: grid;
    font-size: 13px;
    gap: 2px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-top: 10px;
}

.weatherLocationTabs {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    justify-content: flex-end;
}

/* Forecast panels */

.weatherHourlyPanel {
    display: flex;
    flex-direction: column;
}

.weatherLocationTab {
    background-color: #003399;
    border: 1px solid #2f5faa;
    color: #ffffff;
    font-size: 12px;
    padding: 4px 8px;
}

.weatherLocationTab.active {
    background-color: #ffcb52;
    border-color: #ffcb52;
    color: #102b41;
}

.weatherHourly {
    display: grid;
    flex: 1;
    gap: 0;
    grid-auto-rows: minmax(92px, 1fr);
    grid-template-columns: repeat(6, minmax(0, 1fr));
}

.weatherHour {
    border-bottom: 1px solid #244d66;
    border-right: 1px solid #244d66;
    min-height: 92px;
    padding: 8px;
}

.weatherHourTime {
    color: #9fbad0;
    font-size: 12px;
}

.weatherHourTemp {
    color: #ffffff;
    font-size: 22px;
    font-weight: 700;
}

.weatherHourText {
    color: #cbd7df;
    font-size: 12px;
}

.weatherDaily {
    max-height: 332px;
    overflow-y: auto;
}

.weatherDay {
    border-bottom: 1px solid #244d66;
    display: grid;
    gap: 8px;
    grid-template-columns: 96px 70px minmax(0, 1fr);
    padding: 8px 10px;
}

.weatherDay:last-child {
    border-bottom: 0;
}

.weatherDayName {
    color: #ffcb52;
    font-weight: 600;
}

.weatherDayTemp {
    color: #ffffff;
    font-size: 20px;
    font-weight: 700;
}

.weatherDayText {
    color: #cbd7df;
    font-size: 13px;
}

.weatherPopupTitle {
    color: #102b41;
    font-weight: 700;
}

@media (max-width: 1100px) {
    .weatherLayout,
    .weatherForecastLayout,
    .weatherCurrentGrid {
        grid-template-columns: 1fr;
    }

    .weatherHourly {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    .weatherHeader {
        align-items: flex-start;
        flex-direction: column;
        gap: 8px;
    }

    .weatherHourly {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .weatherDay {
        grid-template-columns: 86px 58px minmax(0, 1fr);
    }
}
