.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, visibility 0.3s;
}

.modal-overlay.visible {
  opacity: 1;
  visibility: visible;
}

.modal-content {
  background: #fff;
  padding: var(--space-6);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  width: 90%;
  max-width: 550px; /* Aumentata leggermente la larghezza massima */
  text-align: center;
  transform: scale(0.95);
  transition: transform 0.3s;
}

.modal-overlay.visible .modal-content {
  transform: scale(1);
}

.modal-title {
  margin: 0 0 var(--space-2) 0;
  font-size: var(--h2);
  color: var(--unipi-blue);
}

.modal-body {
  margin-bottom: var(--space-4);
  line-height: 1.6;
}

/* ✅ NUOVE REGOLE PER LA MODALE PRIVACY */
.privacy-content {
  max-height: 40vh; /* Altezza massima del box di testo */
  overflow-y: auto; /* Abilita lo scroll verticale */
  border: 1px solid #e2e8f0;
  padding: var(--space-4);
  text-align: left;
  line-height: 1.6;
  margin-top: var(--space-4);
  border-radius: var(--radius);
  background: #f8fafc;
}

#privacy-accept-btn:disabled {
  background: #ccc;
  border-color: #ccc;
  cursor: not-allowed;
}