.main-container {
      display: grid;
      grid-template-columns: 1fr 1fr 1fr 1fr;
      grid-template-rows: 1fr auto 1fr;
      grid-gap:10px;
      width: 90%;
      margin: auto;
      padding-top: 10px;
      padding-bottom: 10px;
      position:relative;
}

.main-container > div {
      background-color: var(--dl-color-scheme-white);
      border: 7px solid black;
      border-radius: 10px;

}
table {
      margin:auto;
      font-size: 1.2vw;
}


#past-table {
      width:100%;
      height:100%;
      text-align: center;      

}

table td:nth-child(1){
      text-align: right;
}

#site-table td:nth-child(2){
      text-align: left;
}

.cond-table td:nth-child(1){
      text-align: left;
}

.cond-table td:nth-child(2){
      text-align: left;
}

.section-heading {
      color: var(--dl-color-scheme-white);
      background-color: var(--dl-color-scheme-md-red);
      width: 100%;
      font-size: 1.6vw;
      text-align: left;
      font-family: "Source Sans Pro";
      font-weight: 700;
      padding:10px;
      border-radius: 10px;
}

.subsection-heading{
      color: var(--dl-color-scheme-md-red);
      width: 100%;
      font-size: 1.5vw;
      text-align: center;
      font-family: "Source Sans Pro";
      font-weight: 700;
      padding: 10px;
}

#station_id {
      font-size: 1.2vw;
      text-align: left;
      font-family: "Source Sans Pro";
      font-weight: 700;
}

.conditions {
      grid-column: 1 / 4;
      grid-row: 1 / 2;
      width: 100%;
      min-height: 200px;
      text-align: center;
      background-color: transparent;
      justify-self: stretch;
      align-self: stretch;
}

#past_cond{
      grid-column: 1 / 3;
      grid-row: 2 / 3;
      text-align: center;
      justify-self: stretch;
      align-self: stretch;
      position: relative;
      display: table;
}

#snow-row{
      display: none;
}

#soil{
      grid-column: 3 / 4;
      grid-row: 2 / 3;
      width: 100%;
      text-align: center;
      justify-self: stretch;
      align-self: stretch;
      position: relative;
}
#site-pic {
      display: block;
      grid-column: 4 / 5;
      grid-row: 1 / 4;
      width: 100%;
      text-align: center;
      align-self: stretch;
      justify-self: stretch;
      position: relative;
      transition: 1s;
}

.curr-box {
      padding: 10px;
}

.timeseries {
      grid-column: 1 / 4;
      grid-row: 3 / 4;
      width: 100%;
      padding:10px;
      justify-self: center;
      align-self: stretch;
      text-align: center;
      border: solid black;
      background-color: var(--dl-color-scheme-white);
}

.plot-container {
      display: grid;
      grid-template-columns: 4fr 1fr;
      grid-template-rows: 1fr;
}
#timeseries-heading {
      padding:10px;
}

.sidebar {
      grid-column: 2 / 3;
      grid-row: 1 / 2;
      width: 100%;
      align-self: center;
      justify-self: center;
      padding: 5px;
      margin: 5px;
      box-sizing: border-box; 
      background-color: rgb(168, 25, 44);
      border-radius: 15px;
      font-family: "Source Sans Pro";
      color: white;
}

.sidebar p {
      color: white;
      margin-bottom: 10px;
      font-size: 18px;
      width:100%;
      }

.sidebar button {
      width:100%;
      font-size: 1.0vw;
      align-items: center;
      background-color: rgb(168, 25, 44);
      border: none;
      color: white;
      padding: 5px;
      margin-bottom: 10px;
      text-align: left;
      border-radius: 8px;
      cursor: pointer;
}

      /* hover effect on sidebar buttons */
.sidebar button:hover {
      background-color: #555;
      }


.icon {
      float: left;
      width: 50px;
      height: 50px;
      max-width: 20px;
      height: auto;
      margin-right: 10px;
      clear: left;
      display: block;
}

.temp {
      max-width: 10px;
      height: auto;
}

.dew {
      max-width: 15px;
      height: auto;
}


.chart {
      grid-column: 1 / 2;
      grid-row: 1 / 2;
}


/* The Modal (background) */
.modal {
display: none; /* Hidden by default */
position: fixed; /* Stay in place */
z-index: 10; /* Sit on top */
left: 0;
top: 0;
width: 100%; /* Full width */
height: 100%; /* Full height */
overflow: auto; /* Enable scroll if needed */
background-color: rgb(0,0,0); /* Fallback color */
background-color: rgba(0,0,0,0.4); /* Black w/ opacity */
}

/* Modal Content/Box */
.modal-content {
background-color: #fefefe;
margin: 15% auto; /* 15% from the top and centered */
padding: 40px;
border: 1px solid #888;
width: 60%; /* Could be more or less, depending on screen size */
}


/* The Close Button */
.close {
color: #aaa;
float: right;
font-size: 28px;
font-weight: bold;
}

.close:hover,
.close:focus {
color: black;
text-decoration: none;
cursor: pointer;
} 

#curr-flex{
      display:flex;
      justify-content:center;
      align-content: center;
}
#temp{
      flex:1;
      flex-grow:1;
      color: var(--dl-color-scheme-md-red);
      width: 100%;
      font-size: 3.5vw;
      text-align: center;
      font-family: "Source Sans Pro";
      font-weight: 700;
      padding-left: 0px;
      align-self: stretch;
      justify-self: stretch;
      vertical-align: middle;
      margin: auto;

}
#curr-table{
      margin-left:auto;
      margin-right:auto;
      flex-shrink:1;
      justify-self: stretch;
      align-self: stretch;
}


#myBtn {
      align-self: stretch;
      justify-self: stretch;
      font-size: 1.4vw;

}

.mdBtn:hover {
      cursor:pointer;
      fill: var(--dl-color-scheme-white);
      color: var(--dl-color-scheme-white);
      border: 3px solid var(--dl-color-scheme-white);
      background-color: var(--dl-color-scheme-md-red);
}

.mdBtn{
      color: var(--dl-color-scheme-md-red);
      margin-top: auto;
      text-align: center;
      transition: 0.3s;
      font-family: "Source Sans Pro";
      font-weight: 700;
      padding:0.5%;
      border-color: var(--dl-color-scheme-md-red);
      border-width: 3px;
      text-decoration: none;
      background-color: var(--dl-color-scheme-white);
}
#datetime{
      display: inline;
      text-align: left;
      font-size: 1.6vw;
      font-family: "Source Sans Pro";
      font-weight: 700;
      color: var(--dl-color-scheme-white);
}


.flex-condition{
      display:flex;
      flex-wrap: wrap;
      justify-content: space-around;
      align-items: flex-start;
      align-self: center;
      width: 100%;
}

#curr-wind{
      flex-grow: 1;
}

#curr-temp{
      flex-grow: 1;
}

#curr-other{
      flex-grow: 1;
}

#windContain{
      width:150px;
      height:150px;
      margin:0 auto;
      position:relative;
}

#wind_circ{
      width:120px;
      height:120px;
      position: absolute;
      top:15px;
      left:15px;
      background-color: transparent;
      border:10px solid var(--dl-color-scheme-md-red);
      border-radius: 50%;
}

.dir{
      color: var(--dl-color-scheme-md-red);
      font-family: "Source Sans Pro";
      font-weight: 700;
      width: 100%;
      position: absolute;
      font-size: 20px;

}

#pointContain{
      height: 150px;
      width: 150px;
      position: absolute;
      z-index: 1;
      transform: rotate(180deg);
      transform-origin: center;
      position: absolute;
}



#wind_point{
      margin: 0 auto;
      width: 0;
      height: 0;
      border-left: 20px solid transparent;
      border-right: 20px solid transparent;
      border-top: 40px solid black;
      -moz-border-radius: 50%;
      -webkit-border-radius: 50%;
      border-radius: 50%;
}

/*   GLOBAL MOBILE RESPONSIVE     */
/* ------------------------------ */

@media (max-width: 768px) {

      /* Prevent horizontal scrolling */
      body, html {
            overflow-x: hidden;
      }

      /* Main layout stacks vertically */
      .main-container {
            display: flex;
            flex-direction: column;
            padding: 0 10px;
      }

      /* Make each "curr-box" full-width */
      .curr-box,
      #site-pic,
      #soil,
      #past_cond,
      #timeseries {
            width: 100%;
            margin: 10px 0;
            padding: 15px;
      }

      /* Flex sections become vertical */
      .flex-condition {
            flex-direction: column;
            gap: 20px;
      }

      .cond-text {
            width: 100% !important;
      }

      /* Buttons scale */
      button, .sideButton {
            width: 100%;
            font-size: 1rem;
            padding: 10px;
      }

      /* Tables scale and scroll if needed */
      table {
            width: 100%;
            font-size: 0.9rem;
            overflow-x: auto;
            display: block;
      }

      /* Images and charts responsive */
      img,
      .slide-img {
            max-width: 100%;
            height: auto;
      }

      #chart {
            width: 100% !important;
            height: 300px !important;
      }

      /* Sidebar moves below the chart */
      .plot-container {
            display: flex;
            flex-direction: column;
      }

      .sidebar {
            width: 100%;
            margin-top: 10px;
      }

      /* Header style */
      .header-container {
            flex-wrap: wrap;
            justify-content: space-between;
      }

      .logo {
            max-width: 180px;
      }

      /* Hamburger menu wider tap target */
      .hamburger-btn span,
      .hamburger-btn span::before,
      .hamburger-btn span::after {
            height: 4px;
            width: 35px;
      }

      .menu-box {
            width: 100%;
            padding: 20px;
            font-size: 1.1rem;
      }

      /* Footer stacks nicely */
      .footer-container {
            display: flex;
            flex-direction: column;
            text-align: center;
            gap: 20px;
      }

      .footer-left,
      .footer-right {
            width: 100%;
      }
      #myBtn{
            font-size: 3vw;
      }
      #datetime{
            font-size: 4vw;
      }
      .sidebar button{
            font-size: 3vw;
      }
}

/* Optional: extra-small screens */
@media (max-width: 480px) {
      h2.section-heading {
            font-size: 1.3rem;
      }
      h3.subsection-heading {
            font-size: 1.1rem;
      }
      .cond-table td {
            padding: 6px 2px;
      }

}
