/*────────────────── 
     Modal
──────────────────*/

.modal {
  display: none; /* Hidden by default */
  position: fixed; /* Stay in place */
  z-index: 1; /* Sit on top */
  left: 0;
  top: 0;
  width: 100%; /* Full width */
  height: 90%; /* Full height */
  overflow: auto; /* Enable scroll if needed */
  background-color: rgba(0,0,0,0.4); /* Black w/ opacity */
  padding-top: 60px;
}

/* Modal Content/Box */
.modal-content {
  background-color: var(--main-header-background);
  margin: 15% auto; /* 15% from the top and centered */
  padding: 20px;
  border: 1px solid var(--main-decor-color);
  width: 80%; /* Could be more or less, depending on screen size */
  height: 75%; /* Could be more or less, depending on screen size */
  color: var(--main-fonts-color);
  font-family: var(--main-font-family);
  border-radius: 12px;
}

/* The Close Button */
.close-button {
  color: #aaaaaa;
  float: right;
  padding-right: 17px;
  font-size: 35px;
  font-weight: bold;
}

/* The Close Button */
.close {
  color: var(--main-fonts-color);
  float: right;
  font-size: 28px;
  font-weight: bold;
}

.close:hover,
.close:focus {
  color: var(--main-decor-color);
  text-decoration: none;
  cursor: pointer;
}

/* Nowa reguła @keyframes */
@keyframes openModalAnimation {
  0% {
    transform: scale(0.05, 0.05); /* Początkowy stan modalu */
  }
  50% {
    transform: scale(1, 0); /* Modal rozszerza się na pełną szerokość, ale jest nadal płaski */
  }
  100% {
    transform: scale(1, 1); /* Modal osiąga pełną wysokość */
  }
}

/* Dodaj animację do modala, gdy jest wyświetlany */
.modal[style*="block"] .modal-content {
  animation: openModalAnimation 0.5s ease-in-out; /* Tutaj możesz dostosować czas i sposób animacji */
}
