* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

@font-face {
  font-family: "Italianno", cursive;
  src: url("https://fonts.googleapis.com/css2?family=Italianno&display=swap");
}

@font-face {
  font-family: "Poppins", sans-serif;
  src: url("https://fonts.googleapis.com/css2?family=Poppins:ital,wght@1,100&display=swap");
}

body {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  background-image: url("./image.jpg");
  background-repeat: no-repeat;
  background-attachment: fixed;
}

container {
  width: 1000px;
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
}

.container .heading h1 {
  text-align: center;
  justify-content: center;
  align-items: center;
  padding: 20px;
  font-family: "Poppins", sans-serif;
  font-style: italic;
  font-weight: bold;
  letter-spacing: 1px;
  font-size: 3em;
  color: black;
}

.container .card {
  position: relative;
  width: auto;
  height: auto;
  background: #04678c;
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 30px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
  overflow: hidden;
}

.container:hover .card {
  opacity: 0.5;
}

.container .card:hover {
  opacity: 1;
}

.container .card::before {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  bottom: 2px;
  background: rgba(255, 255, 255, 0.1);
  pointer-events: none;
}

.container .card .content {
  padding: 30px;
  text-align: center;
  justify-content: center;
}

.container .card .content h2 {
  position: absolute;
  right: 3px;
  font-size: 3em;
  font-weight: 90%;
  color: black;
  z-index: 1;
  opacity: 0.1;
  transition: 0.5s;
}

.container .card:hover .content h2 {
  opacity: 1;
  transform: translateY(-30px);
}

.container .card .content a {
  display: inline-block;
  margin-top: 15px;
  padding: 8px 15px;
  color: black;
  letter-spacing: 1px;
  font-size: 1.5em;
  text-align: center;
  justify-content: center;
  font-family: "Italianno", cursive;
  font-weight: bold;
  text-decoration: none;
}

.container .card span {
  transition: 0.5;
  opacity: 0%;
}

.container .card:hover span {
  opacity: 1;
}

.container .card span:nth-child(1) {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: linear-gradient(to right, transparent, black);
  animation: animate1 2s linear infinite;
}

@keyframes animate1 {
  0% {
    transform: translateX(-100%);
  }
  100% {
    transform: translateX(100%);
  }
}

.container .card span:nth-child(2) {
  position: absolute;
  top: 0;
  right: 0;
  width: 3px;
  height: 100%;
  background: linear-gradient(to bottom, transparent, black);
  animation: animate2 2s linear infinite;
}

@keyframes animate2 {
  0% {
    transform: translateY(-100%);
  }
  100% {
    transform: translateY(100%);
  }
}

.container .card span:nth-child(3) {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: linear-gradient(to left, transparent, black);
  animation: animate3 2s linear infinite;
}

@keyframes animate3 {
  0% {
    transform: translateX(100%);
  }
  100% {
    transform: translateX(-100%);
  }
}

.container .card span:nth-child(4) {
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 100%;
  background: linear-gradient(to top, transparent, black);
  animation: animate4 2s linear infinite;
}

@keyframes animate4 {
  0% {
    transform: translateY(-100%);
  }
  100% {
    transform: translateY(100%);
  }
}
