/* Media query for larger screens */
@media screen and (min-width: 1200px) {
  nav h3 {
    font-size: 2rem;
  }
}
 /* Media query for larger screens */
 @media (min-width: 768px) {
  .header-title {
    font-size: 6rem;
  }
   .header-subtitle {
    font-size: 3rem;
  }
}
 /* Media query for larger screens */
 @media screen and (min-width: 1600px) {
  .chapter {
    max-width: 1200px;
  }
}
/* Center the progress bar horizontally for desktop devices */
@media only screen and (min-width: 768px) {
  progress {
    left: 50%;
    max-width: 800px;
    transform: translateX(-50%);
  }
}

/* Set special fixing for mobile devices */
@media only screen and (max-width: 767px) {
  progress {
    left: 0;
    max-width: 100%;
    transform: none;
  }
}


/* Set smaller background size and adjust background position for tablet devices */
@media only screen and (min-width: 768px) and (max-width: 1023px) and (max-height: 767px) {
  header {
    background-size: auto 100%;
    background-position: center;
  }
}


/* Adjust Particle Sliders for smaller screens (tablets) */
@media only screen and (max-width: 2000px) {
  .slider-container label {
    width: 40px;
    height: 40px;
    padding: 0;
    border-radius: 50%;
    font-size: 0;
    position: relative;
    z-index: 10;
  }

  .slider-container label[for="particleCount"] {
    background-image: url('/files/sites/Book/Castlehaven/pictures/count.png');
    background-size: cover;
  }

  .slider-container label[for="particleSpeed"] {
    background-image: url('/files/sites/Book/Castlehaven/pictures/speed.png');
    background-size: cover;
  }

  .slider-container label[for="particleSize"] {
    background-image: url('/files/sites/Book/Castlehaven/pictures/size.png');
    background-size: cover;
  }

  .slider-wrapper {
    position: fixed;
    left: 1rem;
    bottom: 9rem;
    z-index: 10;
    display: flex;
    flex-direction: column;
  }

  .slider-container.active label {
    background-color: darkgrey;
  }

  input[type="range"] {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    width: 6px;
    height: 150px;
    background-color: #ddd;
    border-radius: 25px;
    outline: none;
    margin: 0;
    padding: 0;
    cursor: pointer;
    position: fixed;
    top: 170px; /* Adjust this value to position the range slider above the containers */
    left: 0%;
    transform: translateX(-50%);
    z-index: 10;
    opacity: 0;
    transition: all 0.2s ease-in-out;
  }

  .slider-container.active input[type="range"] {
    opacity: 1;
  }
}

/* Adjust Particle Sliders for smaller screens (phones) */
@media only screen and (max-width: 1080px) {
  .slider-container label {
    width: 40px;
    height: 40px;
    padding: 0;
    border-radius: 50%;
    font-size: 0;
    position: relative;
    z-index: 10;
  }

  .slider-container label[for="particleCount"] {
    background-image: url('/files/sites/Book/Castlehaven/pictures/count.png');
    background-size: cover;
  }

  .slider-container label[for="particleSpeed"] {
    background-image: url('/files/sites/Book/Castlehaven/pictures/speed.png');
    background-size: cover;
  }

  .slider-container label[for="particleSize"] {
    background-image: url('/files/sites/Book/Castlehaven/pictures/size.png');
    background-size: cover;
  }

  .slider-wrapper {
    position: fixed;
    left: 1rem;
    bottom: 9rem;
    z-index: 10;
    display: flex;
    flex-direction: column;
  }

  .slider-container.active label {
    background-color: darkgrey;
  }

  input[type="range"] {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    width: 6px;
    height: 150px;
    background-color: #ddd;
    border-radius: 25px;
    outline: none;
    margin: 0;
    padding: 0;
    cursor: pointer;
    position: fixed;
    top: 170px; /* Adjust this value to position the range slider above the containers */
    left: 0%;
    transform: translateX(-50%);
    z-index: 10;
    opacity: 0;
    transition: all 0.2s ease-in-out;
  }

  .slider-container.active input[type="range"] {
    opacity: 1;
  }
}





/* Adjust Nav for smaller screens (phones) */
@media only screen and (max-width: 1080px) {
  #navbox ol {
    flex-direction: column;
  }
  
  #navbox li {
    width: 100%;
  }
  #content {
    margin-left: 30px; /* Adjust this value to your desired amount */
    margin-right: 10px;
    padding-right: 0%;
  }
  #chapter {
    margin: 0; 
  }
  #articles-js-canvas-el {
    width: auto;
    height: auto;
  }
}
