/* Global styles */
html {
  font-size: 12pt;
}

* {
  box-sizing: border-box;
  padding: 0px;
  cursor: pointer;
}

body {
  font-family: "National Park", sans-serif;
  background: white !important;
  padding: 10px;
  overflow-x: hidden;

}

h2 {
  font-family: "Cal Sans", sans-serif;
  font-size: 30px;
  letter-spacing: 1px;
  font-weight: bold; 
  color: #395735;
  text-align: center;
}

h3 {
  font-family: "Cal Sans", sans-serif;
  font-size: 20px;
}

header{
  padding: 0px;
  text-align: center;
  font-size: 10px;
  color: #395735;
}

/* Bison video at the top of the website */
.video-home {
  height: calc(100vh - 60px); 
  position: relative;
  padding: 10px;
  margin-bottom: 0px;
}

#bison-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border: 5px solid #546d54;
  border-radius: 15px;
}

/* Title/text over bison video */
.bison-video-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  color: white;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: fit-content;
}

.bison-video-text h1 {
  font-size: 70px;
  font-family: "Cal Sans", sans-serif;
  letter-spacing: 2px;
  max-width: 90vw;        
  text-align: center;
}

/* About NPS card */
.about-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  margin-top: 20px;
  padding: 10px;
}

.about-card img {
  max-width: 250px;
  height: auto;
  display: block;
}

.about-card p {
  text-indent: 20px;
  color: #395735;
}

/* Timeline */
.timeline {
  position: relative;
  width: 100%;
  margin: 30px auto;
  min-height: 400px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-inline: 45px; 
  box-sizing: border-box;
}

/* Timeline arrows/buttons */
.arrow-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 20px;
  background-color: #395735;
  border: 5px solid #546d54;
  color: white;
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 15px;
  z-index: 10;
  transition: background-color 0.3s;
}

.arrow-btn:hover {
  background-color: #546d54;
}

#backBtn {
  left: 10px;
}

#nextBtn {
  right: 10px;
}

/* --- Timeline container --- */
.timeline-container {
  position: relative;
  width: 100%;
  min-height: 1050px;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
}

.timeline-card {
  position: absolute;
  width: 90%;
  max-width: 700px;
  background: #546d54;
  border: 5px solid #395735;
  border-radius: 15px;
  text-align: center;
  padding: 10px;
  opacity: 0;
  transition: opacity 0.5s, transform 0.5s;
  box-sizing: border-box;
}

.timeline-card.active {
  opacity: 1; 
  transform: translateX(0); 
}

.timeline-card.prev {
  opacity: 0.5; 
  transform: translateX(-100%); 
}

.timeline-card.next {
  opacity: 0.5; 
  transform: translateX(100%); 
}

/* --- Timeline image and text --- */
.timeline-image {
  width: 100%;
  max-width: 300px;
  height: auto;
  border: 5px solid #395735;
  border-radius: 15px;
  margin-bottom: 10px;
}

.timeline-text {
  font-size: 15px;
  line-height: 1.5;
  color: white;
}

.timeline-text h1{
  font-size: 20px;
}

/* Top five most visted park card description */
.topfive-data-description {
  padding: 10px;
  padding-top: 0px;
  text-indent: 20px;
  color: #395735;
  margin-top: 10px;
  gap: 20px;
}

.topfive-data-description h3{
  text-decoration: underline;
  text-underline-offset: 2px;
  color: #546d54;
  text-align: center;
  text-indent: 0px;
}

/* Top five most visited park cards */
.topfive-container {
  gap: 50px;
  padding-bottom: 10px;
  display:flex;
  flex-wrap:wrap;
  justify-content:center;
  align-items:center;
}

.topfive-container h2{
  font-size: 30px;
}

.topfive {
  width: 350px;
  background: #395735;
  border-radius: 15px;
  overflow: hidden;
  border: 5px solid #546d54;
  padding: 15px;
}

.topfive-description {
  display: none;
  padding: 12px;
  background-color: #ffffff;
  border-radius: 15px;
  color: #546d54;
  text-align: center;
}

/* Show description when top five card is clicked on */
.topfive-description.show {
  display: block;
  max-height: 500px;
  transform: scaleY(1);
}

.topfive-image {
  width: 100%;
  height: 210px;
  border-radius: 15px;
  object-fit: cover;
  padding: 10px;
}

/* Flourish chart description and bison image */
.flourish-container {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 20px;
  align-items: center; 
  margin-top: 30px;
  padding: 10px
}

.flourishchart-description {
  text-indent: 20px;
  color: #395735;
}

.bison-pic {
  display: none;
}

/* Flourish chart */
.flourish-topfivechart {
  width: 100%;
  max-width: 800px;
  overflow: hidden;
  border: 5px solid #546d54;
  border-radius: 15px;
}

/* Quiz header */
.quiz-header h3 {
  text-decoration: underline;
  text-underline-offset: 2px;
  text-align: center;
  color:  #546d54;
  margin-top: 0px;
  padding: 10px;
}

/* Quiz */
.quiz-layout {
  display: flex;
  justify-content: center; 
  align-items: center;    
  height: 100%;          
}

.quiz-box {
  border: 5px solid #395735;
  border-radius: 15px;
  padding: 5px;
  max-width: 350px;
  margin: 0px;
  background-color: #546d54;
  color: white;
  padding-left: 10px;
}

/* Submit quiz button and result */
#submit {
  background-color: #395735;;
  border: 1px solid white;
  color: white;         
  padding: 10px;                    
  border-radius: 15px;     
  font-size: 16px;
  margin: 20px auto;
  transition: background-color 0.3s ease;
  text-align: center;
  display: block;
  font-family: "Cal Sans", sans-serif;
  letter-spacing: 1px;
}

#submit:hover {
  background-color: #546d54;
}

#result {
  text-align: center; 
  margin-top: 20px;   
}

/* Hiking picture with quiz */
.hiking-pic {
  display: none;
}

/* Button that scrolls from bottom to top */
.scroll-to-top {
  display: flex;
  justify-content: center;
  margin: 20px;
  padding: 10px;
}

#top-btn {
  padding: 15px 15px;
  font-size: 15px;
  background-color: #395735;
  color: white;
  border: none;
  border-radius: 15px;
  cursor: pointer;
  transition: background-color 0.3s ease;
  font-family: "Cal Sans", sans-serif;
  letter-spacing: 1px;
}

#top-btn:hover {
  background-color: #546d54;
}

#top-btn:active {
  transform: translateY(1px);
}

/* Modal sources window */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;   
  height: 100vh; 
  justify-content: center;
  border-radius: 15px;
  align-items: center;
  z-index: 1000;
}

.modal-content {
  background-color: #395735;
  border: 5px solid #546d54;
  padding: 20px;
  border-radius: 15px;
  width: 300px;
  text-align: center;
  position: relative;
  font-size: 10px;
  color: white;
  max-width: 90%;
}


.modal a {
  color: white;
}

.modal-content h2{
  margin: 0px;
  color: white;
}

.modal-content ul {
  padding: 10px;
  font-size: 10px;
}

.close-btn {
  font-size: 24px;
  cursor: pointer;
  position: absolute;
  top: 10px;
  right: 10px;
}

/* Footer */
.footer {
  position: relative;
  bottom: 0;
  left: 0;
  width: 100%; 
  color: white;
  text-align: center;
  padding: 7px;
  display: block !important;
}

#trigger {
  padding: 7px;
  font-size: 12px;
  color: #546d54;
  cursor: pointer;
  transition: background-color 0.3s;;
  background-color: white;
  border: 1px solid #395735;
  font-family: "National Park", sans-serif;
  border-radius: 15px;
}

.footer.visible {
  display: block;
}

/* Desktop */
@media screen and (min-width: 1080px) {
/* Global styles */
  h2 {
    font-size: 40px;
  }

/* Desktop title/text over bison video */
  .bison-video-text h1 {
    font-size: 100px;
    display: inline-block;
    white-space: nowrap;
    max-width: 100%; 
  }

/* Desktop about NPS card */
  .about-card {
    flex-direction: row;
    justify-content: center;
    text-align: left;
  }

  .about-card h2{
    margin: 0px;
    margin-top: 5px;
  }

  .about-paragraphs {
    font-size: 18px;
  }

  .about-card img {
    max-width: 300px;
    height: auto;
    margin-right: 10px;
  }

/* Desktop timeline */
  .timeline-container {
    min-height: 700px;
  }

  .timeline-text h1{
    font-size: 25px;
  }

  .arrow-btn {
    width: 60px;
    height: 60px;
    font-size: 30px;
  }

/* Desktop top five most visted park card description */
  .topfive-data-description {
    font-size: 18px;
    padding-top: 0px;
  }

/* Desktop top five most visited park cards */
  .topfive {
    width: 400px;
  }

  .topfive-image {
    width: 100%;
    height: 250px;
    object-fit: cover;
    border-radius: 15px;
    padding: 10px;
  }

/* Desktop flourish chart description and bison image */
.flourish-container {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  gap: 40px;
  align-items: flex-start;
  max-width: 1400px;
  margin-top: 10px;
}

.flourishchart-description {
  flex: 0 0 45%;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
}

.bison-pic {
  width: 100%;
  display: block;
  margin-left: auto;
  margin-right: auto;
  border: 5px solid #546d54;
  border-radius: 15px;
}

.flourish-topfivechart .flourish-embed {
  width: 100%;
  min-height: 500px; 
}

/* Desktop quiz */
  .quiz-layout {
    display: flex;
    justify-content: center;       
    align-items: center;           
    gap: 40px;                    
    max-width: 1100px;             
    margin: 0 auto;               
    padding: 20px;
    height: 100%;                
    box-sizing: border-box;             
  }

  .quiz-box {
    width: 50%;                      
    max-width: 500px;             
  }

/* Desktop hiking picture with quiz */
  .hiking-pic {
    display: block;              
    width: 50%;                       
    max-width: 500px;            
    border: 5px solid #546d54;
    border-radius: 15px;
  }

/* Desktop button that scrolls from bottom to top */
  #top-btn{
    font-size: 18px;
  }
}