(function(e){"use strict";function i(e,t){var n=false,r=true,i=e.document,s=i.documentElement,o=i.addEventListener?"addEventListener":"attachEvent",u=i.addEventListener?"removeEventListener":"detachEvent",a=i.addEventListener?"":"on",f=function(r){if(r.type=="readystatechange"&&i.readyState!="complete")return;(r.type=="load"?e:i)[u](a+r.type,f,false);if(!n&&(n=true))t.call(e,r.type||r)},l=function(){try{s.doScroll("left")}catch(e){setTimeout(l,50);return}f("poll")};if(i.readyState=="complete")t.call(e,"lazy");else{if(i.createEventObject&&s.doScroll){try{r=!e.frameElement}catch(c){}if(r)l()}i[o](a+"DOMContentLoaded",f,false);i[o](a+"readystatechange",f,false);e[o](a+"load",f,false)}}var t=e,n=t.document;var r="cbinstance";var s={get:function(e){return decodeURIComponent(n.cookie.replace(new RegExp("(?:(?:^|.*;)\\s*"+encodeURIComponent(e).replace(/[\-\.\+\*]/g,"\\$&")+"\\s*\\=\\s*([^;]*).*$)|^.*$"),"$1"))||null},set:function(e,t,r,i,s,o){if(!e||/^(?:expires|max\-age|path|domain|secure)$/i.test(e)){return false}var u="";if(r){switch(r.constructor){case Number:u=r===Infinity?"; expires=Fri, 31 Dec 9999 23:59:59 GMT":"; max-age="+r;break;case String:u="; expires="+r;break;case Date:u="; expires="+r.toUTCString();break}}n.cookie=encodeURIComponent(e)+"="+encodeURIComponent(t)+u+(s?"; domain="+s:"")+(i?"; path="+i:"")+(o?"; secure":"");return true},has:function(e){return(new RegExp("(?:^|;\\s*)"+encodeURIComponent(e).replace(/[\-\.\+\*]/g,"\\$&")+"\\s*\\=")).test(n.cookie)},remove:function(e,t,r){if(!e||!this.has(e)){return false}n.cookie=encodeURIComponent(e)+"=; expires=Thu, 01 Jan 1970 00:00:00 GMT"+(r?"; domain="+r:"")+(t?"; path="+t:"");return true}};var o={merge:function(){var e={},t=0,n=arguments.length,r;if(0===n){return e}for(;t';var s=n.createElement("div");s.innerHTML=i;e=s.firstChild}return e},agree:function(){this.cookiejar.set(this.options.cookie,1,this.options.expires,this.options["cookie-path"]);return true},agreed:function(){return this.cookiejar.has(this.options.cookie)},close:function(){if(this.inserted){if(!this.closed){if(this.element){n.body.removeChild(this.element)}if(this.element_mask){n.body.removeChild(this.element_mask)}this.closed=true}}return this.closed},agree_and_close:function(){this.agree();return this.close()},cleanup:function(){this.close();return this.unload()},unload:function(){if(this.script_el){this.script_el.parentNode.removeChild(this.script_el)}e[r]=undefined;return true},insert:function(){function s(e,t,n){var r=e.addEventListener?"addEventListener":"attachEvent",i=e.addEventListener?"":"on";e[r](i+t,n,false)}this.element_mask=this.build_viewport_mask();var e=this.options.zindex;if(this.element_mask){e+=1}var t=n.createElement("div");t.className="cookiebanner";t.style.position="fixed";t.style.left=0;t.style.right=0;t.style.height=this.options.height;t.style.minHeight=this.options["min-height"];t.style.zIndex=e;t.style.background=this.options.bg;t.style.color=this.options.fg;t.style.lineHeight=t.style.minHeight;t.style.padding="5px 16px";t.style.fontFamily="arial, sans-serif";t.style.fontSize="14px";if("top"===this.options.position){t.style.top=0}else{t.style.bottom=0}t.innerHTML='
'+""+this.options.message+" "+this.options.linkmsg+"";this.element=t;var r=t.getElementsByTagName("a")[0];r.href=this.options.moreinfo;r.target="_blank";r.style.textDecoration="none";r.style.color=this.options.link;var i=t.getElementsByTagName("div")[0];i.style.cursor="pointer";var u=this;s(i,"click",function(){u.agree_and_close()});if(this.element_mask){s(this.element_mask,"click",function(){u.agree_and_close()});n.body.appendChild(this.element_mask)}n.body.appendChild(this.element);this.inserted=true;if("fade"===this.options.effect){this.element.style.opacity=0;o.fade_in(this.element)}else{this.element.style.opacity=1}}};e[r]=new u})(window)