.modal-container * {
  margin: 0;
  padding: 0;
}

.project-modal {
  display: none;
  position: fixed;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  z-index: 6;
}

.modal-bg {
  position: fixed;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgb(0, 0, 0);
  opacity: 0.6;
  z-index: 7;
}

.modal-container {
  box-sizing: border-box;

  top: 6%;
  left: 28.5%;

  max-width: 650px;
  position: fixed;
  z-index: 8;

  border-radius: 10px;
  box-sizing: border-box;
  animation: modal-hello 0.5s ease-out;
  transition: transform 0.5s ease;
}

@keyframes modal-hello {
  0% {
    transform: scale(0.6);
    opacity: 0;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

.modal-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  width: 100%;
  background-color: #131416;
  padding: 1em;
  border-radius: 10px;
  box-sizing: border-box;
}

.modal-header {
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: flex-end;
  align-items: center;
  width: 100%;
  position: relative;
}

.modal-header .modal-img {
  height: 100%;
  width: 100%;
  object-fit: cover;
  max-width: 650px;
  max-height: 325px;
  object-position: bottom;
}

.modal-header .previous-img,
.modal-header .next-img {
  position: absolute;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 3em;
  height: 3em;
  max-width: 3em;
  color: #00adff;
  bottom: 0;
  right: 0;
  transition: 1s ease;
  overflow: hidden;
}

.modal-header span{
  position: relative;
  color: #00adff;
  transition: 1s ease;
  font-weight: 600;
  font-size: 3em;
}

.modal-header .previous-img {
  left: 0;
}

.modal-header .previous-img:hover,
.modal-header .next-img:hover {
  background-color: #f5f3f425;
}

.modal-header .previous-img:hover svg {
  animation: arrow-move 0.8s ease-in-out alternate-reverse;
}
.modal-header .next-img:hover svg {
  animation: arrow-move 0.8s ease-in-out;
}

@keyframes arrow-move {
  0%,
  100% {
    opacity: 1;
    transform: translateX(0) scaleX(1);
  }
  30% {
    opacity: 0;
    transform: translateX(200%) scaleX(2);
    filter: blur(0.5px);
  }
  31% {
    opacity: 0;
    transform: translateX(200%);
  }
  32% {
    opacity: 0;
    transform: translateX(-200%);
  }
  60% {
    opacity: 1;
    transform: translateX(60%) scaleX(1);
    filter: blur(0.5px);
  }
  75% {
    opacity: 1;
    transform: translateX(60%) scaleX(1);
    filter: blur(0.5px);
  }
  90% {
    opacity: 1;
    transform: translateX(0) scaleX(1);
  }
}

.modal-content .break-line {
  width: 100%;
  height: 2px;
  min-height: 2px;
  background-color: #00adff;
  margin-top: 1em;
  margin-bottom: 0.7em;
}

.modal-body {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-content: space-around;
  align-items: flex-start;
  height: 100%;
  gap: 1em;
}

.modal-body .modal-title {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.8em;
}

.modal-content h3 {
  font-size: 2em;
  font-weight: 600;
}

.modal-content h4 {
  font-size: 1em;
  font-weight: 500;
}

.modal-content p {
  font-size: 1em;
  font-weight: 300;
  margin: 0;
  text-align: justify;
}

.modal-content a {
  color: #f5f3f4;
  text-decoration: none;
  font-weight: 600;
}

.modal-content a:hover {
  opacity: 0.5;
}

.modal-footer {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  width: 100%;
  margin-top: 1em;
}

.modal-footer a {
  display: flex;
  justify-content: space-between;
  gap: 0.5em;
  padding: 0.8em 1em;
  background-color: #00adff;
  color: #101113;
  transition: 0.5s ease-in-out;
}

.modal-footer a:hover,
.modal-footer a:focus,
.modal-footer a:active {
  opacity: 0.8;
}

.modal-footer a:hover svg,
.modal-footer a:focus svg,
.modal-footer a:active svg {
  opacity: 0.8;
  animation: visit-project 0.6s ease-in 1;
}

@keyframes visit-project {
  0%,
  100% {
    opacity: 1;
    transform: rotate(0deg);
  }
  30% {
    transform: rotate(60deg);
  }
  50% {
    transform: rotate(45deg);
  }
  60% {
    transform: rotate(-45deg);
  }
  75% {
    transform: rotate(0deg);
  }
  90% {
    transform: rotate(-15deg);
  }
}

.modal-close {
  display: flex;
  flex-direction: column;
  justify-content: center;
  cursor: pointer;
  width: 1.4em;
  height: 1.4em;
  position: relative;
  opacity: 0.5
}

.modal-close .close-line {
  display: inline-block;
  position: absolute;
  height: 2px;
  min-height: 2px;
  border-radius: 10px;
  background-color: #f5f3f4;
  width: 80%;
  transform: rotate(45deg);
  transition: 0.5s ease-in-out;
}

.modal-close .close-line:nth-of-type(2) {
  transform: rotate(-45deg);
}

.modal-close:hover,
.modal-close:focus {
  opacity: 1;
}

.modal-close:hover .close-line,
.modal-close:focus .close-line {
  transform: rotate(-45deg);
}

.modal-close:hover .close-line:nth-of-type(2),
.modal-close:focus .close-line:nth-of-type(2) {
  transform: rotate(45deg);
}

@media (max-width: 1250px) {
  .modal-container {
    width: 60%;
    left: 20%;
  }
}

@media (max-width: 1025px) {
  .modal-container {   
    width: 70%;
    left: 15%;
  }

  .modal-content h3 {
    font-size: 1.8em;
    font-weight: 600;
  }
  
  .modal-content h4 {
    font-size: 0.9em;
    font-weight: 500;
  }
  
  .modal-content p {
    font-size: 0.8em;
    line-height: 1.7em;
    font-weight: 400;
  }
  
  .modal-content a {
    font-weight: 600;
  }
}

@media (max-width: 700px) {
  .modal-container {
    top: 10%;
    height: 80%;
    width: 80%;
    left: 10%;
  }
}

@media (max-width: 500px) {
  .modal-container {
    
    width: 90%;
    left: 5%;
  }
}