/* Google fonts import */
@import url("https://fonts.googleapis.com/css2?family=Ruda:wght@400..900&display=swap");
@import url("https://fonts.googleapis.com/css2?family=Rock+Salt&display=swap");

/* Asterisk wildcard selector to override default styles added by the browser */
* {
  padding: 0;
  margin: 0;
  box-sizing: border-box;
}

/* General styles*/
body {
  font-family: "Ruda", Arial, sans-serif;
  line-height: 1.6;
  color: #333;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* Header */
header {
    background-color: #000000;
    padding: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    position: fixed;
    z-index: 99;
    box-shadow: 0 2px 5px #ffffff;
    width: 100%;
  }
  
.logo {
    color: #fff;
    font-size: 1.2rem;
    font-weight: bold;
    text-decoration: none;
  }

/* Navigation menu */
.menu-toggle {
    display: none;
  }
  
.menu-icon {
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 3px;
    color: #fff;
    font-size: 1.5rem;
  }
  
nav {
    position: absolute;
    top: 100%;
    left: -100%;
    background-color: #000000;
    width: 100%;
    transition: left 0.3s ease;
  }
  
nav ul {
    list-style-type: none;
  }
  
nav ul li a {
    color: #fff;
    text-decoration: none;
    display: block;
    padding: 0.2rem 1rem;
  }

/* Highlights active page */
.active {
    border-bottom: 1px solid #fff;
  }
  
.menu-toggle:checked ~ nav {
    left: 0;
  }

/* Main content */
main {
    flex: 1 0 auto;
    padding: 0;
  }

  h1 {
    text-align: center;
    font-size: 1.8rem;
  }

  /* Hero Section */
.hero {
  position: relative;
  width: 100%;
  height: 40vh;
  background-image: url("../images/depeche-mode-toronto.webp");
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  background-color: #333;
  display: flex;
  justify-content: center;
  align-items: center;
  color: white;
  text-align: center;
  margin-top: 60px;
}

.hero-content {
  position: relative;
  z-index: 1;
}

.hero::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 0;
}

.hero h1 {
  font-size: 3rem;
  margin: 0;
}

.hero p {
  font-size: 1.5rem;
  margin-top: 10px;
}

/* Footer styles */

footer {
  background-color: #000000;
  color: #fff;
  padding: 1rem;
  flex-shrink: 0;
}

.footer-content {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.social-links {
  margin-bottom: 1rem;
  text-align: center;
}

.social-links a {
  color: #fff;
  font-size: 1.5rem;
  margin: 0 0.5rem;
}

.footer-info {
  font-size: 0.8rem;
  text-align: center;
}

.footer-info a {
  font-family: "Rock Salt", cursive;
  text-decoration: none;
  color: #6791e0;
}

/* Modal styles */
.hidden {
  display: none;
}

.modal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 80%;
  max-width: 450px;
  background-color: #fff;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
  padding: 1.5rem;
  z-index: 100;
  display: none;
}

.modal-content {
  position: relative;
}

.modal-content h2 {
  font-size: 1.5rem;
  text-align: center;
}

.modal-content ul {
  list-style-type: none;
  padding: 0;
  text-align: center;
}

.modal-content ul li {
  margin-bottom: 0.5rem;
}

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

/* Action buttons*/
.action-buttons {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 20px;
  margin: 20px 0;
}

.action-buttons button {
  background-color: #000000;
  color: #fff;
  padding: 0.75rem 1.5rem;
  border-radius: 4px;
  cursor: pointer;
  border: 1px solid transparent;
  font-size: 1rem;
  width: 100%;
  max-width: 200px;
  transition: background-color 0.3s;
}

.action-buttons button:hover {
  background-color: #ffffff;
  color: #6791e0;
  border: 1px solid #6791e0;
}

/* Username input */
.username-form {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 20px;
}

#username-input {
  width: 100%;
  max-width: 150px;
  padding: 10px;
  margin-bottom: 10px;
  border: 1px solid #ccc;
  border-radius: 5px;
}

#username-submit {
  width: 100%;
  max-width: 150px;
  padding: 10px;
  background-color: #000000;
  color: #fff;
  border: 1px solid transparent;
  border-radius: 5px;
  cursor: pointer;
}

#username-submit:hover {
  background-color: #ffffff;
  color: #6791e0;
  border: 1px solid #6791e0;
}

/* Homepage with quiz, about page */
.quiz-container,
.about-container {
  max-width: 800px;
  margin: 0 auto;
  padding: 1rem 1rem;
}

#question-text {
  font-size: 24px;
  font-weight: bold;
  margin-bottom: 20px;
  text-align: center;
}

#answers {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 20px;
  margin-bottom: 20px;
}

#answers button {
  width: 100%;
  max-width: 300px;
  padding: 1rem;
  font-size: 1rem;
  background-color: #000000;
  color: #fff;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  border: 1px solid transparent;
  display: inline-block;
  box-sizing: border-box;
}

#answers button:hover {
  background-color: #ffffff;
  color: #6791e0;
  border: 1px solid #6791e0;
}

#feedback,
#score {
  font-size: 18px;
  margin-bottom: 20px;
  text-align: center;
}

.about-container p {
  text-align: center;
  width: 100%;
  margin: 0 auto;
  padding: 5px 10px;
}

h2 {
  text-align: center;
  font-size: 1.2rem;
}

/* Image gallery */
.image-grid {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 0 15px;
  margin: 20px auto;
}

.image-grid img {
  max-width: 90%;
  height: auto;
  object-fit: cover;
}

@media screen and (min-width: 576px) {
  /* Image gallery */
  .image-grid {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
  }

  .image-grid img {
    max-width: 45%;
  }
}

/* Media query for tablets and smaller devices (767px and down) */
@media screen and (max-width: 767px) {
  /* Highlights active page */
  .active {
    color: #2e3a63;
    background-color: #fff;
  }

  .hero h1 {
    font-size: 2rem;
  }

  .hero p {
    font-size: 1rem;
  }
}

/* Media queries for tablets and larger (768px and up) */
@media screen and (min-width: 768px) {
  /* Navigation menu */
  .menu-icon {
    display: none;
  }

  nav {
    position: static;
    width: auto;
    background-color: transparent;
  }

  nav ul {
    display: flex;
  }

  nav ul li {
    border-bottom: none;
    margin-left: 1rem;
  }

  /* Footer */
  .footer-content {
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-start;
  }

  .social-links {
    margin-bottom: 0;
  }

  .footer-info {
    text-align: justify;
  }
}

/* Media queries for laptops and desktops (1024px and up) */
@media screen and (min-width: 1024px) {
  /* Footer */
  .footer-content {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 2rem;
  }

  .social-links {
    margin-right: 1rem;
  }

  .footer-info {
    margin-left: 1rem;
  }
}