text: (function(e,t,n){"use strict";Foundation.libs.section={name:"section",version:"4.0.8",settings:{deep_linking:!1,one_up:!0,callback:function(){}},init:function(e,t,n){return this.scope=e||this.scope,Foundation.inherit(this,"throttle data_options"),"string"!=typeof t?(this.set_active_from_hash(),this.events(),!0):this[t].call(this,n)},events:function(){var i=this;e(this.scope).on("click.fndtn.section","[data-section] .title",function(t){var n=e(this);n.closest("[data-section]"),i.toggle_active.call(this,t,i)}),e(t).on("resize.fndtn.section",i.throttle(function(){i.resize.call(this)},30)).on("hashchange",function(){i.settings.toggled||(i.set_active_from_hash(),e(this).trigger("resize"))}).trigger("resize"),e(n).on("click.fndtn.section",function(t){1>e(t.target).closest(".title").length&&e("[data-section].vertical-nav, [data-section].horizontal-nav").find("section, .section").removeClass("active").attr("style","")})},toggle_active:function(t,n){var i=e(this),r=i.closest("section, .section"),o=r.find(".content"),a=r.closest("[data-section]"),n=Foundation.libs.section,s=e.extend({},n.settings,n.data_options(a));if(n.settings.toggled=!0,!s.deep_linking&&o.length>0&&t.preventDefault(),r.hasClass("active"))(n.small(a)||n.is_vertical(a)||n.is_horizontal(a)||n.is_accordion(a))&&r.removeClass("active").attr("style","");else{var l=null,c=n.outerHeight(r.find(".title"));(n.small(a)||s.one_up)&&(l=i.closest("[data-section]").find("section.active, .section.active"),n.small(a)?l.attr("style",""):l.attr("style","visibility: hidden; padding-top: "+c+"px;")),n.small(a)?r.attr("style",""):r.css("padding-top",c),r.addClass("active"),null!==l&&l.removeClass("active").attr("style","")}setTimeout(function(){n.settings.toggled=!1},300),s.callback()},resize:function(){var t=e("[data-section]"),n=Foundation.libs.section;t.each(function(){var t=e(this),i=t.find("section.active, .section.active");if(e.extend({},n.settings,n.data_options(t)),i.length>1)i.not(":first").removeClass("active").attr("style","");else if(1>i.length&&!n.is_vertical(t)&&!n.is_horizontal(t)&&!n.is_accordion(t)){var r=t.find("section, .section").first();r.addClass("active"),n.small(t)?r.attr("style",""):r.css("padding-top",n.outerHeight(r.find(".title")))}n.small(t)?i.attr("style",""):i.css("padding-top",n.outerHeight(i.find(".title"))),n.position_titles(t),n.is_horizontal(t)&&!n.small(t)?n.position_content(t):n.position_content(t,!1)})},is_vertical:function(e){return e.hasClass("vertical-nav")},is_horizontal:function(e){return e.hasClass("horizontal-nav")},is_accordion:function(e){return e.hasClass("accordion")},set_active_from_hash:function(){var n=t.location.hash.substring(1),i=e("[data-section]"),r=this;i.each(function(){var t=e(this),i=e.extend({},r.settings,r.data_options(t));n.length>0&&i.deep_linking&&(t.find("section, .section").attr("style","").removeClass("active"),t.find('.content[data-slug="'+n+'"]').closest("section, .section").addClass("active"))})},position_titles:function(t,n){var i=t.find(".title"),r=0,o=this;"boolean"==typeof n?i.attr("style",""):i.each(function(){e(this).css("left",r),r+=o.outerWidth(e(this))})},position_content:function(t,n){var i=t.find(".title"),r=t.find(".content"),o=this;"boolean"==typeof n?(r.attr("style",""),t.attr("style","")):(t.find("section, .section").each(function(){var t=e(this).find(".title"),n=e(this).find(".content");n.css({left:t.position().left-1,top:o.outerHeight(t)-2})}),"function"==typeof Zepto?t.height(this.outerHeight(i.first())):t.height(this.outerHeight(i.first())-2))},small:function(t){return e.extend({},this.settings,this.data_options(t)),t&&t.hasClass("tabs")?!1:t&&this.is_accordion(t)?!0:e("html").hasClass("lt-ie9")?!0:e("html").hasClass("ie8compat")?!0:768>e(this.scope).width()},off:function(){e(this.scope).off(".fndtn.section"),e(t).off(".fndtn.section"),e(n).off(".fndtn.section")}}})(Foundation.zj,this,this.document);