/* ==========================================================
   NUBO_MOVEMENT_AI_MOBILE_REFINE_V1_START
   Refinamiento mobile del bloque Nubo IA en modal de movimientos
   ========================================================== */

@media (max-width: 768px) {

  /* Card IA */
  .ai-helper,
  .nubo-movement-form-v2 .ai-helper,
  #movement-form .ai-helper {
    margin: 0 0 14px 0 !important;
    padding: 12px !important;
    border-radius: 18px !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
  }

  /* Título superior del bloque */
  .ai-helper > strong,
  .ai-helper > .label,
  .ai-helper .field-label,
  .ai-helper .section-label {
    display: block !important;
    margin-bottom: 8px !important;
    font-size: 0.9rem !important;
    line-height: 1.2 !important;
  }

  /* Intento de apilar automáticamente el input + botón */
  .ai-helper > div,
  .ai-helper .ai-helper__row,
  .ai-helper .ai-inline,
  .ai-helper .inline,
  .ai-helper .row {
    gap: 10px !important;
  }

  /* Si el contenedor usa flex */
  .ai-helper > div:not(:last-child),
  .ai-helper .ai-helper__row,
  .ai-helper .ai-inline,
  .ai-helper .inline,
  .ai-helper .row {
    flex-wrap: wrap !important;
  }

  /* Input */
  .ai-helper input[type="text"],
  .ai-helper input:not([type]),
  .ai-helper textarea {
    width: 100% !important;
    min-width: 0 !important;
    min-height: 48px !important;
    font-size: 0.98rem !important;
    line-height: 1.35 !important;
    border-radius: 14px !important;
    padding: 13px 14px !important;
    box-sizing: border-box !important;
  }

  /* Botón Interpretar */
  .ai-helper button,
  .ai-helper .btn,
  .ai-helper [role="button"] {
    width: auto !important;
    min-width: 160px !important;
    max-width: 220px !important;
    min-height: 46px !important;
    padding: 0 16px !important;
    border-radius: 14px !important;
    font-size: 0.96rem !important;
    font-weight: 700 !important;
    align-self: center !important;
    margin: 0 auto !important;
    box-sizing: border-box !important;
    white-space: nowrap !important;
  }

  /* Si el botón tenía full width heredado */
  .ai-helper button.btn--block,
  .ai-helper .btn--block {
    width: auto !important;
    display: inline-flex !important;
  }

  /* Ícono dentro del botón */
  .ai-helper button svg,
  .ai-helper .btn svg {
    width: 18px !important;
    height: 18px !important;
    flex: 0 0 18px !important;
  }

  /* Texto de ayuda inferior */
  .ai-helper small,
  .ai-helper .help,
  .ai-helper .helper-text,
  .ai-helper p {
    font-size: 0.75rem !important;
    line-height: 1.35 !important;
    margin-top: 10px !important;
    margin-bottom: 0 !important;
    opacity: 0.88 !important;
  }

  /* Separación para que no se vea apretado */
  .nubo-movement-form-v2 .ai-helper + .field,
  #movement-form .ai-helper + .field {
    margin-top: 10px !important;
  }
}

/* Desktop: solo un pequeño refinamiento visual */
@media (min-width: 769px) {
  .ai-helper,
  .nubo-movement-form-v2 .ai-helper,
  #movement-form .ai-helper {
    border-radius: 20px !important;
  }
}

/* ==========================================================
   NUBO_MOVEMENT_AI_MOBILE_REFINE_V1_END
   ========================================================== */
