/* ============================================
   MODAL FORM — Palmira Club
   ============================================ */

.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(45, 49, 66, 0.55);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.modal-overlay.open {
  opacity: 1;
  pointer-events: all;
}

.modal {
  background: #fff;
  border-radius: 18px;
  padding: 2.5rem;
  width: 100%;
  max-width: 480px;
  position: relative;
  transform: translateY(24px) scale(0.98);
  transition: transform 0.3s ease;
  box-shadow: 0 24px 64px rgba(0,0,0,0.15);
}

.modal-overlay.open .modal {
  transform: translateY(0) scale(1);
}

.modal__close {
  position: absolute;
  top: 1.2rem;
  right: 1.2rem;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #f0f7fa;
  border: none;
  cursor: pointer;
  font-size: 1.1rem;
  color: #8a8fa8;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, color 0.2s;
}
.modal__close:hover {
  background: #f27d2b;
  color: #fff;
}

.modal__icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: #fff3ea;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  margin-bottom: 1.2rem;
}

.modal__title {
  font-size: 1.5rem;
  font-weight: 800;
  color: #2d3142;
  margin-bottom: 0.4rem;
  line-height: 1.2;
}

.modal__sub {
  font-size: 0.9rem;
  color: #8a8fa8;
  margin-bottom: 1.8rem;
  line-height: 1.55;
}

.modal__form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.modal__field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.modal__label {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #8a8fa8;
}

.modal__input,
.modal__textarea {
  padding: 0.85rem 1.1rem;
  font-family: 'Nunito', sans-serif;
  font-size: 0.95rem;
  color: #2d3142;
  background: #f0f7fa;
  border: 1.5px solid #d8edf5;
  border-radius: 10px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
  width: 100%;
}

.modal__input:focus,
.modal__textarea:focus {
  border-color: #3aaed8;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(58,174,216,0.12);
}

.modal__input.error,
.modal__textarea.error {
  border-color: #e53935;
}

.modal__textarea {
  resize: vertical;
  min-height: 90px;
}

.modal__error {
  font-size: 0.75rem;
  color: #e53935;
  display: none;
}
.modal__error.visible { display: block; }

.modal__submit {
  margin-top: 0.5rem;
}

.modal__privacy {
  font-size: 0.73rem;
  color: #8a8fa8;
  text-align: center;
  line-height: 1.5;
  margin-top: 0.3rem;
}

.modal__success {
  display: none;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 1rem 0;
  gap: 0.8rem;
}

.modal__success.visible { display: flex; }

.modal__success-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: #e8f8ef;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
}

.modal__success h3 {
  font-size: 1.25rem;
  font-weight: 800;
  color: #2d3142;
}

.modal__success p {
  font-size: 0.9rem;
  color: #8a8fa8;
  line-height: 1.55;
}

.modal__sending {
  opacity: 0.6;
  pointer-events: none;
}

@media (max-width: 480px) {
  .modal {
    padding: 2rem 1.5rem;
    border-radius: 14px;
  }
}
