(function(f,h){"function"===typeof define&&define.amd?define([],h):"object"===typeof exports?module.exports=h():f.FontFaceOnload=h()})(this,function(){var f={tolerance:2,delay:100,glyphs:"",success:function(){},error:function(){},timeout:5E3,weight:"400",style:"normal",window:window},h="display:block position:absolute top:-999px left:-999px font-size:48px width:auto height:auto line-height:normal margin:0 padding:0 font-variant:normal white-space:nowrap".split(" "),b=function(){this.fontFamily="";
this.appended=!1;this.parent=this.sansSerif=this.serif=void 0;this.options={}};b.prototype.getMeasurements=function(){return{sansSerif:{width:this.sansSerif.offsetWidth,height:this.sansSerif.offsetHeight},serif:{width:this.serif.offsetWidth,height:this.serif.offsetHeight}}};b.prototype.load=function(){function n(a){return h.concat(["font-weight:"+c.weight,"font-style:"+c.style]).concat("font-family:"+a).join(";")}function a(a,c,d){return Math.abs(a.width-c.offsetWidth)>d||Math.abs(a.height-c.offsetHeight)>
d}var e=new Date,d=this,b=d.serif,g=d.sansSerif,k=d.parent,f=d.appended,l,c=d.options,m=c.reference,q='<div style="%s" aria-hidden="true">AxmTYklsjo190QW</div>'.replace(/%s/,n("sans-serif")),r='<div style="%s" aria-hidden="true">AxmTYklsjo190QW</div>'.replace(/%s/,n("serif"));k||(k=d.parent=c.window.document.createElement("div"));k.innerHTML=q+r;g=d.sansSerif=k.firstChild;b=d.serif=g.nextSibling;c.glyphs&&(g.innerHTML+=c.glyphs,b.innerHTML+=c.glyphs);(function p(){m||(m=c.window.document.body);!f&&
m&&(m.appendChild(k),f=d.appended=!0,l=d.getMeasurements(),g.style.fontFamily=d.fontFamily+", sans-serif",b.style.fontFamily=d.fontFamily+", serif");f&&l&&(a(l.sansSerif,g,c.tolerance)||a(l.serif,b,c.tolerance))?c.success():(new Date).getTime()-e.getTime()>c.timeout?c.error():!f&&"requestAnimationFrame"in c.window?c.window.requestAnimationFrame(p):c.window.setTimeout(p,c.delay)})()};b.prototype.cleanFamilyName=function(b){return b.replace(/['"]/g,"").toLowerCase()};b.prototype.cleanWeight=function(b){return""+
({normal:"400",bold:"700"}[b]||b)};b.prototype.checkFontFaces=function(b){var a=this;a.options.window.document.fonts.forEach(function(e){a.cleanFamilyName(e.family)===a.cleanFamilyName(a.fontFamily)&&a.cleanWeight(e.weight)===a.cleanWeight(a.options.weight)&&e.style===a.options.style&&e.load().then(function(){a.options.success(e);a.options.window.clearTimeout(b)})})};b.prototype.init=function(b,a){var e,d;for(d in f)a.hasOwnProperty(d)||(a[d]=f[d]);this.options=a;this.fontFamily=b;!a.glyphs&&"fonts"in
a.window.document?(a.timeout&&(e=a.window.setTimeout(function(){a.error()},a.timeout)),this.checkFontFaces(e)):this.load()};return function(f,a){var e=new b;e.init(f,a);return e}});FontFaceOnload("mar-fy-reg",{success:function(){document.documentElement.className+="j-customFontLoaded"}});