@import url("https://fonts.googleapis.com/css2?family=Bakbak+One&display=swap");

/* =====================================
   Main Body Layout - Sets the background with a radial gradient for the entire page
   ===================================== */
body {
  background-image: radial-gradient(
    circle,
    rgb(246, 255, 0),
    rgb(0, 191, 255),
    blue
  );
}

/* =====================================
   Header Tag Styling - Applies to all heading tags (h1 to h6) for consistent font and color
   ===================================== */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: Bakbak One, sans-serif;
  color: rgb(255, 255, 255);
  font-weight: 900;
}

/* =====================================
   START: MAIN BANNER-HEADER STYLING - Styles the header section containing the logo, title, and FAQ button
   ===================================== */

.header {
  background-color: rgba(
    245,
    222,
    179,
    0
  ); /* Transparent background for the main header container */
}

/* Main Header Container - Flexbox for organizing the logo, catchy title, and FAQ button */
.headerOrganizationBox {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  padding: 3vw;
}

/* Logo Container - Centers the business logo image within the header */
.headerImageContainer {
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Business Logo Image - Ensures the logo scales appropriately */
.header-image {
  max-width: 100%;
  width: 50%;
  border: 2px groove white;
  border-radius: 8px;
  box-shadow: 0px 0px 2px 2px rgba(0, 0, 0, 0.7);
}

/* Catchy Header Title - Styles the main title "Instant, Accurate Weather at Your Fingertips." */
.catchyHeaderTitle {
  font-size: 8vw;
  text-align: center;
  -webkit-text-stroke: 0.5px rgb(0, 0, 0);
}

/* FAQ Button Container - Centers the FAQ button in the header */
.headerButton {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 5vh;
  max-width: 100%;
  width: 100%;
}

/* FAQ Button Styling - General styling for the FAQ button element */
.headerButton button {
  height: 30%;
  max-width: 100%;
  font-family: Bakbak One;
  border-radius: 5px;
  background-image: linear-gradient(
    rgb(181, 181, 181),
    white,
    rgb(255, 255, 255),
    rgb(188, 188, 188)
  );
  border: 2px outset rgb(255, 255, 255);
  border-style: ridge;
  color: black;
}

.headerButton button:active:not(:disabled) {
  background-image: linear-gradient(
    rgb(181, 181, 181),
    white,
    rgb(255, 255, 255),
    rgb(188, 188, 188)
  );
}

/* FAQ Button Specific Styling - Defines size and hover effect for the FAQ button */
#actualButton {
  max-width: 100%;
  width: 180px;
  height: 5vh;
}

#actualButton:hover {
  background-color: rgba(255, 255, 255, 0.657);
  cursor: pointer;
}

/* =====================================
   END: MAIN BANNER-HEADER STYLING
   ===================================== */

/* =====================================
   Three Day Forecast Link Styling - Styles the link to switch to the three-day forecast page
   ===================================== */
.three-day-link {
  cursor: pointer;
  background-image: radial-gradient(
    circle,
    rgb(0, 0, 0),
    rgb(0, 208, 255),
    blue
  );
  color: rgb(255, 255, 255);
  border: 3px groove rgb(255, 255, 255);
  border-radius: 4px;
  font-family: "Bakbak One", sans-serif;
  text-decoration: none;
  padding: 8px 16px;
  display: inline-block;
  font-size: 1.5rem;
  -webkit-text-stroke: 0.8px black;
}

.three-day-link:hover {
  background-image: radial-gradient(
    circle,
    rgb(0, 0, 0),
    rgb(0, 208, 255),
    rgb(255, 247, 0)
  );
  border: 4px inset rgb(255, 255, 255);
}

.three-day-link-container {
  display: flex;
  justify-content: center;
  padding: 10px;
  text-align: center;
  -webkit-text-stroke: 0.8px black;
  margin-bottom: 15px;
}

/* =====================================
   START: FRONT PAGE MENU STYLING - Styles the section for entering city/state or zip code
   ===================================== */

.frontPageMenuMainBox {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 2vh 0;
}

/* Front Page Menu Header - Centers the "Current Forecast" heading */
.frontPageMenu-Header {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

/* Current Forecast Heading - Styles the "Current Forecast" text */
.currentForecast {
  font-size: 5vh;
  -webkit-text-stroke: 0.8px rgb(0, 0, 0);
}

/* City Input Label Container - Centers the label for city/state or zip code input */
.cityName-container {
  text-align: center;
  margin-bottom: 20px;
}

/* City Input Label - Styles the text "Enter a City and State or Zipcode" */
.cityName-label {
  display: block;
  margin-bottom: 5px;
  font-family: Bakbak One;
  font-size: 2.2rem;
  color: white;
}

/* Text Input Field - Styles the input box for entering city/state or zip code */
input[type="text"] {
  padding: 8px;
  border: 3px solid #00b7ff;
  border-radius: 4px;
  font-size: 1rem;
  width: 90%;
  font-family: Bakbak One;
  margin: 0 auto;
  text-align: center;
}

/* Input Field Container - Centers the text input field */
.inputContainer {
  display: flex;
  justify-content: center;
}

/* Submit Button Container - Centers the "Retrieve Forecast" button */
.button-container {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 1vh 0;
}

/* Submit Button Styling - Styles the "Retrieve Forecast" button with hover effect */
.cityNameSubmitButton {
  height: 10vh;
  width: 200px;
  max-width: 100%;
  font-family: "Bakbak One", sans-serif;
  border-radius: 5px;
  background-image: linear-gradient(
    rgb(181, 181, 181),
    white,
    rgb(255, 255, 255),
    rgb(188, 188, 188)
  );
  border: 3px outset rgb(255, 255, 255);
  color: rgb(0, 0, 0);
  cursor: pointer;
}

.cityNameSubmitButton:active:not(:disabled) {
  background-color: rgba(212, 212, 212, 0.745);
  border: 3px inset black;
}

/* =====================================
   END: FRONT PAGE MENU STYLING
   ===================================== */

/* =====================================
   START: FORECAST DISPLAY STYLING - Styles the section that displays weather forecast information
   ===================================== */

/* Forecast Display Container - Initially hidden, displays weather details when retrieved */
.foreCastBox {
  max-width: 100%;
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 2vh;
  padding: 2vh 0;
}

/* Forecast Title Container - Displays city, state, and "Forecast" text */
.forecastTitleFormatting {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  font-size: 2rem;
  text-align: center;
  max-width: 100%;
  margin: 0;
  height: auto;
  font-family: Bakbak One, sans-serif;
}

/* City Name - Styles the city name display with text overflow handling */
#location {
  color: rgb(255, 255, 255);
  font-size: 2.5rem;
  max-width: 320px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  -webkit-text-stroke: 0.8px rgb(0, 0, 0);
  height: auto;
}

/* State or Region - Styles the state display with text overflow handling */
#regionLocation {
  color: rgb(255, 255, 255);
  font-size: 2rem;
  max-width: 320px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  -webkit-text-stroke: 0.8px rgb(0, 0, 0);
  height: auto;
}


/* Weather Condition Container - Centers the weather condition description */
.typeOfWeatherForecasted {
  display: flex;
  justify-content: center;
  align-items: center;
  height: auto;
  text-align: center;
}

/* Weather Condition Description - Styles the text describing the weather condition */
.condition {
  font-size: 2.5rem;
  -webkit-text-stroke: 0.8px rgb(0, 0, 0);
  text-align: center;
}

/* Weather Image Container - Centers the weather condition image */
.weatherPictureContainer {
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Weather Image - Ensures the weather image scales appropriately */
#weatherPicture {
  max-width: 70%;
}

/* Forecast Details Container - Displays temperature and other weather details */
.foreCastHighLows {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  align-items: center;
  font-family: Bakbak One, sans-serif;
  color: white;
  max-width: 100%;
}

.foreCastHighLows p {
  font-size: 2rem;
}

/* Temperature Text Container - Centers the temperature label and value */
.temperatureParentBox {
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  flex-direction: column;
}

.temperatureParentBox p {
  margin: 0;
}

/* Temperature Label - Styles the "Temperature" text with underline */
.Temperature {
  color: yellow;
  -webkit-text-stroke: 0.8px black;
  text-decoration: underline;
}

/* Weather Details Table - Styles the table for precipitation, humidity, wind, etc. */
.tableStyling {
  color: white;
  font: Bakbak One, sans-serif;
  font-size: 1rem;
  font-weight: 200;
  text-align: center;
  box-shadow: 0px 0px 5px 5px rgba(0, 0, 0, 0.7);
  margin-left: auto;
  margin-right: auto;
  width: auto;
  border-radius: 8px;
  border: 2px groove rgb(0, 0, 0);
}

.tableStyling th {
  font-family: "Bakbak One", sans-serif;
  color: white;
  width: auto;
}

.tableMainHeader {
  border-collapse: collapse;
  width: 100%;
  max-width: 100%; /* Prevent overflow */
  table-layout: fixed; /* Force columns to respect container width */
  font-size: 1.5rem;
}

/* Table Headers - Styles the header rows for weather details */
.tableHeadersStyling th {
  font-family: "Bakbak One", sans-serif;
  color: white;
  -webkit-text-stroke: 0.5px black;
  border: 2px groove rgb(255, 255, 255);
  width: auto;
  font-size: 1rem;
}

/* Table Contents - Styles the content rows for weather details */
.tableContentsStyling {
  background-color: rgba(0, 97, 224, 0);
}

/* Air Quality Table - Styles the table explaining the EPA Air Quality Index */
.airQualityTable {
  width: 100%;
  margin-top: 2vh;
  color: rgb(0, 0, 0);
  font: Bakbak One, sans-serif;
  font-size: 1.25rem;
  font-weight: 200;
  text-align: center;
  box-shadow: 0px 0px 5px 5px rgba(0, 0, 0, 0.7);
  background-color: rgb(0, 0, 0);
  border-radius: 10px;
  border: 2px groove rgb(0, 0, 0);
}

.airQualityTable th {
  width: 50%;
  color: rgb(0, 0, 0);
  font: Bakbak One, sans-serif;
  font-size: 1.25rem;
  border: 4px solid black;
  border-color: rgb(0, 0, 0);
  border-radius: 2px;
}

.airQuality {
  height: 75px;
}

/* Temperature Display - Styles the temperature value */
.temp {
  text-align: center;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  width: 100%;
  font-size: 2.5rem;
}

/* =====================================
   END: FORECAST DISPLAY STYLING
   ===================================== */

/* =====================================
   START: THREE DAY FORECAST STYLING - Styles elements for the three-day forecast page (threeday.html)
   ===================================== */

/* Three Day Forecast Container - Initially hidden, displays three-day forecast details */
.threeDayForecast {
  display: none;
  justify-content: space-between;
  gap: 10px;
}

/* Individual Day Forecast - Styles each day's forecast block */
.dayForecasted {
  flex: 1;
  text-align: center;
}

/* Three Day Forecast Main Container - Organizes the three-day forecast layout */
.threeDayForecastContainer {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

/* Individual Day Containers - Styles each day's forecast details */
.dayOne,
.dayTwo,
.dayThree {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  width: 100%; /* Ensures each day takes full container width for centering */
}

/* Three Day Forecast Table - Styles the table for each day's weather details */
.threeDayForecastTable {
  font-family: "Bakbak One", sans-serif;
  color: white;
  outline: 2px solid black;
  margin-top: 20px; /* Adds space between image and table */
}

/* Three Day Table - Styles the table structure for each day's forecast */
.threeDayTable {
  border-collapse: collapse;
  width: auto; /* Lets table size naturally, can adjust if needed */
}

.threeDayTable th,
.threeDayTable td {
  padding: 8px;
  border: 2px solid black;
}

/* =====================================
   END: THREE DAY FORECAST STYLING
   ===================================== */

footer {
  background-color: #1a3c5e00; /* A weather-inspired dark blue */
  color: #ffffff;
  padding: 2rem 1rem;
  text-align: center;
  font-family: Bakbak-One, sans-serif;
}

.footer-content h4 {
  margin: 0;
  font-size: 1.5rem;
  font-weight: bold;
  font-family: Bakbak-One, sans-serif;
}

.footer-content p {
  margin: 0.5rem 0;
  font-size: 0.9rem;
  font-family: Bakbak-One, sans-serif;
}

.footer-links {
  margin-top: 1rem;
  font-family: Bakbak-One, sans-serif;
}

.footer-links a {
  color: #a8c7fa; /* Light blue for links */
  text-decoration: none;
  font-size: 0.85rem;
  margin: 0 0.5rem;
  font-family: Bakbak-One, sans-serif;
}

.footer-links a:hover {
  text-decoration: underline;
}

/* =====================================
   Responsive Design - Media Queries for adjusting layout on different screen sizes
   ===================================== */

/* 320px Width - Adjustments for small screens (e.g., mobile devices) */
@media screen and (min-width: 320px) {
  /* Adjust FAQ button height */
  #actualButton {
    height: 5vh;
  }

  /* Adjust front page menu layout */
  .frontPageMenuMainBox {
    justify-content: flex-start;
    padding: 1vh 0;
  }

  .frontPageMenu-Header {
    align-items: flex-start;
  }

  /* Adjust weather details table margins */
  .tableStyling {
    margin-top: 20px;
  }

  .airQualityTable {
    margin-top: 2vh;
    width: 80%;
  }

  /* Ensure three-day forecast displays in a column on small screens */
  .threeDayForecastContainer {
    flex-direction: column;
  }
}

/* 375px Width - Additional adjustments for slightly larger mobile screens */
@media screen and (min-width: 375px) {
  /* Adjust current forecast heading size */
  .currentForecast {
    font-size: 5vh;
    -webkit-text-stroke: 0.8px rgb(0, 0, 0);
  }

  /* Adjust weather image size */
  #weatherPicture {
    max-width: 50%;
  }

  /* Adjust weather details table margins */
  .tableStyling {
    margin-top: 20px;
  }

  .airQualityTable {
    margin-top: 2vh;
    width: 80%;
  }
}

/* 450px Width - Adjustments for medium-sized screens */
@media screen and (min-width: 450px) {
  /* Adjust header title size */
  .catchyHeaderTitle {
    font-size: 5vw;
  }

  /* Adjust current forecast heading size */
  .currentForecast {
    font-size: 32px;
  }

  /* Adjust city input label size */
  .cityName-label {
    font-size: 2.2rem;
  }

  /* Adjust forecast details layout to column on medium screens */
  .foreCastHighLows {
    flex-direction: column;
  }

  /* Adjust weather condition text size */
  .condition {
    font-size: 2.5rem;
    -webkit-text-stroke: 0.8px rgb(0, 0, 0);
    text-align: center;
  }


  /* Adjust weather image size */
  #weatherPicture {
    max-width: 40%;
  }

  /* Adjust weather details table styling */
  .tableStyling {
    width: 40%;
    font-size: 1.25rem;
    margin-top: 20px;
  }

  .tableStyling th {
    width: 40%;
    font-size: 1.25rem;
  }

  .tableStyling th,
  .tableStyling td {
    width: auto;
    height: auto;
  }

  .airQualityTable {
    margin-top: 2vh;
    width: 80%;
  }
  .headerButton {
    height: 8vh;
  }
  /* FAQ Button Specific Styling - Defines size and hover effect for the FAQ button */
  #actualButton {
    height: 8vh;
  }
}

/* 540px Width - Adjustments for larger medium screens */
@media screen and (min-width: 540px) {
  /* Adjust header title size */
  .catchyHeaderTitle {
    font-size: 5vw;
  }

  /* Adjust current forecast heading size */
  .currentForecast {
    font-size: 10vh;
  }

  /* Adjust submit button height */
  .cityNameSubmitButton {
    height: 12vh;
  }

  /* Adjust forecast details layout for even spacing */
  .foreCastHighLows {
    justify-content: space-evenly;
  }


  /* Adjust weather image size */
  #weatherPicture {
    max-width: 40%;
  }

  /* Adjust weather details table styling */
  .tableStyling {
    font-size: 1.25rem;
    margin-top: 20px;
  }

  .tableStyling th {
    width: 40%;
    font-size: 1.25rem;
  }

  .tableStyling th,
  .tableStyling td {
    width: auto;
    height: auto;
  }

  .airQualityTable {
    margin-top: 2vh;
    width: 80%;
  }

  /* Display three-day forecast in a row on larger medium screens */
  .threeDayForecastContainer {
    flex-direction: row;
  }
  .headerButton {
    height: 8vh;
  }
  #actualButton {
    height: 8vh;
  }
}

/* 800px Width - Adjustments for desktop screens */
@media screen and (min-width: 800px) {
  /* Adjust header layout to prevent wrapping */
  .headerOrganizationBox {
    flex-wrap: nowrap;
    justify-content: space-around;
    padding: 3vw;
    max-width: 100%;
    width: auto;
  }

  /* Adjust header title size */
  .catchyHeaderTitle {
    font-size: 4vw;
  }

  /* Adjust logo container size */
  .headerImageContainer {
    width: 20%;
  }

  /* Adjust logo image size */
  .header-image {
    height: 50%;
  }

  /* Adjust FAQ button container width */
  .headerButton {
    width: 20%;
  }

  /* Adjust FAQ button height */
  #actualButton {
    height: 5vh;
  }

  /* Adjust current forecast heading size */
  .currentForecast {
    font-size: 10vh;
  }

  /* Adjust city input label size */
  .cityName-label {
    font-size: 3.2rem;
  }

  /* Adjust submit button height */
  .cityNameSubmitButton {
    height: 12vh;
  }

  /* Adjust weather condition container alignment */
  .typeOfWeatherForecasted {
    align-items: flex-start;
    width: auto;
  }

  /* Adjust forecast display layout */
  .foreCastBox {
    justify-content: center;
    gap: 0.1vh;
    padding: 0.1vh 0;
    height: auto;
  }

  /* Adjust forecast details layout for desktop */
  .foreCastHighLows {
    flex-wrap: nowrap;
    flex-direction: row;
    gap: 5%;
  }

  /* Adjust weather condition text size */
  .condition {
    font-size: 2.5rem;
    -webkit-text-stroke: 0.8px rgb(0, 0, 0);
    text-align: center;
  }

  /* Adjust weather image size */
  #weatherPicture {
    max-width: 30%;
  }


  /* Adjust temperature label color */
  .Temperature {
    color: rgb(255, 255, 255);
  }

  /* Adjust weather details table styling */
  .tableStyling {
    font-size: 1.25rem;
  }

  .tableStyling th {
    width: 40%;
    font-size: 1.25rem;
  }

  .tableStyling th,
  .tableStyling td {
    width: auto;
    height: auto;
  }

  .airQualityTable {
    margin-top: 8vh;
    width: 40%;
  }

  /* Display three-day forecast in a row on desktop screens */
  .threeDayForecastContainer {
    flex-direction: row;
  }
}

/* Only on devices with a mouse and not touchscreen */

@media (hover: hover) and (pointer: fine) {
  .headerButton button:hover {
    background-image: linear-gradient(
      rgb(97, 97, 97),
      white,
      rgb(255, 255, 255),
      rgb(83, 83, 83)
    );
  }
  .cityNameSubmitButton:hover {
    background-color: rgba(212, 212, 212, 0.745);
    background-image: linear-gradient(
      rgb(181, 181, 181),
      rgb(5, 255, 201),
      rgb(238, 255, 0),
      rgb(188, 188, 188)
    );
    border: 4px inset rgb(255, 255, 255);
  }
}
