(function initFivaRuntimeConfig(global) {
  "use strict";

  if (global.FIVA?.RuntimeConfig) {
    if (typeof module !== "undefined" && module.exports) module.exports = global.FIVA.RuntimeConfig;
    return;
  }

  const RuntimeConfig = Object.freeze({
    dropdownWaitMs: 8000,
    ajaxWaitMs: 8000,
    retryCount: 2,
    dropdownRetryCount: 3,
    stabilizationDelayMinMs: 800,
    stabilizationDelayMaxMs: 1500,
    typingDelayMinMs: 30,
    typingDelayMaxMs: 80,
    domSettleMs: 320,
    verificationTimeoutMs: 2000,
    asyncDependencyTimeoutMs: 8000,
    globalAutofillTimeoutMs: 90000,
    fieldTimeoutMs: 8000,
    dropdownQuietMs: 500,
    fastActionDelayMs: 120
  });

  global.FIVA = Object.assign(global.FIVA || {}, { RuntimeConfig });

  if (typeof module !== "undefined" && module.exports) {
    module.exports = RuntimeConfig;
  }
})(typeof globalThis !== "undefined" ? globalThis : this);
