:root {
  --h1: 2.25rem;
}
.z-2 {
  z-index: 2;
}
section {
  padding: 5%;
}
hr {
  border: none;
  height: 1px;
  background-color: var(--text-color);
  opacity: 0.1;
  margin: 3rem auto;
  width: 60%;
}
.hero {
  min-height: 100vh;
  padding: 18% 0 0 0;
  width: 100%;
  position: relative;
  background-color: var(--primary-color);
  background-image: url(../images/uploads/home-hero.webp);
  background-size: cover;
  background-repeat: no-repeat;
  background-position: bottom;
  justify-content: flex-end;
  margin-bottom: 3rem;
}
.hero .overlay {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to top, var(--primary-color), transparent);
  opacity: 0.8;
  z-index: -1;
}
.hero .info {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  margin-bottom: 2rem;
}
.hero h1 {
  width: 65%;
  font-size: var(--h1);
  text-align: center;
}
.hero p {
  color: white;
  background-color: rgba(147, 18, 114, 0.6);
  padding: 15px;
  border-radius: 30px;
  font-size: 0.95rem;
}
.hero .btn-primary {
  background-color: var(--secondary-color);
}
.about {
  padding: 0 5%;
  justify-content: space-between;
  align-items: flex-start;
}
.about .info {
  width: 45%;
}
.about p {
  margin-bottom: 1rem;
  line-height: 1.7rem;
}
.about .images {
  position: relative;
  width: 55%;
  margin-left: 2rem;
  padding: 2% 0;
}
.about .images .image-container {
  width: 50%;
  height: 24rem;
  border-radius: 25px;
}
.about .images .image-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.about .images .img-2 {
  position: absolute;
  width: calc(50% + 30px);
  border: 15px solid #fff;
  top: 30%;
  right: 7%;
}

.team {
  position: relative;
  /* height: 50vh; */
  /* margin-bottom: calc(50vh + 3rem); */
  text-align: center;
  /* background-color: var(--primary-color); */
}
.team::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 50vh;
  background: var(--primary-color);
  pointer-events: none;
  z-index: 1;
}
.team * {
  z-index: 2;
}
.team h2 {
  position: relative;
  margin-bottom: 2rem;
  color: #fff;
  z-index: 4;
}
.team .team-members {
  flex-wrap: wrap;
  justify-content: center;
  align-items: stretch;
  gap: 1rem;
}
.team .team-members .card {
  width: 270px;
  padding: 2%;
  flex-direction: column;
  align-items: center;
  justify-content: space-evenly;
  box-shadow: var(--shadow-y);
  border-radius: var(--radius);
  overflow: hidden;
  background-color: #fff;
  text-align: center;
}
.team .team-members .card hr {
  width: 50%;
  border: 1px solid var(--text-color);
  opacity: 0.2;
  margin: 0.5rem 0;
}
.team .team-members .card .image-container {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  overflow: hidden;
  margin-bottom: 1rem;
}
.team .team-members .card h5 {
  color: var(--secondary-color);
  font-size: 0.85rem;
}
.team .bio-modal {
  position: absolute;
  width: 80%;
  left: 50%;
  top: 7rem;
  opacity: 0;
  transform: translateX(-50%);
  box-shadow: var(--shadow-y);
  border-radius: var(--radius);
  background-color: var(--background-color);
  overflow: hidden;
  z-index: 99;
  pointer-events: none;
  transition: opacity 300ms ease, top 300ms ease;
}
.team .bio-modal.show {
  top: calc(20% + 10vh);
  opacity: 1;
  pointer-events: all;
}
.team .bio-modal .overlay {
  position: absolute;
  background: url("../images/uploads/horizontal-pattern-white.png");
  background-repeat: no-repeat;
  background-size: cover;
  opacity: 0.05;
  width: 100%;
  height: 100%;
}
.team .bio-modal .header {
  position: relative;
  width: 100%;
  padding: 5%;
  background-color: var(--primary-color);
  color: white;
}
.team .bio-modal .header .fa-xmark {
  position: absolute;
  right: 1rem;
  top: 2rem;
  font-size: 1.2rem;
  cursor: pointer;
  z-index: 3;
}
.team .bio-modal .header .member-info {
  align-items: flex-start;
  justify-content: flex-start;
  gap: 1rem;
  text-align: left;
  margin-top: 2rem;
  margin-bottom: -2rem;
}
.team .bio-modal .header .member-info .image-container {
  width: 200px;
  height: 200px;
  border: 8px solid var(--background-color);
  border-radius: 50%;
  margin-bottom: -7rem;
}
.team .bio-modal .header .member-info .member {
  padding-top: 2rem;
  margin-left: 1rem;
  z-index: 3;
}
.team .bio-modal .header .member-info .member p {
  color: var(--secondary-color);
  margin-bottom: 1.2rem;
}
.team .bio-modal .header .member-info .member .fa-brands {
  font-size: 1.5rem;
  color: white;
  transition: color 300ms ease;
}
.team .bio-modal .header .member-info .member .fa-brands:hover {
  color: var(--secondary-color);
}
.team .bio-modal .modal-body {
  padding: 5%;
  padding-top: calc(5% + 1rem);
}
.team .bio-modal .modal-body p {
  line-height: 1.8rem;
  text-align: left;
}

.partners {
  text-align: center;
}
.partners h2 {
  margin-bottom: 2rem;
}
.partners .partner-logos {
  justify-content: center;
  align-items: center;
  gap: 3rem;
}
.partners .partner-logos .image-container {
  width: 20%;
}
.partners .partner-logos .jse-logo {
  width: 11%;
}
.partners .partner-logos .image-container img {
  filter: grayscale(1);
  opacity: 0.7;
  transition: filter 0.3s ease, opacity 0.3s ease;
}
.partners .partner-logos .image-container img:hover {
  filter: grayscale(0);
  opacity: 1;
}

.projects {
  position: relative;
  text-align: center;
  color: #fff;
  padding-top: 3%;
}
.projects::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 80vh;
  background: var(--primary-color);
  pointer-events: none;
  z-index: 1;
}
.projects * {
  z-index: 2;
}
.projects h2 {
  position: relative;
  margin-bottom: 2rem;
}
.projects p {
  position: relative;
  margin: 0 auto 1rem auto;
  width: 60%;
  line-height: 1.7rem;
}
.projects > p:last-child {
  margin-bottom: 5rem;
}

.cs-work {
  justify-content: center;
  align-items: stretch;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-top: 3rem;
}
.cs-work .work-card {
  width: 350px;
  /* flex: 1 1 350px; */
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  box-shadow: var(--shadow-y);
  border-radius: var(--radius);
  overflow: hidden;
  background-color: #fff;
  color: var(--text-color);
  text-align: center;
}
.cs-work .work-card .image-container {
  width: 100%;
  height: 200px;
  margin-bottom: 1rem;
}
.cs-work .work-card h4 {
  margin-bottom: 0.5rem;
  color: var(--primary-color);
  text-align: left;
  padding: 0 1rem;
}
.cs-work .work-card p {
  line-height: 1.6rem;
  text-align: left;
  width: 100%;
  padding: 0 1rem;
}

.events h2 {
  margin-bottom: 2rem;
  text-align: center;
}
.events .upcoming {
  margin-bottom: 3rem;
}
.events .events-list {
  align-items: stretch;
  flex-wrap: wrap;
  gap: 1rem;
}
.events .event-card {
  width: 100%;
  max-width: 400px;
  padding: 1rem;
  flex-direction: column;
  align-items: flex-start;
  justify-content: space-between;
  box-shadow: var(--shadow-y);
  border-radius: var(--radius);
  background-color: #fff;
  color: var(--text-color);
}
.events .event-card .image-container {
  width: 100%;
  border-radius: var(--radius);
}
.events .event-card .image-container img {
  height: 100%;
}
.events .event-card p {
  line-height: 1.6rem;
}
.events .event-card .date {
  column-gap: 2rem;
}
.events .event-card .date .flex {
  justify-content: flex-start;
  column-gap: 0.5rem;
}
.events .event-card .date p {
  margin-bottom: 0;
}
.events .event-card .date .fa-solid {
  color: var(--secondary-color);
}
.events .event-card .cta {
  gap: 1rem;
  width: 100%;
  justify-content: space-between;
}
.events .event-card .btn {
  width: 100%;
}
.events .events-list.past-events .event-card {
  max-width: 370px;
}
.events .past {
  position: relative;
}
.events .lightbox-popup {
  position: absolute;
  display: none;
  width: 100%;
  height: auto;
  padding: 5% 2% 2%;
  border-radius: var(--radius);
  background-color: var(--primary-color);
  box-shadow: var(--shadow-y);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  /* z-index: 100; */
}
.events .lightbox-popup.show {
  display: block;
}
.events .lightbox-popup .fa-solid {
  position: absolute;
  color: white;
  top: 1rem;
  right: 1rem;
  font-size: 1.5rem;
  padding: 5px;
  cursor: pointer;
}
.events .lightbox-popup .fa-solid:hover {
  background-color: rgba(27, 27, 27, 0.185);
  border-radius: 7px;
}
.events .gallery {
  width: 100%;
  height: 100%;
  padding: 1%;
  margin: 0 auto;
  backdrop-filter: blur(5px);
  border-radius: 20px;
  background-color: var(--background-color);
}
.events .main-image-container {
  position: relative;
  width: 100%;
  max-height: 60vh;
  border-radius: 20px;
  overflow: hidden;
}
.events .full-image .nav-icons {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  padding: 5px 7px;
  background-color: rgba(27, 27, 27, 0.185);
  transition: background-color 300ms ease;
}
.events .full-image .nav-icons.left {
  left: 1rem;
}
.events .full-image .nav-icons.right {
  width: fit-content;
  right: 1rem;
}
.events .full-image .fa-solid:hover {
  border-radius: 0;
  background-color: var(--secondary-color);
}
.events .main-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* object-position: top; */
}
.events .thumbnails {
  height: 22vh;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
  gap: 0.5rem;
  margin-top: 0.5rem;
}
.events .thumbnails button {
  height: inherit;
  overflow: hidden;
  border-radius: 15px;
}
.events .thumb-image {
  height: 100%;
  width: 100%;
  object-fit: cover;
  border-radius: 10px;
  filter: grayscale(1);
  cursor: pointer;
  transition: filter 300ms ease, scale 300ms ease;
}
.events .thumb-image:hover {
  scale: 1.05;
  filter: grayscale(0);
}
.events .image-container.full-image {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 90%;
  max-height: 90vh;
  z-index: 150;
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background-color: rgba(0, 0, 0, 0.8);
  padding: 1rem;
  border-radius: 15px;
}
.events .image-container.full-image.show {
  display: flex;
}
.events .image-container.full-image img {
  width: 100%;
  max-height: 80vh;
  object-fit: contain;
  border-radius: 10px;
}
.events .image-container.full-image .controls {
  width: 80%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: white;
  margin-top: 1rem;
}
.events .image-container.full-image .controls .fa-solid {
  position: relative;
  top: 0;
  right: 0;
  color: white;
  font-size: 1.5rem;
  cursor: pointer;
}

.events .event-modal {
  position: absolute;
  width: 80%;
  left: 50%;
  top: 7rem;
  opacity: 0;
  transform: translateX(-50%);
  box-shadow: var(--shadow-y);
  border-radius: var(--radius);
  background-color: var(--background-color);
  overflow: hidden;
  z-index: 99;
  pointer-events: none;
  transition: opacity 300ms ease, top 300ms ease;
}
.events .event-modal.show {
  top: 0;
  opacity: 1;
  pointer-events: all;
}
.events .event-modal .overlay {
  position: absolute;
  background: url("../images/uploads/horizontal-pattern-white.png");
  background-repeat: no-repeat;
  background-size: cover;
  opacity: 0.03;
  width: 100%;
  height: 100%;
}
.events .event-modal .header {
  position: relative;
  width: 100%;
  padding: 5%;
  background-color: var(--primary-color);
  color: white;
  text-align: center;
}
.events .event-modal .header .fa-xmark {
  position: absolute;
  right: 1rem;
  top: 1rem;
  font-size: 1.2rem;
  cursor: pointer;
  z-index: 3;
}
.events .event-modal .modal-body {
  padding: 3%;
}
.events .event-modal .modal-body .left {
  width: 50%;
}
.events .event-modal .modal-body form fieldset {
  padding: 3%;
  border-radius: 10px;
  border-color: var(--text-color);
}
.events .event-modal .modal-body form legend {
  font-weight: bold;
  padding: 0 0.5rem;
}
.events form .input {
  width: 100%;
  border-radius: 7px;
  border: 2px solid var(--text-color);
  position: relative;
  padding: 0.5rem;
  padding-left: 0.5rem;
  margin-bottom: 1rem;
}
.events form .input input {
  border: none;
  outline: none;
  font-family: inherit;
  width: 75%;
  height: 100%;
}
.events form .input .error {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  right: 0.5rem;
  color: red;
  font-size: 0.75rem;
}
.events form .checks {
  margin: 1rem 0;
  flex-direction: column;
  justify-content: space-around;
  align-items: flex-start;
}
.events form .checks:nth-child(1) {
  margin: 0;
}
.events .right {
  width: 50%;
}
.events .right .image-container {
  width: 100%;
}

.pagination {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 1.5rem;
}
.pagination .page-link {
  display: inline-block;
  padding: 0.5rem 1rem;
  border: 1px solid var(--primary-color);
  border-radius: 5px;
  color: var(--primary-color);
  text-decoration: none;
  transition: all 0.2s;
}
.pagination .page-link:hover {
  background: var(--primary-color);
  color: white;
}
.pagination .page-link.active {
  background: var(--primary-color);
  color: white;
  pointer-events: none;
}

.media {
  padding: 5% 0;
  background-color: var(--primary-color);
}
.media h2 {
  text-align: center;
  margin-bottom: 2rem;
  color: #fff;
}
.media .media-cards {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: stretch;
  gap: 1.5rem;
}
.media .media-card {
  width: 400px;
  flex-direction: column;
  align-items: flex-start;
  justify-content: space-between;
  box-shadow: var(--shadow-y);
  border-radius: var(--radius);
  overflow: hidden;
  background-color: #fff;
  color: var(--text-color);
}
.media .media-card .image-container {
  width: 100%;
  height: 200px;
}
.media .media-card .content {
  padding: 5%;
}
.media .media-card h4,
.media .media-card h5 {
  margin-bottom: 0.5rem;
}
.media .media-card h4 {
  color: var(--primary-color);
}
.media .media-card p {
  line-height: 1.6rem;
  width: 100%;
  margin-bottom: 1rem;
}
.media .media-card a {
  position: relative;
  color: var(--text-color);
  width: 100%;
  padding-left: 0;
  transition: padding-left 0.3s ease, color 0.3s ease;
}
.media .media-card a::after {
  content: "";
  position: absolute;
  width: 0;
  height: 2px;
  margin-left: 5px;
  background-color: var(--secondary-color);
  left: 0;
  bottom: -3px;
  transform-origin: left;
  transition: width 0.3s ease;
}
.media .media-card a:hover {
  padding-left: 5px;
  color: var(--secondary-color);
}
.media .media-card a:hover::after {
  width: 80%;
}

.resources h2 {
  text-align: center;
  margin-bottom: 3rem;
}

@media screen and (max-width: 1200px) {
  .hero h1 {
    width: 75%;
  }
}

@media screen and (max-width: 768px) {
  hr {
    margin: 1rem auto;
  }
  .hero h1 {
    width: 90%;
  }
  .about {
    flex-direction: column;
    margin-bottom: 10rem;
  }
  .about .info {
    width: 100%;
  }
  .about .images {
    width: 100%;
    margin-left: 0;
  }
  .projects p {
    width: 90%;
  }
  .cs-work .work-card {
    width: 300px;
  }
  .events .upcoming,
  .events .past {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
  }
  .events .events-list {
    align-items: center;
    justify-content: center;
  }
}

@media screen and (max-width: 550px) {
  :root {
    --h1: 1.5rem;
  }
  .hero h1 {
    font-size: var(--h1);
    margin-top: 0.5rem;
  }
  .about .info {
    text-align: center;
  }
  .about .images .image-container {
    width: 60%;
  }
  .about .images .img-2 {
    right: 0;
  }
  .team .team-members .card {
    width: 80%;
    padding: 5%;
    margin-bottom: 1rem;
  }
  .team .bio-modal .header .member-info {
    flex-direction: column;
    align-items: center;
    text-align: center;
    margin-bottom: 0;
  }
  .team .bio-modal .header .member-info .member {
    padding-top: 0;
    margin-left: 0;
    margin-top: 7rem;
  }
  .team .bio-modal .header .member-info .member h3,
  .team .bio-modal .header .member-info .member p {
    margin-bottom: 0.5rem;
  }
  .partners h2 {
    margin-bottom: 0;
  }
  .partners .partner-logos .image-container {
    width: 40%;
  }
  .partners .partner-logos .jse-logo {
    width: 20%;
  }
  .projects::after {
    height: 90vh;
  }
  .cs-work .work-card {
    width: 80%;
  }
  .cs-work .work-card h4,
  .cs-work .work-card p {
    padding: 0 5%;
  }
  .events .event-modal .modal-body {
    flex-direction: column;
    gap: 2rem;
  }
  .events .right,
  .events .event-modal .modal-body .left {
    width: 100%;
    padding: 3%;
  }
  .events .event-modal .header h3 {
    padding-top: 5%;
  }
  .events form {
    width: 100%;
  }
  .events .right .image-container {
    border-radius: 20px;
    overflow: hidden;
  }
  .events .thumbnails {
    height: 18vh;
    grid-template-columns: repeat(auto-fill, minmax(75px, 1fr));
  }
  .events .lightbox-popup {
    top: 35%;
    height: auto;
    padding: 12% 2% 2%;
  }
  .events .image-container.full-image {
    width: 100%;
  }
}
