html {
        height: 100%;
}

body {
    background-color: #E2EDF8;
    font-family: sans-serif;
    /* display: flex; */
    /*flex-flow: column nowrap;*/
    /*align-items: center; */
    margin: 5px;
}

.main-body {
    flex-flow: column nowrap;
    align-items: center;
    margin: 5px;
}

h1 {
    font-size: 1.5rem;
}

h2 {
    font-size: 1.0rem;
}

.predictions-plot {
    width: 100%;
    height: auto;
    max-width: 960px;
}

.ad-placeholder {
    height: 120px;
    width: 400px;
    color: white;
    background-color: black;
}

#sharing-group {
    width: 80%;
    max-width: 900px;
    /* display: flex; */
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
}

#ics {
   margin: 5px;
}

#addthis {
   margin: 5px;
}

#search-box {
   margin: 5px;
   max-width: 40%;
   flex: 0 1 auto;
   height: 80px;
}

.predictions-section {
    zzdisplay: flex;
    width: 100%;
    flex-flow: row wrap;
/*    border: 2px solid black;*/
/*    flex-flow: column nowrap; */
/*    justify-content: flex-start; */
    align-items: flex-start;
}

.predictions-table {
    flex: 0 0 auto;
  font-size: 0.9rem;
}

#mobile-ad {
    flex: 0 0 auto;
    /* border: 3px solid magenta; */
}

#desktop-ad {
    display: none;
}

.mgcsad {
    width: 100%;
}

.map {
    width: 100%;
    /* margin: auto; */
}

.map img {
    width: 100%; 
    height: auto;
    max-width: 542px;
}

.weather-menu {
    /* height: 80px; */
    width: 542px;
    display: flex;
    justify-content: center;
    /* width: 100%; */
}

.weather-menu a {
/*    flex: 1 0 auto;*/
    padding: 1rem;
} 

.weather-menu ul {
      display: flex; 
      /* width: 100%; */
      list-style-type: none;
    }

.weather-menu li {
          flex-grow: 1;
}

#controls-group {
    /* display: flex; */
    flex-flow: row wrap;
    justify-content: center;
    flex: 1 0 auto;
    width: 80%;
}

#time-control {
    flex: 0 1 30%;
    margin: auto;
}

#calendars-links {
    flex: 0 1 20%;
    margin: auto;
}

/* ===== Default: Mobile-first ===== */
.top-menu {
    display: none;
}

.bottom-menu {
    display: none;
}

.bottom-menu-small {
    flex: 0 1 auto;
    width: 100%;
    min-height: 60px;
    display: flex;
    justify-content: center;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

/* Menu list and item base styles (shared) */
.top-menu ul,
.bottom-menu ul,
.bottom-menu-small ul {
    display: flex;
    flex-wrap: nowrap;
    justify-content: center;
    list-style: none;
    margin: 0;
    padding: 0;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    width: 100%;
    gap: 0.5rem;
}

.top-menu li,
.bottom-menu li,
.bottom-menu-small li {
    flex: 0 0 auto;
    padding: 0.5rem 1rem;
    white-space: nowrap;
}

/* Menu link styles (shared) */
.top-menu a,
.bottom-menu a,
.bottom-menu-small a {
    text-decoration: none;
    display: block;
    padding: 0.5rem 1rem;
    color: inherit;
}

/* ===== Tablet & Desktop: breakpoint at 900px ===== */
@media (min-width: 900px) {
    .top-menu {
        display: flex;
        justify-content: center;
        width: 100%;
        max-width: 960px;
        margin: 0 auto;
        padding: 0 1rem;
    }

    .bottom-menu {
        display: flex;
        justify-content: center;
        width: 100%;
        max-width: 960px;
        margin: 0 auto;
        padding: 0 1rem;
    }

    .bottom-menu-small {
        display: none;
    }
}

/* ===== Below 900px: mobile layout ===== */
@media (max-width: 899px) {
    .top-menu {
        display: none;
    }

    .bottom-menu {
        display: none;
    }

    .bottom-menu-small {
        display: flex;
    }
}

/* ===== Base: hide by default ===== */
.simple-search {
    display: none;
    width: 100%;
    max-width: 600px;
    margin: 1rem auto;
    padding: 0 1rem;
    box-sizing: border-box;
}

/* Optional: input styling */
.simple-search input {
    width: 70%;
    padding: 0.5rem;
    font-size: 1rem;
    border: 1px solid #aaa;
    border-radius: 4px 0 0 4px;
    outline: none;
}

.simple-search button {
    width: 30%;
    padding: 0.5rem;
    font-size: 1rem;
    border: 1px solid #aaa;
    border-left: none;
    border-radius: 0 4px 4px 0;
    background-color: #337ab7;
    color: white;
    cursor: pointer;
}

/* ===== Show only on small screens ===== */
@media (max-width: 899px) {
    .simple-search {
        display: flex;
        justify-content: center;
        align-items: center;
    }
}
