/* ── Enkanta Booking Form ──────────────────────────────────────────────────── */

.ekb-wrap {
  max-width: 460px;
  margin: 0 auto;
  font-family: inherit;
}

/* ── Pasos ───────────────────────────────────────────────────────────────── */

.ekb-step {
  animation: ekbFadeIn 0.25s ease;
}

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

/* ── Tipografía ──────────────────────────────────────────────────────────── */

.ekb-title {
  font-size: 1.35rem;
  font-weight: 700;
  margin: 0 0 6px;
  color: #1a1a1a;
}

.ekb-subtitle {
  font-size: 0.95rem;
  color: #555;
  margin: 0 0 24px;
}

/* ── Campos ──────────────────────────────────────────────────────────────── */

.ekb-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 18px;
}

.ekb-field label {
  font-size: 0.875rem;
  font-weight: 600;
  color: #222;
}

.ekb-req {
  color: #e53e3e;
  margin-left: 2px;
}

.ekb-optional {
  font-weight: 400;
  color: #888;
  font-size: 0.8rem;
  margin-left: 4px;
}

.ekb-field input {
  width: 100%;
  padding: 11px 14px;
  border: 1.5px solid #d1d5db;
  border-radius: 8px;
  font-size: 1rem;
  color: #1a1a1a;
  background: #fff;
  transition: border-color 0.15s;
  box-sizing: border-box;
}

.ekb-field input:focus {
  outline: none;
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

/* ── Teléfono con prefijo ────────────────────────────────────────────────── */

.ekb-phone-row {
  display: flex;
  align-items: center;
  border: 1.5px solid #d1d5db;
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
  transition: border-color 0.15s;
}

.ekb-phone-row:focus-within {
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.ekb-prefix {
  padding: 11px 12px;
  background: #f3f4f6;
  font-size: 0.95rem;
  font-weight: 600;
  color: #374151;
  border-right: 1.5px solid #d1d5db;
  white-space: nowrap;
}

.ekb-phone-row input {
  border: none !important;
  box-shadow: none !important;
  border-radius: 0 !important;
  flex: 1;
  min-width: 0;
}

/* ── Hints ───────────────────────────────────────────────────────────────── */

.ekb-hint {
  font-size: 0.8rem;
  color: #6b7280;
}

.ekb-hint-rescue {
  color: #92400e;
}

/* ── Errores ─────────────────────────────────────────────────────────────── */

.ekb-error {
  font-size: 0.875rem;
  color: #dc2626;
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: 6px;
  padding: 10px 14px;
  margin-bottom: 14px;
}

/* ── Botón principal ─────────────────────────────────────────────────────── */

.ekb-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 13px 20px;
  background: #2563eb;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, opacity 0.15s;
}

.ekb-btn:hover:not(:disabled) {
  background: #1d4ed8;
}

.ekb-btn:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

/* ── Links secundarios ───────────────────────────────────────────────────── */

.ekb-links {
  display: flex;
  justify-content: space-between;
  margin-top: 16px;
  flex-wrap: wrap;
  gap: 8px;
}

.ekb-link {
  background: none;
  border: none;
  color: #2563eb;
  font-size: 0.875rem;
  cursor: pointer;
  padding: 4px 0;
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: color 0.15s;
}

.ekb-link:hover:not(:disabled) {
  color: #1d4ed8;
}

.ekb-link:disabled {
  color: #9ca3af;
  cursor: not-allowed;
  text-decoration: none;
}

/* ── Spinner ─────────────────────────────────────────────────────────────── */

/*
 * IMPORTANTE: el spinner está oculto por defecto (display: none).
 * Se muestra sólo cuando tiene la clase .is-active.
 * No usamos el atributo HTML `hidden` porque cualquier regla CSS
 * con display:inline-block/block lo sobreescribe (el UA stylesheet
 * no usa !important). Usando .is-active evitamos ese conflicto.
 */
.ekb-spinner {
  display: none;
  width: 16px;
  height: 16px;
  border: 2.5px solid rgba(255, 255, 255, 0.4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: ekbSpin 0.7s linear infinite;
  flex-shrink: 0;
}

.ekb-spinner.is-active {
  display: inline-block;
}

.ekb-spinner-lg {
  width: 32px;
  height: 32px;
  border-width: 3px;
  border-color: rgba(37, 99, 235, 0.2);
  border-top-color: #2563eb;
}

.ekb-spinner-lg.is-active {
  display: block;
  margin: 20px auto 12px;
}

@keyframes ekbSpin {
  to { transform: rotate(360deg); }
}

/* ── Paso de redirección ─────────────────────────────────────────────────── */

.ekb-step-redirect {
  text-align: center;
  padding: 32px 0;
}

/* ── Responsive ──────────────────────────────────────────────────────────── */

@media (max-width: 480px) {
  .ekb-title {
    font-size: 1.15rem;
  }

  .ekb-links {
    flex-direction: column;
    align-items: flex-start;
  }
}
