/* Modal Styles */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.85);
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
  backdrop-filter: blur(5px);
  overflow-y: auto;
  padding: 20px;
  box-sizing: border-box;
}

.modal-overlay.active {
  display: flex;
  opacity: 1;
}

.modal-container {
  position: relative;
  width: 100%;
  max-width: 500px;
  margin: auto;
}

.modal-content {
  background: #fff;
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
  position: relative;
  animation: modalFadeIn 0.4s ease-out;
}

.modal-close {
  position: absolute;
  top: -15px;
  right: -15px;
  width: 40px;
  height: 40px;
  background: #fff;
  border-radius: 50%;
  border: none;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  font-size: 1.5rem;
  font-weight: bold;
  color: #333;
  cursor: pointer;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  padding: 0;
}

.modal-close:hover {
  transform: scale(1.1);
  background: #f0f0f0;
}

@keyframes modalFadeIn {
  from {
    transform: translateY(20px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .modal-overlay {
    padding: 15px;
    align-items: flex-start;
  }

  .modal-content {
    padding: 1.5rem;
    margin-top: 20px;
  }

  .modal-close {
    width: 35px;
    height: 35px;
    top: -12px;
    right: -12px;
    font-size: 1.3rem;
  }
}

@media (max-width: 480px) {
  .modal-content {
    padding: 1.2rem;
  }

  .modal-close {
    width: 30px;
    height: 30px;
    top: -10px;
    right: -10px;
    font-size: 1.1rem;
  }
}
