/* Formulario global de WhatsApp. Conserva la paleta del tema y la tipografía Work Sans. */
.tmd-whatsapp-dialog,
.tmd-whatsapp-dialog * {
  box-sizing: border-box;
}

.tmd-whatsapp-dialog {
  position: fixed;
  inset: 0;
  width: min(460px, calc(100% - 32px));
  max-width: 460px;
  max-height: calc(100dvh - 32px);
  margin: auto;
  padding: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  border: 0;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 24px 70px rgba(20, 30, 57, .36);
  color: #262e4f;
  color-scheme: light;
  font-family: 'Work Sans', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

.tmd-whatsapp-dialog:not([open]) {
  display: none;
}

.tmd-whatsapp-dialog::backdrop {
  background: rgba(19, 29, 57, .76);
}

body.tmd-whatsapp-dialog-open {
  overflow: hidden;
}

.tmd-whatsapp-dialog__content {
  position: relative;
  padding: 32px 30px 28px;
}

.tmd-whatsapp-dialog__close {
  position: absolute;
  top: 14px;
  right: 14px;
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #262e4f;
  cursor: pointer;
}

.tmd-whatsapp-dialog__close > i {
  font-size: 22px;
}

.tmd-whatsapp-dialog__close:hover {
  background: #eef2f9;
}

.tmd-whatsapp-dialog__title {
  margin: 0 28px 10px;
  color: #244f98;
  font-size: clamp(22px, 3vw, 25px);
  font-weight: 700;
  letter-spacing: -.02em;
  line-height: 1.2;
  text-align: center;
}

.tmd-whatsapp-dialog__description {
  margin: 0 0 24px;
  color: #485570;
  font-size: 15px;
  line-height: 1.55;
  text-align: center;
}

.tmd-whatsapp-dialog__form {
  display: grid;
  gap: 16px;
  margin: 0;
}

.tmd-whatsapp-dialog__field {
  display: grid;
  gap: 7px;
  margin: 0;
}

.tmd-whatsapp-dialog__field > span {
  color: #263d70;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.35;
}

.tmd-whatsapp-dialog__field em {
  color: #58647e;
  font-size: 12px;
  font-style: normal;
  font-weight: 400;
}

.tmd-whatsapp-dialog__field input,
.tmd-whatsapp-dialog__field select {
  display: block;
  width: 100%;
  min-width: 0;
  min-height: 47px;
  margin: 0;
  padding: 11px 13px;
  border: 1px solid #a6b5d2;
  border-radius: 8px;
  outline: 0;
  background: #fff;
  box-shadow: none;
  color: #262e4f;
  font: inherit;
  font-size: 16px;
  line-height: 1.35;
}

.tmd-whatsapp-dialog__field input::placeholder {
  color: #69758b;
  opacity: 1;
}

.tmd-whatsapp-dialog__field select {
  padding-right: 34px;
  cursor: pointer;
}

.tmd-whatsapp-dialog__field input:focus-visible,
.tmd-whatsapp-dialog__field select:focus-visible,
.tmd-whatsapp-dialog__close:focus-visible,
.tmd-whatsapp-dialog__submit:focus-visible,
.tmd-whatsapp-dialog__consent a:focus-visible {
  outline: 3px solid #128ceb;
  outline-offset: 2px;
}

.tmd-whatsapp-dialog__consent {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 2px 0 0;
  color: #364361;
  font-size: 13px;
  line-height: 1.5;
  cursor: pointer;
}

.tmd-whatsapp-dialog__consent input {
  width: 18px;
  min-width: 18px;
  height: 18px;
  margin: 2px 0 0;
  accent-color: #156dbb;
  cursor: pointer;
}

.tmd-whatsapp-dialog__consent a {
  color: #155ba4;
  font-weight: 600;
  text-underline-offset: 3px;
}

.tmd-whatsapp-dialog__submit {
  display: flex;
  min-height: 50px;
  align-items: center;
  justify-content: center;
  margin-top: 3px;
  padding: 12px 16px;
  border: 0;
  border-radius: 9px;
  background: #ffc33c;
  color: #262e4f;
  font: inherit;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.3;
  cursor: pointer;
  transition: background-color .18s ease;
}

.tmd-whatsapp-dialog__submit:hover {
  background: #ffcf61;
}

@media (max-width: 480px) {
  .tmd-whatsapp-dialog {
    width: calc(100% - 24px);
    max-height: calc(100dvh - 24px);
  }

  .tmd-whatsapp-dialog__content {
    padding: 30px 20px 24px;
  }

  .tmd-whatsapp-dialog__description {
    margin-bottom: 18px;
  }

  .tmd-whatsapp-dialog__form {
    gap: 13px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .tmd-whatsapp-dialog__submit {
    transition: none;
  }
}
