/* Overlay */
.smp-overlay {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: none; /* viene mostrato via JS */
}

/* Modale */
.smp-modal {
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: calc(100% - 32px);
  max-height: calc(100vh - 32px);
  z-index: 100001;
  display: none; /* viene mostrato via JS */
  border-radius: 14px;
  box-shadow: 0 18px 55px rgba(0,0,0,.35);
  background-color: #ffffff;
  background-repeat: no-repeat;
  background-position: center;
  background-size: cover;
  overflow-y: auto;
}

/* Blocca lo scroll sotto */
body.smp-modal-open {
  overflow: hidden;
}

/* X in alto a destra — sticky so it stays visible when modal scrolls */
.smp-close-x {
  position: sticky;
  top: 10px;
  z-index: 1;
  display: block;
  width: 38px;
  height: 38px;
  margin: 10px 12px 0 auto;
  border-radius: 999px;
  border: 0;
  cursor: pointer;
  font-size: 24px;
  line-height: 1;
  background: rgba(255,255,255,.85);
  box-shadow: 0 6px 18px rgba(0,0,0,.18);
}

.smp-close-x:focus {
  outline: 2px solid rgba(0,0,0,.35);
  outline-offset: 2px;
}

/* Card contenuti */
.smp-card {
  margin: 8px 18px 18px 18px;
  background: transparent;
  border-radius: 12px;
  padding: 18px 18px 14px 18px;
}

.smp-title {
  margin: 0 0 10px 0;
  font-size: 24px;
  line-height: 1.2;
}

.smp-content {
  font-size: 16px;
  line-height: 1.45;
}

.smp-content p:last-child {
  margin-bottom: 0;
}

.smp-actions {
  margin-top: 14px;
  display: flex;
  justify-content: center;
}

.smp-close-btn {
  border: 0;
  cursor: pointer;
  padding: 10px 14px;
  border-radius: 10px;
  background: #111;
  color: #fff;
  font-weight: 600;
}

.smp-close-btn:hover {
  opacity: .92;
}

@media (max-width: 480px) {
  .smp-card {
    margin: 6px 14px 14px 14px;
    padding: 16px 14px 12px 14px;
  }
  .smp-title {
    font-size: 20px;
  }
}
