:root {
  --primary-color: #00ed64; /* Soft Forest Green */
  --secondary-color: #21313c; /* Light Gold */
  --accent-color: #7d8b5a; /* Soft Olive Green */
  --background-color: #061621;
  --second-background-color: #001e2b;
  --border-color: #3b4e56; /* Dark Charcoal */
  --second-border-color: #3d4f58; /* Dark Charcoal */
  --text-color: #b8c4b9; /* Beige */
  --second-text-color: #001e45; /* Beige */
}

* {
  margin: 0;
  padding: 0;
}

body {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Josefin Sans", sans-serif;
  font-optical-sizing: auto;
  /* position: relative; */
  font-style: normal;
  overflow-y: scroll;
  overflow-x: hidden;
  background: var(--background-color);
}

.sections1 {
  height: auto;
}

.youtubeVideos {
  margin-top: 10vh;
  height: auto;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3vw;
  padding: 3vw;
}
.youtubeVideos h1 {
  color: white;
  text-align: center;
}
#medias {
  width: 90%;
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  color: #00ed64;

  align-items: center;
  justify-content: space-around;
  gap: 3vw;
}

#loading {
  height: 70vh;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Spinner Loader CSS */
#loadingbar {
  border: 0.5vh solid white; /* Light grey */
  border-top: 0.5vh solid var(--primary-color);
  border-radius: 50%;
  width: 5vh;
  height: 5vh;
  animation: spin 1s linear infinite;
}

/* Button styling */
#loadMoreBtn {
  display: block;
  margin: 20px auto;
  padding: 10px 20px;
  background-color: var(--primary-color);
  color: var(--second-text-color);
  border: none;
  cursor: pointer;
  position: relative; /* For the spinner positioning */
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 1vh;
  border-radius: 1vh;
  font-weight: 800;
}

#loadMoreBtn:hover {
  background-color: var(--secondary-color);
  color: var(--primary-color);
}

/* Spinner inside button */
.loadMoreBtnSpinner {
  border: 4px solid var(--text-color); /* Light grey */
  border-top: 4px solid var(--primary-color); /* Midnight green (Primary Color) */
  border-radius: 50%;
  width: 20px;
  height: 20px;
  animation: spin 1s linear infinite;
  /* position: absolute; */
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  display: none; /* Hidden by default */
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.videoItem {
  padding: 1vw;
  height: auto;
  overflow: hidden;
  width: 40vw;
  display: flex;
  flex-direction: column;
  gap: 1vw;
  border: 1px solid var(--border-color);
  background: var(--secondary-color);
  border-radius: 2vh;
}
.youtubeTitle {
  height: 5vw;
  width: 100%;
  font-size: 1.5vw;
  padding: 1vh;
  overflow: hidden;
  text-align: left;
}
.videoFarameBox {
  height: 25vw;
  width: 100%;
  border-radius: 3vw;
}

.videoFarameBox iframe {
  height: 100%;
  width: 99%;
  border: 1px solid var(--primary-color);
  border-radius: 0.5vw;
}
.youtubeVideoLink {
  color: red;
  text-decoration: none;
}

.discriptionBox {
  transition: 1s ease-in-out;
  border-top: 1px solid var(--border-color);
  padding: 1vh;
}
.YoutubeDescription {
  color: var(--text-color);
  font-size: 1vw;
  display: none;
  transition: 1s ease-in-out;
  border-radius: 1vh;
  background: var(--border-color);
  padding: 1vh;
}

@media (min-width: 100px) and (max-width: 700px) {
  .youtubeVideos {
    height: auto;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1vh;
    padding: 2vh;
  }
  .youtubeVideos h1 {
    color: white;
    text-align: center;
  }
  #medias {
    width: 90%;
    display: flex;
    flex-direction: column;
    flex-wrap: wrap;
    color: #00ed64;

    align-items: center;
    justify-content: space-around;
    gap: 3vw;
  }

  .videoItem {
    padding: 1vw;
    height: auto;
    overflow: hidden;
    width: 40vh;
    display: flex;
    flex-direction: column;
    gap: 1vh;

    padding: 2vh;
  }
  .youtubeTitle {
    height: auto;
    width: 100%;
    font-size: 2vh;

    overflow: hidden;
    text-align: left;
  }
  .videoFarameBox {
    height: 35vh;
    width: 100%;
    border-radius: 3vw;
  }

  .videoFarameBox iframe {
    height: 100%;
    width: 99%;
    /* border: 1px solid var(--primary-color); */
    border-radius: 0.5vw;
    border-radius: 1vh;
  }
}
.YoutubeDescription {
  color: var(--text-color);
  font-size: 2vh;
}
