').hide().insertBefore($target);
$events.one(event_purge, function (){
$inline.replaceWith($target);
});
prep($target);
}else if(settings.get('iframe')){
prep(" ");
}else if(settings.get('html')){
prep(settings.get('html'));
}else if(isImage(settings, href)){
href=retinaUrl(settings, href);
photo=settings.get('createImg');
$(photo)
.addClass(prefix + 'Photo')
.bind('error.' + prefix, function (){
prep($tag(div, 'Error').html(settings.get('imgError')));
})
.one('load', function (){
if(request!==requests){
return;
}
setTimeout(function (){
var percent;
if(settings.get('retinaImage')&&window.devicePixelRatio > 1){
photo.height=photo.height / window.devicePixelRatio;
photo.width=photo.width / window.devicePixelRatio;
}
if(settings.get('scalePhotos')){
setResize=function (){
photo.height -=photo.height * percent;
photo.width -=photo.width * percent;
};
if(settings.mw&&photo.width > settings.mw){
percent=(photo.width - settings.mw) / photo.width;
setResize();
}
if(settings.mh&&photo.height > settings.mh){
percent=(photo.height - settings.mh) / photo.height;
setResize();
}}
if(settings.h){
photo.style.marginTop=Math.max(settings.mh - photo.height, 0) / 2 + 'px';
}
if($related[1]&&(settings.get('loop')||$related[index + 1])){
photo.style.cursor='pointer';
$(photo).bind('click.' + prefix, function (){
publicMethod.next();
});
}
photo.style.width=photo.width + 'px';
photo.style.height=photo.height + 'px';
prep(photo);
}, 1);
});
photo.src=href;
}else if(href){
$loadingBay.load(href, settings.get('data'), function (data, status){
if(request===requests){
prep(status==='error' ? $tag(div, 'Error').html(settings.get('xhrError')):$(this).contents());
}});
}}
publicMethod.next=function (){
if(!active&&$related[1]&&(settings.get('loop')||$related[index + 1])){
index=getIndex(1);
launch($related[index]);
}};
publicMethod.prev=function (){
if(!active&&$related[1]&&(settings.get('loop')||index)){
index=getIndex(-1);
launch($related[index]);
}};
publicMethod.close=function (){
if(open&&!closing){
closing=true;
open=false;
trigger(event_cleanup);
settings.get('onCleanup');
$window.unbind('.' + prefix);
$overlay.fadeTo(settings.get('fadeOut')||0, 0);
$box.stop().fadeTo(settings.get('fadeOut')||0, 0, function (){
$box.hide();
$overlay.hide();
trigger(event_purge);
$loaded.remove();
setTimeout(function (){
closing=false;
trigger(event_closed);
settings.get('onClosed');
}, 1);
});
}};
publicMethod.remove=function (){
if(!$box){
return;
}
$box.stop();
$[colorbox].close();
$box.stop(false, true).remove();
$overlay.remove();
closing=false;
$box=null;
$('.' + boxElement)
.removeData(colorbox)
.removeClass(boxElement);
$(document).unbind('click.' + prefix).unbind('keydown.' + prefix);
};
publicMethod.element=function (){
return $(settings.el);
};
publicMethod.settings=defaults;
}(jQuery, document, window));
SGPopup.prototype.canOpenOnce=function(id){
if(typeof jQuery.cookie('sgPopupDetails'+id)=="undefined"){
return true;
}
var cookieData=JSON.parse(jQuery.cookie('sgPopupDetails'+id));
if(cookieData.popupId==id&&cookieData.openCounter >=this.numberLimit){
return false;
}else{
return true
}}
SGPopup.prototype.cantPopupClose=function(){
this.popupEscKey=false;
this.popupCloseButton=false;
this.popupOverlayClose=false;
this.popupContentClick=false;
}
SGPopup.prototype.forMobile=function(){
if(/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)){
return true;
}
return false;
}
SGPopup.inactivityIdicator=0;
SGPopup.prototype.showPopupAfterInactivity=function(popupId){
var data=SG_POPUP_DATA[popupId];
var that=this;
var inactivityTimout=data['inactivity-timout']+"000";
var idleInterval=setInterval(function(){that.timerIncrement(popupId, idleInterval)}, inactivityTimout);
jQuery(window).mousemove(function (e){
SGPopup.inactivityIdicator++;
});
jQuery(window).keypress(function (e){
SGPopup.inactivityIdicator++;
});
}
SGPopup.prototype.timerIncrement=function(popupId , idleInterval){
var lastActivity=SGPopup.inactivityIdicator;
if(lastActivity==0){
clearInterval(idleInterval);
this.showPopup(popupId, true);
}
SGPopup.inactivityIdicator=0;
}
SGPopup.prototype.onScrolling=function(popupId){
that=this;
var scrollStatus=false;
jQuery(window).on('scroll', function(){
var scrollTop=jQuery(window).scrollTop();
var docHeight=jQuery(document).height();
var winHeight=jQuery(window).height();
var scrollPercent=(scrollTop) / (docHeight - winHeight);
var scrollPercentRounded=Math.round(scrollPercent*100);
if(beforeScrolingPrsent < scrollPercentRounded){
if(scrollStatus==false){
that.showPopup(popupId,true);
scrollStatus=true;
}}
});
}
SGPopup.prototype.removeCookie=function(openOnce){
if(openOnce===false){
}}
SGPopup.prototype.proInit=function(){
var that=this;
jQuery('#sgcolorbox').on('sgColorboxOnCompleate',function(e){
if(arguments[1]=='on'){
jQuery('#sgcboxLoadedContent').css({'position': 'relative'});
}
that.isPushToBottom();
});
}
SGPopup.prototype.disablePopupOverlay=function(){
jQuery('#sgcolorbox').on("sgColorboxOnOpen", function(){
jQuery("#sgcboxOverlay").remove();
});
}
SGPopup.prototype.autoClosePopup=function(){
jQuery.sgcolorbox.close();
}
SGPopup.prototype.isPushToBottom=function(){
var loadedContent=document.getElementById('sgcboxLoadedContent');
var loadConetnetHasScroll=loadedContent.scrollHeight>loadedContent.clientHeight;
if(jQuery(".js-sg-push-on-bottom").length!=0&&loadConetnetHasScroll){
jQuery(".js-sg-push-on-bottom").removeClass("sg-push-to-bottom");
}}
SGPopup.prototype.sgPopupShouldOpen=function(popupId){
if(typeof SG_POPUP_DATA[popupId]=="undefined"){
return false;
}
var openMobile=SG_POPUP_DATA[popupId]['openMobile'];
var hideForMobile=SG_POPUP_DATA[popupId]['forMobile'];
var popupThisOften=SG_POPUP_DATA[popupId]['repeatPopup'];
var popupType=SG_POPUP_DATA[popupId]['type'];
var popupNumberLimit=SG_POPUP_DATA[popupId]['popup-appear-number-limit']
var isMobile=this.forMobile();
if(isMobile==false&&openMobile){
return false;
}
if(isMobile==true&&hideForMobile){
return false;
}
if(popupThisOften){
this.numberLimit=popupNumberLimit;
var canOpen=this.canOpenOnce(popupId);
if(!canOpen){
return false;
}}
if(popupType=='exitIntent'){
return false;
}
return true;
}
SGPopup.prototype.popupOpenOnWindowLoad=function(popupId){
sgAddEvent(window, 'load', this.popupOpenById(popupId));
}
jQuery(document).ready(function($){
var popupObj=new SGPopup();
popupObj.proInit();
var that=this;
});
(function (factory){
if(typeof define==='function'&&define.amd){
define(['jquery'], factory);
}else{
factory(jQuery);
}}(function ($){
var pluses=/\+/g;
function encode(s){
return config.raw ? s:encodeURIComponent(s);
}
function decode(s){
return config.raw ? s:decodeURIComponent(s);
}
function stringifyCookieValue(value){
return encode(config.json ? JSON.stringify(value):String(value));
}
function parseCookieValue(s){
if(s.indexOf('"')===0){
s=s.slice(1, -1).replace(/\\"/g, '"').replace(/\\\\/g, '\\');
}
try {
s=decodeURIComponent(s.replace(pluses, ' '));
} catch(e){
return;
}
try {
return config.json ? JSON.parse(s):s;
} catch(e){}}
function read(s, converter){
var value=config.raw ? s:parseCookieValue(s);
return $.isFunction(converter) ? converter(value):value;
}
var config=$.cookie=function (key, value, options){
if(value!==undefined&&!$.isFunction(value)){
options=$.extend({}, config.defaults, options);
if(typeof options.expires==='number'){
var days=options.expires, t=options.expires=new Date();
t.setDate(t.getDate() + days);
}
return (document.cookie=[
encode(key), '=', stringifyCookieValue(value),
options.expires ? '; expires=' + options.expires.toUTCString():'',
options.path ? '; path=' + options.path:'',
options.domain ? '; domain=' + options.domain:'',
options.secure ? '; secure':''
].join(''));
}
var result=key ? undefined:{};
var cookies=document.cookie ? document.cookie.split('; '):[];
for (var i=0, l=cookies.length; i < l; i++){
var parts=cookies[i].split('=');
var name=decode(parts.shift());
var cookie=parts.join('=');
if(key&&key===name){
result=read(cookie, value);
break;
}
if(!key&&(cookie=read(cookie))!==undefined){
result[name]=cookie;
}}
return result;
};
config.defaults={};
$.removeCookie=function (key, options){
if($.cookie(key)!==undefined){
$.cookie(key, '', $.extend({}, options, { expires: -1 }));
return true;
}
return false;
};}));
function SGQueue(){
}
if(typeof SG_POPUPS_QUEUE=='undefined'){
SG_POPUPS_QUEUE=[];
}
SGQueue.queue=SG_POPUPS_QUEUE;
SGQueue.currentId='';
SGQueue.popupObj=new SGPopup();
SGQueue.queueObj=new SGQueue();
SGQueue.run=function(){
var popupObj=SGQueue.popupObj;
var queueObj=SGQueue.queueObj;
queueObj.bindingForNext();
var listOfQueue=SGQueue.queue;
if(typeof listOfQueue=="undefined"||listOfQueue.length==0){
return false;
}
SGQueue.currentId=listOfQueue[0];
var shouldOpen=SGQueue.popupObj.sgPopupShouldOpen(SGQueue.currentId);
if(!shouldOpen){
queueObj.next();
}else{
SGQueue.popupObj.popupOpenOnWindowLoad(SGQueue.currentId);
}}
SGQueue.prototype.next=function(){
SGQueue.queueObj.removeFromQueueByValue(SGQueue.queue, SGQueue.currentId);
SGQueue.currentId=SGQueue.queue[0];
if(typeof SGQueue.currentId=="undefined"){
return false;
}
var shouldOpen=SGQueue.popupObj.sgPopupShouldOpen(SGQueue.currentId);
if(!shouldOpen){
this.next();
}else{
SGQueue.popupObj.popupOpenOnWindowLoad(SGQueue.currentId);
}}
SGQueue.prototype.removeFromQueueByValue=function(arr, value){
var index=arr.indexOf(value);
arr.splice(index, 1);
return arr;
}
SGQueue.prototype.bindingForNext=function(){
var that=this;
jQuery('#sgcolorbox').bind("sgPopupClose", function(){
that.next();
});
}
jQuery(document).ready(function($){
SGQueue.run();
});
var Base=function(){
};
Base.extend=function(_instance, _static){
"use strict";
var extend=Base.prototype.extend;
Base._prototyping=true;
var proto=new this();
extend.call(proto, _instance);
proto.base=function(){
};
delete Base._prototyping;
var constructor=proto.constructor;
var klass=proto.constructor=function(){
if(!Base._prototyping){
if(this._constructing||this.constructor==klass){
this._constructing=true;
constructor.apply(this, arguments);
delete this._constructing;
}else if(arguments[0]!==null){
return (arguments[0].extend||extend).call(arguments[0], proto);
}}
};
klass.ancestor=this;
klass.extend=this.extend;
klass.forEach=this.forEach;
klass.implement=this.implement;
klass.prototype=proto;
klass.toString=this.toString;
klass.valueOf=function(type){
return (type=="object") ? klass:constructor.valueOf();
};
extend.call(klass, _static);
if(typeof klass.init=="function") klass.init();
return klass;
};
Base.prototype={
extend: function(source, value){
if(arguments.length > 1){
var ancestor=this[source];
if(ancestor&&(typeof value=="function") &&
(!ancestor.valueOf||ancestor.valueOf()!=value.valueOf()) &&
/\bbase\b/.test(value)){
var method=value.valueOf();
value=function(){
var previous=this.base||Base.prototype.base;
this.base=ancestor;
var returnValue=method.apply(this, arguments);
this.base=previous;
return returnValue;
};
value.valueOf=function(type){
return (type=="object") ? value:method;
};
value.toString=Base.toString;
}
this[source]=value;
}else if(source){
var extend=Base.prototype.extend;
if(!Base._prototyping&&typeof this!="function"){
extend=this.extend||extend;
}
var proto={toSource: null};
var hidden=["constructor", "toString", "valueOf"];
var i=Base._prototyping ? 0:1;
while (key=hidden[i++]){
if(source[key]!=proto[key]){
extend.call(this, key, source[key]);
}}
for (var key in source){
if(!proto[key]) extend.call(this, key, source[key]);
}}
return this;
}};
Base=Base.extend({
constructor: function(){
this.extend(arguments[0]);
}}, {
ancestor: Object,
version: "1.1",
forEach: function(object, block, context){
for (var key in object){
if(this.prototype[key]===undefined){
block.call(context, object[key], key, object);
}}
},
implement: function(){
for (var i=0; i < arguments.length; i++){
if(typeof arguments[i]=="function"){
arguments[i](this.prototype);
}else{
this.prototype.extend(arguments[i]);
}}
return this;
},
toString: function(){
return String(this.valueOf());
}});
var FlipClock;
(function($){
"use strict";
FlipClock=function(obj, digit, options){
if(digit instanceof Object&&digit instanceof Date===false){
options=digit;
digit=0;
}
return new FlipClock.Factory(obj, digit, options);
};
FlipClock.Lang={};
FlipClock.Base=Base.extend({
buildDate: '2014-12-12',
version: '0.7.7',
constructor: function(_default, options){
if(typeof _default!=="object"){
_default={};}
if(typeof options!=="object"){
options={};}
this.setOptions($.extend(true, {}, _default, options));
},
callback: function(method){
if(typeof method==="function"){
var args=[];
for(var x=1; x <=arguments.length; x++){
if(arguments[x]){
args.push(arguments[x]);
}}
method.apply(this, args);
}},
log: function(str){
if(window.console&&console.log){
console.log(str);
}},
getOption: function(index){
if(this[index]){
return this[index];
}
return false;
},
getOptions: function(){
return this;
},
setOption: function(index, value){
this[index]=value;
},
setOptions: function(options){
for(var key in options){
if(typeof options[key]!=="undefined"){
this.setOption(key, options[key]);
}}
}});
}(jQuery));
(function($){
"use strict";
FlipClock.Face=FlipClock.Base.extend({
autoStart: true,
dividers: [],
factory: false,
lists: [],
constructor: function(factory, options){
this.dividers=[];
this.lists=[];
this.base(options);
this.factory=factory;
},
build: function(){
if(this.autoStart){
this.start();
}},
createDivider: function(label, css, excludeDots){
if(typeof css=="boolean"||!css){
excludeDots=css;
css=label;
}
var dots=[
'
',
'
'
].join('');
if(excludeDots){
dots='';
}
label=this.factory.localize(label);
var html=[
'
',
''+(label ? label:'')+'',
dots,
''
];
var $html=$(html.join(''));
this.dividers.push($html);
return $html;
},
createList: function(digit, options){
if(typeof digit==="object"){
options=digit;
digit=0;
}
var obj=new FlipClock.List(this.factory, digit, options);
this.lists.push(obj);
return obj;
},
reset: function(){
this.factory.time=new FlipClock.Time(this.factory,
this.factory.original ? Math.round(this.factory.original):0,
{
minimumDigits: this.factory.minimumDigits
}
);
this.flip(this.factory.original, false);
},
appendDigitToClock: function(obj){
obj.$el.append(false);
},
addDigit: function(digit){
var obj=this.createList(digit, {
classes: {
active: this.factory.classes.active,
before: this.factory.classes.before,
flip: this.factory.classes.flip
}});
this.appendDigitToClock(obj);
},
start: function(){},
stop: function(){},
autoIncrement: function(){
if(!this.factory.countdown){
this.increment();
}else{
this.decrement();
}},
increment: function(){
this.factory.time.addSecond();
},
decrement: function(){
if(this.factory.time.getTimeSeconds()==0){
this.factory.stop()
}else{
this.factory.time.subSecond();
}},
flip: function(time, doNotAddPlayClass){
var t=this;
$.each(time, function(i, digit){
var list=t.lists[i];
if(list){
if(!doNotAddPlayClass&&digit!=list.digit){
list.play();
}
list.select(digit);
}else{
t.addDigit(digit);
}});
}});
}(jQuery));
(function($){
"use strict";
FlipClock.Factory=FlipClock.Base.extend({
animationRate: 1000,
autoStart: true,
callbacks: {
destroy: false,
create: false,
init: false,
interval: false,
start: false,
stop: false,
reset: false
},
classes: {
active: 'flip-clock-active',
before: 'flip-clock-before',
divider: 'flip-clock-divider',
dot: 'flip-clock-dot',
label: 'flip-clock-label',
flip: 'flip',
play: 'play',
wrapper: 'flip-clock-wrapper'
},
clockFace: 'HourlyCounter',
countdown: false,
defaultClockFace: 'HourlyCounter',
defaultLanguage: 'english',
$el: false,
face: true,
lang: false,
language: 'english',
minimumDigits: 0,
original: false,
running: false,
time: false,
timer: false,
$wrapper: false,
constructor: function(obj, digit, options){
if(!options){
options={};}
this.lists=[];
this.running=false;
this.base(options);
this.$el=$(obj).addClass(this.classes.wrapper);
this.$wrapper=this.$el;
this.original=(digit instanceof Date) ? digit:(digit ? Math.round(digit):0);
this.time=new FlipClock.Time(this, this.original, {
minimumDigits: this.minimumDigits,
animationRate: this.animationRate
});
this.timer=new FlipClock.Timer(this, options);
this.loadLanguage(this.language);
this.loadClockFace(this.clockFace, options);
if(this.autoStart){
this.start();
}},
loadClockFace: function(name, options){
var face, suffix='Face', hasStopped=false;
name=name.ucfirst()+suffix;
if(this.face.stop){
this.stop();
hasStopped=true;
}
this.$el.html('');
this.time.minimumDigits=this.minimumDigits;
if(FlipClock[name]){
face=new FlipClock[name](this, options);
}else{
face=new FlipClock[this.defaultClockFace+suffix](this, options);
}
face.build();
this.face=face
if(hasStopped){
this.start();
}
return this.face;
},
loadLanguage: function(name){
var lang;
if(FlipClock.Lang[name.ucfirst()]){
lang=FlipClock.Lang[name.ucfirst()];
}
else if(FlipClock.Lang[name]){
lang=FlipClock.Lang[name];
}else{
lang=FlipClock.Lang[this.defaultLanguage];
}
return this.lang=lang;
},
localize: function(index, obj){
var lang=this.lang;
if(!index){
return null;
}
var lindex=index.toLowerCase();
if(typeof obj=="object"){
lang=obj;
}
if(lang&&lang[lindex]){
return lang[lindex];
}
return index;
},
start: function(callback){
var t=this;
if(!t.running&&(!t.countdown||t.countdown&&t.time.time > 0)){
t.face.start(t.time);
t.timer.start(function(){
t.flip();
if(typeof callback==="function"){
callback();
}});
}else{
t.log('Trying to start timer when countdown already at 0');
}},
stop: function(callback){
this.face.stop();
this.timer.stop(callback);
for(var x in this.lists){
if(this.lists.hasOwnProperty(x)){
this.lists[x].stop();
}}
},
reset: function(callback){
this.timer.reset(callback);
this.face.reset();
},
setTime: function(time){
this.time.time=time;
this.flip(true);
},
getTime: function(time){
return this.time;
},
setCountdown: function(value){
var running=this.running;
this.countdown=value ? true:false;
if(running){
this.stop();
this.start();
}},
flip: function(doNotAddPlayClass){
this.face.flip(false, doNotAddPlayClass);
}});
}(jQuery));
(function($){
"use strict";
FlipClock.List=FlipClock.Base.extend({
digit: 0,
classes: {
active: 'flip-clock-active',
before: 'flip-clock-before',
flip: 'flip'
},
factory: false,
$el: false,
$obj: false,
items: [],
lastDigit: 0,
constructor: function(factory, digit, options){
this.factory=factory;
this.digit=digit;
this.lastDigit=digit;
this.$el=this.createList();
this.$obj=this.$el;
if(digit > 0){
this.select(digit);
}
this.factory.$el.append(this.$el);
},
select: function(digit){
if(typeof digit==="undefined"){
digit=this.digit;
}else{
this.digit=digit;
}
if(this.digit!=this.lastDigit){
var $delete=this.$el.find('.'+this.classes.before).removeClass(this.classes.before);
this.$el.find('.'+this.classes.active).removeClass(this.classes.active)
.addClass(this.classes.before);
this.appendListItem(this.classes.active, this.digit);
$delete.remove();
this.lastDigit=this.digit;
}},
play: function(){
this.$el.addClass(this.factory.classes.play);
},
stop: function(){
var t=this;
setTimeout(function(){
t.$el.removeClass(t.factory.classes.play);
}, this.factory.timer.interval);
},
createListItem: function(css, value){
return [
'
',
'',
'',
'
',
'
'+(value ? value:'')+'
',
'
',
'',
'
',
'
'+(value ? value:'')+'
',
'
',
'',
''
].join('');
},
appendListItem: function(css, value){
var html=this.createListItem(css, value);
this.$el.append(html);
},
createList: function(){
var lastDigit=this.getPrevDigit() ? this.getPrevDigit():this.digit;
var html=$([
'
',
this.createListItem(this.classes.before, lastDigit),
this.createListItem(this.classes.active, this.digit),
'
'
].join(''));
return html;
},
getNextDigit: function(){
return this.digit==9 ? 0:this.digit + 1;
},
getPrevDigit: function(){
return this.digit==0 ? 9:this.digit - 1;
}});
}(jQuery));
(function($){
"use strict";
String.prototype.ucfirst=function(){
return this.substr(0, 1).toUpperCase() + this.substr(1);
};
$.fn.FlipClock=function(digit, options){
return new FlipClock($(this), digit, options);
};
$.fn.flipClock=function(digit, options){
return $.fn.FlipClock(digit, options);
};}(jQuery));
(function($){
"use strict";
FlipClock.Time=FlipClock.Base.extend({
time: 0,
factory: false,
minimumDigits: 0,
constructor: function(factory, time, options){
if(typeof options!="object"){
options={};}
if(!options.minimumDigits){
options.minimumDigits=factory.minimumDigits;
}
this.base(options);
this.factory=factory;
if(time){
this.time=time;
}},
convertDigitsToArray: function(str){
var data=[];
str=str.toString();
for(var x=0;x < str.length; x++){
if(str[x].match(/^\d*$/g)){
data.push(str[x]);
}}
return data;
},
digit: function(i){
var timeStr=this.toString();
var length=timeStr.length;
if(timeStr[length - i]){
return timeStr[length - i];
}
return false;
},
digitize: function(obj){
var data=[];
$.each(obj, function(i, value){
value=value.toString();
if(value.length==1){
value='0'+value;
}
for(var x=0; x < value.length; x++){
data.push(value.charAt(x));
}});
if(data.length > this.minimumDigits){
this.minimumDigits=data.length;
}
if(this.minimumDigits > data.length){
for(var x=data.length; x < this.minimumDigits; x++){
data.unshift('0');
}}
return data;
},
getDateObject: function(){
if(this.time instanceof Date){
return this.time;
}
return new Date((new Date()).getTime() + this.getTimeSeconds() * 1000);
},
getDayCounter: function(includeSeconds){
var digits=[
this.getDays(),
this.getHours(true),
this.getMinutes(true)
];
if(includeSeconds){
digits.push(this.getSeconds(true));
}
return this.digitize(digits);
},
getDays: function(mod){
var days=this.getTimeSeconds() / 60 / 60 / 24;
if(mod){
days=days % 7;
}
return Math.floor(days);
},
getHourCounter: function(){
var obj=this.digitize([
this.getHours(),
this.getMinutes(true),
this.getSeconds(true)
]);
return obj;
},
getHourly: function(){
return this.getHourCounter();
},
getHours: function(mod){
var hours=this.getTimeSeconds() / 60 / 60;
if(mod){
hours=hours % 24;
}
return Math.floor(hours);
},
getMilitaryTime: function(date, showSeconds){
if(typeof showSeconds==="undefined"){
showSeconds=true;
}
if(!date){
date=this.getDateObject();
}
var data=[
date.getHours(),
date.getMinutes()
];
if(showSeconds===true){
data.push(date.getSeconds());
}
return this.digitize(data);
},
getMinutes: function(mod){
var minutes=this.getTimeSeconds() / 60;
if(mod){
minutes=minutes % 60;
}
return Math.floor(minutes);
},
getMinuteCounter: function(){
var obj=this.digitize([
this.getMinutes(),
this.getSeconds(true)
]);
return obj;
},
getTimeSeconds: function(date){
if(!date){
date=new Date();
}
if(this.time instanceof Date){
if(this.factory.countdown){
return Math.max(this.time.getTime()/1000 - date.getTime()/1000,0);
}else{
return date.getTime()/1000 - this.time.getTime()/1000 ;
}}else{
return this.time;
}},
getTime: function(date, showSeconds){
if(typeof showSeconds==="undefined"){
showSeconds=true;
}
if(!date){
date=this.getDateObject();
}
console.log(date);
var hours=date.getHours();
var merid=hours > 12 ? 'PM':'AM';
var data=[
hours > 12 ? hours - 12:(hours===0 ? 12:hours),
date.getMinutes()
];
if(showSeconds===true){
data.push(date.getSeconds());
}
return this.digitize(data);
},
getSeconds: function(mod){
var seconds=this.getTimeSeconds();
if(mod){
if(seconds==60){
seconds=0;
}else{
seconds=seconds % 60;
}}
return Math.ceil(seconds);
},
getWeeks: function(mod){
var weeks=this.getTimeSeconds() / 60 / 60 / 24 / 7;
if(mod){
weeks=weeks % 52;
}
return Math.floor(weeks);
},
removeLeadingZeros: function(totalDigits, digits){
var total=0;
var newArray=[];
$.each(digits, function(i, digit){
if(i < totalDigits){
total +=parseInt(digits[i], 10);
}else{
newArray.push(digits[i]);
}});
if(total===0){
return newArray;
}
return digits;
},
addSeconds: function(x){
if(this.time instanceof Date){
this.time.setSeconds(this.time.getSeconds() + x);
}else{
this.time +=x;
}},
addSecond: function(){
this.addSeconds(1);
},
subSeconds: function(x){
if(this.time instanceof Date){
this.time.setSeconds(this.time.getSeconds() - x);
}else{
this.time -=x;
}},
subSecond: function(){
this.subSeconds(1);
},
toString: function(){
return this.getTimeSeconds().toString();
}
/*
getYears: function(){
return Math.floor(this.time / 60 / 60 / 24 / 7 / 52);
},
getDecades: function(){
return Math.floor(this.getWeeks() / 10);
}*/
});
}(jQuery));
(function($){
"use strict";
FlipClock.Timer=FlipClock.Base.extend({
callbacks: {
destroy: false,
create: false,
init: false,
interval: false,
start: false,
stop: false,
reset: false
},
count: 0,
factory: false,
interval: 1000,
animationRate: 1000,
constructor: function(factory, options){
this.base(options);
this.factory=factory;
this.callback(this.callbacks.init);
this.callback(this.callbacks.create);
},
getElapsed: function(){
return this.count * this.interval;
},
getElapsedTime: function(){
return new Date(this.time + this.getElapsed());
},
reset: function(callback){
clearInterval(this.timer);
this.count=0;
this._setInterval(callback);
this.callback(this.callbacks.reset);
},
start: function(callback){
this.factory.running=true;
this._createTimer(callback);
this.callback(this.callbacks.start);
},
stop: function(callback){
this.factory.running=false;
this._clearInterval(callback);
this.callback(this.callbacks.stop);
this.callback(callback);
},
_clearInterval: function(){
clearInterval(this.timer);
},
_createTimer: function(callback){
this._setInterval(callback);
},
_destroyTimer: function(callback){
this._clearInterval();
this.timer=false;
this.callback(callback);
this.callback(this.callbacks.destroy);
},
_interval: function(callback){
this.callback(this.callbacks.interval);
this.callback(callback);
this.count++;
},
_setInterval: function(callback){
var t=this;
t._interval(callback);
t.timer=setInterval(function(){
t._interval(callback);
}, this.interval);
}});
}(jQuery));
(function($){
FlipClock.TwentyFourHourClockFace=FlipClock.Face.extend({
constructor: function(factory, options){
this.base(factory, options);
},
build: function(time){
var t=this;
var children=this.factory.$el.find('ul');
if(!this.factory.time.time){
this.factory.original=new Date();
this.factory.time=new FlipClock.Time(this.factory, this.factory.original);
}
var time=time ? time:this.factory.time.getMilitaryTime(false, this.showSeconds);
if(time.length > children.length){
$.each(time, function(i, digit){
t.createList(digit);
});
}
this.createDivider();
this.createDivider();
$(this.dividers[0]).insertBefore(this.lists[this.lists.length - 2].$el);
$(this.dividers[1]).insertBefore(this.lists[this.lists.length - 4].$el);
this.base();
},
flip: function(time, doNotAddPlayClass){
this.autoIncrement();
time=time ? time:this.factory.time.getMilitaryTime(false, this.showSeconds);
this.base(time, doNotAddPlayClass);
}});
}(jQuery));
(function($){
FlipClock.CounterFace=FlipClock.Face.extend({
shouldAutoIncrement: false,
constructor: function(factory, options){
if(typeof options!="object"){
options={};}
factory.autoStart=options.autoStart ? true:false;
if(options.autoStart){
this.shouldAutoIncrement=true;
}
factory.increment=function(){
factory.countdown=false;
factory.setTime(factory.getTime().getTimeSeconds() + 1);
};
factory.decrement=function(){
factory.countdown=true;
var time=factory.getTime().getTimeSeconds();
if(time > 0){
factory.setTime(time - 1);
}};
factory.setValue=function(digits){
factory.setTime(digits);
};
factory.setCounter=function(digits){
factory.setTime(digits);
};
this.base(factory, options);
},
build: function(){
var t=this;
var children=this.factory.$el.find('ul');
var time=this.factory.getTime().digitize([this.factory.getTime().time]);
if(time.length > children.length){
$.each(time, function(i, digit){
var list=t.createList(digit);
list.select(digit);
});
}
$.each(this.lists, function(i, list){
list.play();
});
this.base();
},
flip: function(time, doNotAddPlayClass){
if(this.shouldAutoIncrement){
this.autoIncrement();
}
if(!time){
time=this.factory.getTime().digitize([this.factory.getTime().time]);
}
this.base(time, doNotAddPlayClass);
},
reset: function(){
this.factory.time=new FlipClock.Time(this.factory,
this.factory.original ? Math.round(this.factory.original):0
);
this.flip();
}});
}(jQuery));
(function($){
FlipClock.DailyCounterFace=FlipClock.Face.extend({
showSeconds: true,
constructor: function(factory, options){
this.base(factory, options);
},
build: function(time){
var t=this;
var children=this.factory.$el.find('ul');
var offset=0;
time=time ? time:this.factory.time.getDayCounter(this.showSeconds);
if(time.length > children.length){
$.each(time, function(i, digit){
t.createList(digit);
});
}
if(this.showSeconds){
$(this.createDivider('Seconds')).insertBefore(this.lists[this.lists.length - 2].$el);
}else{
offset=2;
}
$(this.createDivider('Minutes')).insertBefore(this.lists[this.lists.length - 4 + offset].$el);
$(this.createDivider('Hours')).insertBefore(this.lists[this.lists.length - 6 + offset].$el);
$(this.createDivider('Days', true)).insertBefore(this.lists[0].$el);
this.base();
},
flip: function(time, doNotAddPlayClass){
if(!time){
time=this.factory.time.getDayCounter(this.showSeconds);
}
this.autoIncrement();
this.base(time, doNotAddPlayClass);
}});
}(jQuery));
(function($){
FlipClock.HourlyCounterFace=FlipClock.Face.extend({
constructor: function(factory, options){
this.base(factory, options);
},
build: function(excludeHours, time){
var t=this;
var children=this.factory.$el.find('ul');
time=time ? time:this.factory.time.getHourCounter();
if(time.length > children.length){
$.each(time, function(i, digit){
t.createList(digit);
});
}
$(this.createDivider('Seconds')).insertBefore(this.lists[this.lists.length - 2].$el);
$(this.createDivider('Minutes')).insertBefore(this.lists[this.lists.length - 4].$el);
if(!excludeHours){
$(this.createDivider('Hours', true)).insertBefore(this.lists[0].$el);
}
this.base();
},
flip: function(time, doNotAddPlayClass){
if(!time){
time=this.factory.time.getHourCounter();
}
this.autoIncrement();
this.base(time, doNotAddPlayClass);
},
appendDigitToClock: function(obj){
this.base(obj);
this.dividers[0].insertAfter(this.dividers[0].next());
}});
}(jQuery));
(function($){
FlipClock.MinuteCounterFace=FlipClock.HourlyCounterFace.extend({
clearExcessDigits: false,
constructor: function(factory, options){
this.base(factory, options);
},
build: function(){
this.base(true, this.factory.time.getMinuteCounter());
},
flip: function(time, doNotAddPlayClass){
if(!time){
time=this.factory.time.getMinuteCounter();
}
this.base(time, doNotAddPlayClass);
}});
}(jQuery));
(function($){
FlipClock.TwelveHourClockFace=FlipClock.TwentyFourHourClockFace.extend({
meridium: false,
meridiumText: 'AM',
build: function(){
var t=this;
var time=this.factory.time.getTime(false, this.showSeconds);
this.base(time);
this.meridiumText=this.getMeridium();
this.meridium=$([
'
'
].join(''));
this.meridium.insertAfter(this.lists[this.lists.length-1].$el);
},
flip: function(time, doNotAddPlayClass){
if(this.meridiumText!=this.getMeridium()){
this.meridiumText=this.getMeridium();
this.meridium.find('a').html(this.meridiumText);
}
this.base(this.factory.time.getTime(false, this.showSeconds), doNotAddPlayClass);
},
getMeridium: function(){
return new Date().getHours() >=12 ? 'PM':'AM';
},
isPM: function(){
return this.getMeridium()=='PM' ? true:false;
},
isAM: function(){
return this.getMeridium()=='AM' ? true:false;
}});
}(jQuery));
(function($){
FlipClock.Lang.Arabic={
'years':'سنوات',
'months':'شهور',
'days':'أيام',
'hours':'ساعات',
'minutes':'دقائق',
'seconds':'ثواني'
};
FlipClock.Lang['ar']=FlipClock.Lang.Arabic;
FlipClock.Lang['ar-ar']=FlipClock.Lang.Arabic;
FlipClock.Lang['arabic']=FlipClock.Lang.Arabic;
}(jQuery));
(function($){
FlipClock.Lang.Danish={
'years':'År',
'months':'Måneder',
'days':'Dage',
'hours':'Timer',
'minutes':'Minutter',
'seconds':'Sekunder'
};
FlipClock.Lang['da']=FlipClock.Lang.Danish;
FlipClock.Lang['da-dk']=FlipClock.Lang.Danish;
FlipClock.Lang['danish']=FlipClock.Lang.Danish;
}(jQuery));
(function($){
FlipClock.Lang.German={
'years':'Jahre',
'months':'Monate',
'days':'Tage',
'hours':'Stunden',
'minutes':'Minuten',
'seconds':'Sekunden'
};
FlipClock.Lang['de']=FlipClock.Lang.German;
FlipClock.Lang['de-de']=FlipClock.Lang.German;
FlipClock.Lang['german']=FlipClock.Lang.German;
}(jQuery));
(function($){
FlipClock.Lang.English={
'years':'Years',
'months':'Months',
'days':'Days',
'hours':'Hours',
'minutes':'Minutes',
'seconds':'Seconds'
};
FlipClock.Lang['en']=FlipClock.Lang.English;
FlipClock.Lang['en-us']=FlipClock.Lang.English;
FlipClock.Lang['english']=FlipClock.Lang.English;
}(jQuery));
(function($){
FlipClock.Lang.Spanish={
'years':'Años',
'months':'Meses',
'days':'DÍas',
'hours':'Horas',
'minutes':'Minutos',
'seconds':'Segundo'
};
FlipClock.Lang['es']=FlipClock.Lang.Spanish;
FlipClock.Lang['es-es']=FlipClock.Lang.Spanish;
FlipClock.Lang['spanish']=FlipClock.Lang.Spanish;
}(jQuery));
(function($){
FlipClock.Lang.Finnish={
'years':'Vuotta',
'months':'Kuukautta',
'days':'Päivää',
'hours':'Tuntia',
'minutes':'Minuuttia',
'seconds':'Sekuntia'
};
FlipClock.Lang['fi']=FlipClock.Lang.Finnish;
FlipClock.Lang['fi-fi']=FlipClock.Lang.Finnish;
FlipClock.Lang['finnish']=FlipClock.Lang.Finnish;
}(jQuery));
(function($){
FlipClock.Lang.French={
'years':'Ans',
'months':'Mois',
'days':'Jours',
'hours':'Heures',
'minutes':'Minutes',
'seconds':'Secondes'
};
FlipClock.Lang['fr']=FlipClock.Lang.French;
FlipClock.Lang['fr-ca']=FlipClock.Lang.French;
FlipClock.Lang['french']=FlipClock.Lang.French;
}(jQuery));
(function($){
FlipClock.Lang.Italian={
'years':'Anni',
'months':'Mesi',
'days':'Giorni',
'hours':'Ore',
'minutes':'Minuti',
'seconds':'Secondi'
};
FlipClock.Lang['it']=FlipClock.Lang.Italian;
FlipClock.Lang['it-it']=FlipClock.Lang.Italian;
FlipClock.Lang['italian']=FlipClock.Lang.Italian;
}(jQuery));
(function($){
FlipClock.Lang.Latvian={
'years':'Gadi',
'months':'Mēneši',
'days':'Dienas',
'hours':'Stundas',
'minutes':'Minūtes',
'seconds':'Sekundes'
};
FlipClock.Lang['lv']=FlipClock.Lang.Latvian;
FlipClock.Lang['lv-lv']=FlipClock.Lang.Latvian;
FlipClock.Lang['latvian']=FlipClock.Lang.Latvian;
}(jQuery));
(function($){
FlipClock.Lang.Dutch={
'years':'Jaren',
'months':'Maanden',
'days':'Dagen',
'hours':'Uren',
'minutes':'Minuten',
'seconds':'Seconden'
};
FlipClock.Lang['nl']=FlipClock.Lang.Dutch;
FlipClock.Lang['nl-be']=FlipClock.Lang.Dutch;
FlipClock.Lang['dutch']=FlipClock.Lang.Dutch;
}(jQuery));
(function($){
FlipClock.Lang.Norwegian={
'years':'År',
'months':'Måneder',
'days':'Dager',
'hours':'Timer',
'minutes':'Minutter',
'seconds':'Sekunder'
};
FlipClock.Lang['no']=FlipClock.Lang.Norwegian;
FlipClock.Lang['nb']=FlipClock.Lang.Norwegian;
FlipClock.Lang['no-nb']=FlipClock.Lang.Norwegian;
FlipClock.Lang['norwegian']=FlipClock.Lang.Norwegian;
}(jQuery));
(function($){
FlipClock.Lang.Portuguese={
'years':'Anos',
'months':'Meses',
'days':'Dias',
'hours':'Horas',
'minutes':'Minutos',
'seconds':'Segundos'
};
FlipClock.Lang['pt']=FlipClock.Lang.Portuguese;
FlipClock.Lang['pt-br']=FlipClock.Lang.Portuguese;
FlipClock.Lang['portuguese']=FlipClock.Lang.Portuguese;
}(jQuery));
(function($){
FlipClock.Lang.Russian={
'years':'лет',
'months':'месяцев',
'days':'дней',
'hours':'часов',
'minutes':'минут',
'seconds':'секунд'
};
FlipClock.Lang['ru']=FlipClock.Lang.Russian;
FlipClock.Lang['ru-ru']=FlipClock.Lang.Russian;
FlipClock.Lang['russian']=FlipClock.Lang.Russian;
}(jQuery));
(function($){
FlipClock.Lang.Swedish={
'years':'År',
'months':'Månader',
'days':'Dagar',
'hours':'Timmar',
'minutes':'Minuter',
'seconds':'Sekunder'
};
FlipClock.Lang['sv']=FlipClock.Lang.Swedish;
FlipClock.Lang['sv-se']=FlipClock.Lang.Swedish;
FlipClock.Lang['swedish']=FlipClock.Lang.Swedish;
}(jQuery));
(function($){
FlipClock.Lang.Chinese={
'years':'年',
'months':'月',
'days':'日',
'hours':'时',
'minutes':'分',
'seconds':'秒'
};
FlipClock.Lang['zh']=FlipClock.Lang.Chinese;
FlipClock.Lang['zh-cn']=FlipClock.Lang.Chinese;
FlipClock.Lang['chinese']=FlipClock.Lang.Chinese;
}(jQuery));
function vc_js(){vc_toggleBehaviour(),vc_tabsBehaviour(),vc_accordionBehaviour(),vc_teaserGrid(),vc_carouselBehaviour(),vc_slidersBehaviour(),vc_prettyPhoto(),vc_googleplus(),vc_pinterest(),vc_progress_bar(),vc_plugin_flexslider(),vc_google_fonts(),vc_gridBehaviour(),vc_rowBehaviour(),vc_googleMapsPointer(),vc_ttaActivation(),jQuery(document).trigger("vc_js"),window.setTimeout(vc_waypoints,500)}function getSizeName(){var screen_w=jQuery(window).width();return screen_w>1170?"desktop_wide":screen_w>960&&1169>screen_w?"desktop":screen_w>768&&959>screen_w?"tablet":screen_w>300&&767>screen_w?"mobile":300>screen_w?"mobile_portrait":""}function loadScript(url,$obj,callback){var script=document.createElement("script");script.type="text/javascript",script.readyState&&(script.onreadystatechange=function(){("loaded"===script.readyState||"complete"===script.readyState)&&(script.onreadystatechange=null,callback())}),script.src=url,$obj.get(0).appendChild(script)}function vc_ttaActivation(){jQuery("[data-vc-accordion]").on("show.vc.accordion",function(e){var $=window.jQuery,ui={};ui.newPanel=$(this).data("vc.accordion").getTarget(),window.wpb_prepare_tab_content(e,ui)})}function vc_accordionActivate(event,ui){if(ui.newPanel.length&&ui.newHeader.length){var $pie_charts=ui.newPanel.find(".vc_pie_chart:not(.vc_ready)"),$round_charts=ui.newPanel.find(".vc_round-chart"),$line_charts=ui.newPanel.find(".vc_line-chart"),$carousel=ui.newPanel.find('[data-ride="vc_carousel"]');"undefined"!=typeof jQuery.fn.isotope&&ui.newPanel.find(".isotope, .wpb_image_grid_ul").isotope("layout"),ui.newPanel.find(".vc_masonry_media_grid, .vc_masonry_grid").length&&ui.newPanel.find(".vc_masonry_media_grid, .vc_masonry_grid").each(function(){var grid=jQuery(this).data("vcGrid");grid&&grid.gridBuilder&&grid.gridBuilder.setMasonry&&grid.gridBuilder.setMasonry()}),vc_carouselBehaviour(ui.newPanel),vc_plugin_flexslider(ui.newPanel),$pie_charts.length&&jQuery.fn.vcChat&&$pie_charts.vcChat(),$round_charts.length&&jQuery.fn.vcRoundChart&&$round_charts.vcRoundChart({reload:!1}),$line_charts.length&&jQuery.fn.vcLineChart&&$line_charts.vcLineChart({reload:!1}),$carousel.length&&jQuery.fn.carousel&&$carousel.carousel("resizeAction"),ui.newPanel.parents(".isotope").length&&ui.newPanel.parents(".isotope").each(function(){jQuery(this).isotope("layout")})}}function initVideoBackgrounds(){return window.console&&window.console.warn&&window.console.warn("this function is deprecated use vc_initVideoBackgrounds"),vc_initVideoBackgrounds()}function vc_initVideoBackgrounds(){jQuery(".vc_row").each(function(){var youtubeUrl,youtubeId,$row=jQuery(this);$row.data("vcVideoBg")?(youtubeUrl=$row.data("vcVideoBg"),youtubeId=vcExtractYoutubeId(youtubeUrl),youtubeId&&($row.find(".vc_video-bg").remove(),insertYoutubeVideoAsBackground($row,youtubeId)),jQuery(window).on("grid:items:added",function(event,$grid){$row.has($grid).length&&vcResizeVideoBackground($row)})):$row.find(".vc_video-bg").remove()})}function insertYoutubeVideoAsBackground($element,youtubeId,counter){if("undefined"==typeof YT.Player)return counter="undefined"==typeof counter?0:counter,counter>100?void console.warn("Too many attempts to load YouTube api"):void setTimeout(function(){insertYoutubeVideoAsBackground($element,youtubeId,counter++)},100);var $container=$element.prepend('
').find(".inner");new YT.Player($container[0],{width:"100%",height:"100%",videoId:youtubeId,playerVars:{playlist:youtubeId,iv_load_policy:3,enablejsapi:1,disablekb:1,autoplay:1,controls:0,showinfo:0,rel:0,loop:1,wmode:"transparent"},events:{onReady:function(event){event.target.mute().setLoop(!0)}}}),vcResizeVideoBackground($element),jQuery(window).bind("resize",function(){vcResizeVideoBackground($element)})}function vcResizeVideoBackground($element){var iframeW,iframeH,marginLeft,marginTop,containerW=$element.innerWidth(),containerH=$element.innerHeight(),ratio1=16,ratio2=9;ratio1/ratio2>containerW/containerH?(iframeW=containerH*(ratio1/ratio2),iframeH=containerH,marginLeft=-Math.round((iframeW-containerW)/2)+"px",marginTop=-Math.round((iframeH-containerH)/2)+"px",iframeW+="px",iframeH+="px"):(iframeW=containerW,iframeH=containerW*(ratio2/ratio1),marginTop=-Math.round((iframeH-containerH)/2)+"px",marginLeft=-Math.round((iframeW-containerW)/2)+"px",iframeW+="px",iframeH+="px"),$element.find(".vc_video-bg iframe").css({maxWidth:"1000%",marginLeft:marginLeft,marginTop:marginTop,width:iframeW,height:iframeH})}function vcExtractYoutubeId(url){if("undefined"==typeof url)return!1;var id=url.match(/(?:https?:\/{2})?(?:w{3}\.)?youtu(?:be)?\.(?:com|be)(?:\/watch\?v=|\/)([^\s&]+)/);return null!==id?id[1]:!1}function vc_googleMapsPointer(){var $=window.jQuery,$wpbGmapsWidget=$(".wpb_gmaps_widget");$wpbGmapsWidget.click(function(){$("iframe",this).css("pointer-events","auto")}),$wpbGmapsWidget.mouseleave(function(){$("iframe",this).css("pointer-events","none")}),$(".wpb_gmaps_widget iframe").css("pointer-events","none")}document.documentElement.className+=" js_active ",document.documentElement.className+="ontouchstart"in document.documentElement?" vc_mobile ":" vc_desktop ",function(){for(var prefix=["-webkit-","-moz-","-ms-","-o-",""],i=0;i
parseInt(ver[1]);$call.each(function(index){var $tabs,interval=jQuery(this).attr("data-interval"),tabs_array=[];if($tabs=jQuery(this).find(".wpb_tour_tabs_wrapper").tabs({show:function(event,ui){wpb_prepare_tab_content(event,ui)},beforeActivate:function(event,ui){1!==ui.newPanel.index()&&ui.newPanel.find(".vc_pie_chart:not(.vc_ready)")},activate:function(event,ui){wpb_prepare_tab_content(event,ui)}}),interval&&interval>0)try{$tabs.tabs("rotate",1e3*interval)}catch(e){window.console&&window.console.log&&console.log(e)}jQuery(this).find(".wpb_tab").each(function(){tabs_array.push(this.id)}),jQuery(this).find(".wpb_tabs_nav li").click(function(e){return e.preventDefault(),old_version?$tabs.tabs("select",jQuery("a",this).attr("href")):$tabs.tabs("option","active",jQuery(this).index()),!1}),jQuery(this).find(".wpb_prev_slide a, .wpb_next_slide a").click(function(e){if(e.preventDefault(),old_version){var index=$tabs.tabs("option","selected");jQuery(this).parent().hasClass("wpb_next_slide")?index++:index--,0>index?index=$tabs.tabs("length")-1:index>=$tabs.tabs("length")&&(index=0),$tabs.tabs("select",index)}else{var index=$tabs.tabs("option","active"),length=$tabs.find(".wpb_tab").length;index=jQuery(this).parent().hasClass("wpb_next_slide")?index+1>=length?0:index+1:0>index-1?length-1:index-1,$tabs.tabs("option","active",index)}})})}}),"function"!=typeof window.vc_accordionBehaviour&&(window.vc_accordionBehaviour=function(){jQuery(".wpb_accordion").each(function(index){var $tabs,$this=jQuery(this),active_tab=($this.attr("data-interval"),!isNaN(jQuery(this).data("active-tab"))&&0 div > h3",autoHeight:!1,heightStyle:"content",active:active_tab,collapsible:collapsible,navigation:!0,activate:vc_accordionActivate,change:function(event,ui){"undefined"!=typeof jQuery.fn.isotope&&ui.newContent.find(".isotope").isotope("layout"),vc_carouselBehaviour(ui.newPanel)}}),!0===$this.data("vcDisableKeydown")&&($tabs.data("uiAccordion")._keydown=function(){})})}),"function"!=typeof window.vc_teaserGrid&&(window.vc_teaserGrid=function(){var layout_modes={fitrows:"fitRows",masonry:"masonry"};jQuery(".wpb_grid .teaser_grid_container:not(.wpb_carousel), .wpb_filtered_grid .teaser_grid_container:not(.wpb_carousel)").each(function(){var $container=jQuery(this),$thumbs=$container.find(".wpb_thumbnails"),layout_mode=$thumbs.attr("data-layout-mode");$thumbs.isotope({itemSelector:".isotope-item",layoutMode:"undefined"==typeof layout_modes[layout_mode]?"fitRows":layout_modes[layout_mode]}),$container.find(".categories_filter a").data("isotope",$thumbs).click(function(e){e.preventDefault();var $thumbs=jQuery(this).data("isotope");jQuery(this).parent().parent().find(".active").removeClass("active"),jQuery(this).parent().addClass("active"),$thumbs.isotope({filter:jQuery(this).attr("data-filter")})}),jQuery(window).bind("load resize",function(){$thumbs.isotope("layout")})})}),"function"!=typeof window.vc_carouselBehaviour&&(window.vc_carouselBehaviour=function($parent){var $carousel=$parent?$parent.find(".wpb_carousel"):jQuery(".wpb_carousel");$carousel.each(function(){var $this=jQuery(this);if(!0!==$this.data("carousel_enabled")&&$this.is(":visible")){$this.data("carousel_enabled",!0);var carousel_speed=(getColumnsCount(jQuery(this)),500);jQuery(this).hasClass("columns_count_1")&&(carousel_speed=900);var carousele_li=jQuery(this).find(".wpb_thumbnails-fluid li");carousele_li.css({"margin-right":carousele_li.css("margin-left"),"margin-left":0});var fluid_ul=jQuery(this).find("ul.wpb_thumbnails-fluid");fluid_ul.width(fluid_ul.width()+300),jQuery(window).resize(function(){var before_resize=screen_size;screen_size=getSizeName(),before_resize!=screen_size&&window.setTimeout("location.reload()",20)})}})}),"function"!=typeof window.vc_slidersBehaviour&&(window.vc_slidersBehaviour=function(){jQuery(".wpb_gallery_slides").each(function(index){var $imagesGrid,this_element=jQuery(this);if(this_element.hasClass("wpb_slider_nivo")){var sliderSpeed=800,sliderTimeout=1e3*this_element.attr("data-interval");0===sliderTimeout&&(sliderTimeout=9999999999),this_element.find(".nivoSlider").nivoSlider({effect:"boxRainGrow,boxRain,boxRainReverse,boxRainGrowReverse",slices:15,boxCols:8,boxRows:4,animSpeed:sliderSpeed,pauseTime:sliderTimeout,startSlide:0,directionNav:!0,directionNavHide:!0,controlNav:!0,keyboardNav:!1,pauseOnHover:!0,manualAdvance:!1,prevText:"Prev",nextText:"Next"})}else this_element.hasClass("wpb_image_grid")&&(jQuery.fn.imagesLoaded?$imagesGrid=this_element.find(".wpb_image_grid_ul").imagesLoaded(function(){$imagesGrid.isotope({itemSelector:".isotope-item",layoutMode:"fitRows"})}):this_element.find(".wpb_image_grid_ul").isotope({itemSelector:".isotope-item",layoutMode:"fitRows"}))})}),"function"!=typeof window.vc_prettyPhoto&&(window.vc_prettyPhoto=function(){try{jQuery&&jQuery.fn&&jQuery.fn.prettyPhoto&&jQuery('a.prettyphoto, .gallery-icon a[href*=".jpg"]').prettyPhoto({animationSpeed:"normal",hook:"data-rel",padding:15,opacity:.7,showTitle:!0,allowresize:!0,counter_separator_label:"/",hideflash:!1,deeplinking:!1,modal:!1,callback:function(){var url=location.href,hashtag=url.indexOf("#!prettyPhoto")?!0:!1;hashtag&&(location.hash="")},social_tools:""})}catch(err){window.console&&window.console.log&&console.log(err)}}),"function"!=typeof window.vc_google_fonts&&(window.vc_google_fonts=function(){return!1}),window.vcParallaxSkroll=!1,"function"!=typeof window.vc_rowBehaviour&&(window.vc_rowBehaviour=function(){function fullWidthRow(){var $elements=$('[data-vc-full-width="true"]');$.each($elements,function(key,item){var $el=$(this);$el.addClass("vc_hidden");var $el_full=$el.next(".vc_row-full-width");if($el_full.length||($el_full=$el.parent().next(".vc_row-full-width")),$el_full.length){var el_margin_left=parseInt($el.css("margin-left"),10),el_margin_right=parseInt($el.css("margin-right"),10),offset=0-$el_full.offset().left-el_margin_left,width=$(window).width();if($el.css({position:"relative",left:offset,"box-sizing":"border-box",width:$(window).width()}),!$el.data("vcStretchContent")){var padding=-1*offset;0>padding&&(padding=0);var paddingRight=width-padding-$el_full.width()+el_margin_left+el_margin_right;0>paddingRight&&(paddingRight=0),$el.css({"padding-left":padding+"px","padding-right":paddingRight+"px"})}$el.attr("data-vc-full-width-init","true"),$el.removeClass("vc_hidden")}}),$(document).trigger("vc-full-width-row",$elements)}function parallaxRow(){var vcSkrollrOptions,callSkrollInit=!1;return window.vcParallaxSkroll&&window.vcParallaxSkroll.destroy(),$(".vc_parallax-inner").remove(),$("[data-5p-top-bottom]").removeAttr("data-5p-top-bottom data-30p-top-bottom"),$("[data-vc-parallax]").each(function(){var skrollrSpeed,skrollrSize,skrollrStart,skrollrEnd,$parallaxElement,parallaxImage,youtubeId;callSkrollInit=!0,"on"===$(this).data("vcParallaxOFade")&&$(this).children().attr("data-5p-top-bottom","opacity:0;").attr("data-30p-top-bottom","opacity:1;"),skrollrSize=100*$(this).data("vcParallax"),$parallaxElement=$("").addClass("vc_parallax-inner").appendTo($(this)),$parallaxElement.height(skrollrSize+"%"),parallaxImage=$(this).data("vcParallaxImage"),youtubeId=vcExtractYoutubeId(parallaxImage),youtubeId?insertYoutubeVideoAsBackground($parallaxElement,youtubeId):"undefined"!=typeof parallaxImage&&$parallaxElement.css("background-image","url("+parallaxImage+")"),skrollrSpeed=skrollrSize-100,skrollrStart=-skrollrSpeed,skrollrEnd=0,$parallaxElement.attr("data-bottom-top","top: "+skrollrStart+"%;").attr("data-top-bottom","top: "+skrollrEnd+"%;")}),callSkrollInit&&window.skrollr?(vcSkrollrOptions={forceHeight:!1,smoothScrolling:!1,mobileCheck:function(){return!1}},window.vcParallaxSkroll=skrollr.init(vcSkrollrOptions),window.vcParallaxSkroll):!1}function fullHeightRow(){var $element=$(".vc_row-o-full-height:first");if($element.length){var $window,windowHeight,offsetTop,fullHeight;$window=$(window),windowHeight=$window.height(),offsetTop=$element.offset().top,windowHeight>offsetTop&&(fullHeight=100-offsetTop/(windowHeight/100),$element.css("min-height",fullHeight+"vh"))}$(document).trigger("vc-full-height-row",$element)}function fixIeFlexbox(){var ua=window.navigator.userAgent,msie=ua.indexOf("MSIE ");(msie>0||navigator.userAgent.match(/Trident.*rv\:11\./))&&$(".vc_row-o-full-height").each(function(){"flex"===$(this).css("display")&&$(this).wrap('')})}var $=window.jQuery;$(window).off("resize.vcRowBehaviour").on("resize.vcRowBehaviour",fullWidthRow).on("resize.vcRowBehaviour",fullHeightRow),fullWidthRow(),fullHeightRow(),fixIeFlexbox(),vc_initVideoBackgrounds(),parallaxRow()}),"function"!=typeof window.vc_gridBehaviour&&(window.vc_gridBehaviour=function(){jQuery.fn.vcGrid&&jQuery("[data-vc-grid]").vcGrid()}),"function"!=typeof window.getColumnsCount&&(window.getColumnsCount=function(el){for(var find=!1,i=1;!1===find;){if(el.hasClass("columns_count_"+i))return find=!0,i;i++}});var screen_size=getSizeName();"function"!=typeof window.wpb_prepare_tab_content&&(window.wpb_prepare_tab_content=function(event,ui){var $ui_panel,$google_maps,panel=ui.panel||ui.newPanel,$pie_charts=panel.find(".vc_pie_chart:not(.vc_ready)"),$round_charts=panel.find(".vc_round-chart"),$line_charts=panel.find(".vc_line-chart"),$carousel=panel.find('[data-ride="vc_carousel"]');if(vc_carouselBehaviour(),vc_plugin_flexslider(panel),ui.newPanel.find(".vc_masonry_media_grid, .vc_masonry_grid").length&&ui.newPanel.find(".vc_masonry_media_grid, .vc_masonry_grid").each(function(){var grid=jQuery(this).data("vcGrid");grid&&grid.gridBuilder&&grid.gridBuilder.setMasonry&&grid.gridBuilder.setMasonry()}),panel.find(".vc_masonry_media_grid, .vc_masonry_grid").length&&panel.find(".vc_masonry_media_grid, .vc_masonry_grid").each(function(){var grid=jQuery(this).data("vcGrid");grid&&grid.gridBuilder&&grid.gridBuilder.setMasonry&&grid.gridBuilder.setMasonry()}),$pie_charts.length&&jQuery.fn.vcChat&&$pie_charts.vcChat(),$round_charts.length&&jQuery.fn.vcRoundChart&&$round_charts.vcRoundChart({reload:!1}),$line_charts.length&&jQuery.fn.vcLineChart&&$line_charts.vcLineChart({reload:!1}),$carousel.length&&jQuery.fn.carousel&&$carousel.carousel("resizeAction"),$ui_panel=panel.find(".isotope, .wpb_image_grid_ul"),$google_maps=panel.find(".wpb_gmaps_widget"),0<$ui_panel.length&&$ui_panel.isotope("layout"),$google_maps.length&&!$google_maps.is(".map_ready")){var $frame=$google_maps.find("iframe");$frame.attr("src",$frame.attr("src")),$google_maps.addClass("map_ready")}panel.parents(".isotope").length&&panel.parents(".isotope").each(function(){jQuery(this).isotope("layout")})}),"function"!=typeof window.vc_googleMapsPointer,jQuery(document).ready(function($){window.vc_js()});
(function(e){var t=function(t,n){var r=e.extend({},e.fn.nivoSlider.defaults,n);var i={currentSlide:0,currentImage:"",totalSlides:0,running:false,paused:false,stop:false,controlNavEl:false};var s=e(t);s.data("nivo:vars",i).addClass("nivoSlider");var o=s.children();o.each(function(){var t=e(this);var n="";if(!t.is("img")){if(t.is("a")){t.addClass("nivo-imageLink");n=t}t=t.find("img:first")}var r=r===0?t.attr("width"):t.width(),s=s===0?t.attr("height"):t.height();if(n!==""){n.css("display","none")}t.css("display","none");i.totalSlides++});if(r.randomStart){r.startSlide=Math.floor(Math.random()*i.totalSlides)}if(r.startSlide>0){if(r.startSlide>=i.totalSlides){r.startSlide=i.totalSlides-1}i.currentSlide=r.startSlide}if(e(o[i.currentSlide]).is("img")){i.currentImage=e(o[i.currentSlide])}else{i.currentImage=e(o[i.currentSlide]).find("img:first")}if(e(o[i.currentSlide]).is("a")){e(o[i.currentSlide]).css("display","block")}var u=e("").addClass("nivo-main-image");u.attr("src",i.currentImage.attr("src")).show();s.append(u);e(window).resize(function(){s.children("img").width(s.width());u.attr("src",i.currentImage.attr("src"));u.stop().height("auto");e(".nivo-slice").remove();e(".nivo-box").remove()});s.append(e(''));var a=function(t){var n=e(".nivo-caption",s);if(i.currentImage.attr("data-title")!=""&&i.currentImage.attr("data-title")!=undefined){var r=i.currentImage.attr("data-title");if(r.substr(0,1)=="#")r=e(r).html();if(n.css("display")=="block"){setTimeout(function(){n.html(r)},t.animSpeed)}else{n.html(r);n.stop().fadeIn(t.animSpeed)}}else{n.stop().fadeOut(t.animSpeed)}};a(r);var f=0;if(!r.manualAdvance&&o.length>1){f=setInterval(function(){d(s,o,r,false)},r.pauseTime)}if(r.directionNav){s.append('");e(s).on("click","a.nivo-prevNav",function(){if(i.running){return false}clearInterval(f);f="";i.currentSlide-=2;d(s,o,r,"prev")});e(s).on("click","a.nivo-nextNav",function(){if(i.running){return false}clearInterval(f);f="";d(s,o,r,"next")})}if(r.controlNav){i.controlNavEl=e('');s.after(i.controlNavEl);for(var l=0;l')}else{i.controlNavEl.append(''+(l+1)+"")}}e("a:eq("+i.currentSlide+")",i.controlNavEl).addClass("active");e("a",i.controlNavEl).bind("click",function(){if(i.running)return false;if(e(this).hasClass("active"))return false;clearInterval(f);f="";u.attr("src",i.currentImage.attr("src"));i.currentSlide=e(this).attr("rel")-1;d(s,o,r,"control")})}if(r.pauseOnHover){s.hover(function(){i.paused=true;clearInterval(f);f=""},function(){i.paused=false;if(f===""&&!r.manualAdvance){f=setInterval(function(){d(s,o,r,false)},r.pauseTime)}})}s.bind("nivo:animFinished",function(){u.attr("src",i.currentImage.attr("src"));i.running=false;e(o).each(function(){if(e(this).is("a")){e(this).css("display","none")}});if(e(o[i.currentSlide]).is("a")){e(o[i.currentSlide]).css("display","block")}if(f===""&&!i.paused&&!r.manualAdvance){f=setInterval(function(){d(s,o,r,false)},r.pauseTime)}r.afterChange.call(this)});var h=function(t,n,r){if(e(r.currentImage).parent().is("a"))e(r.currentImage).parent().css("display","block");e('img[src="'+r.currentImage.attr("src")+'"]',t).not(".nivo-main-image,.nivo-control img").width(t.width()).css("visibility","hidden").show();var i=e('img[src="'+r.currentImage.attr("src")+'"]',t).not(".nivo-main-image,.nivo-control img").parent().is("a")?e('img[src="'+r.currentImage.attr("src")+'"]',t).not(".nivo-main-image,.nivo-control img").parent().height():e('img[src="'+r.currentImage.attr("src")+'"]',t).not(".nivo-main-image,.nivo-control img").height();for(var s=0;s ').css({left:o*s+"px",width:t.width()-o*s+"px",height:i+"px",opacity:"0",overflow:"hidden"}))}else{t.append(e('