/* Array.indexOf polyfill 
*  https://developer.mozilla.org/en-US/docs/JavaScript/Reference/Global_Objects/Array/indexOf
*/
if (!Array.prototype.indexOf) { Array.prototype.indexOf = function (e) { "use strict"; if (this == null) { throw new TypeError } var t = Object(this); var n = t.length >>> 0; if (n === 0) { return -1 } var r = 0; if (arguments.length > 1) { r = Number(arguments[1]); if (r != r) { r = 0 } else if (r != 0 && r != Infinity && r != -Infinity) { r = (r > 0 || -1) * Math.floor(Math.abs(r)) } } if (r >= n) { return -1 } var i = r >= 0 ? r : Math.max(n - Math.abs(r), 0); for (; i < n; i++) { if (i in t && t[i] === e) { return i } } return -1 } }

/*
* jQuery hashchange event - v1.3 - 7/21/2010
* http://benalman.com/projects/jquery-hashchange-plugin/
* 
* Copyright (c) 2010 "Cowboy" Ben Alman
* Dual licensed under the MIT and GPL licenses.
* http://benalman.com/about/license/
*/
(function ($, e, b) { var c = "hashchange", h = document, f, g = $.event.special, i = h.documentMode, d = "on" + c in e && (i === b || i > 7); function a(j) { j = j || location.href; return "#" + j.replace(/^[^#]*#?(.*)$/, "$1") } $.fn[c] = function (j) { return j ? this.bind(c, j) : this.trigger(c) }; $.fn[c].delay = 50; g[c] = $.extend(g[c], { setup: function () { if (d) { return false } $(f.start) }, teardown: function () { if (d) { return false } $(f.stop) } }); f = (function () { var j = {}, p, m = a(), k = function (q) { return q }, l = k, o = k; j.start = function () { p || n() }; j.stop = function () { p && clearTimeout(p); p = b }; function n() { var r = a(), q = o(m); if (r !== m) { l(m = r, q); $(e).trigger(c) } else { if (q !== m) { location.href = location.href.replace(/#.*/, "") + q } } p = setTimeout(n, $.fn[c].delay) } $.browser.msie && !d && (function () { var q, r; j.start = function () { if (!q) { r = $.fn[c].src; r = r && r + a(); q = $('<iframe tabindex="-1" title="empty"/>').hide().one("load", function () { r || l(a()); n() }).attr("src", r || "javascript:0").insertAfter("body")[0].contentWindow; h.onpropertychange = function () { try { if (event.propertyName === "title") { q.document.title = h.title } } catch (s) { } } } }; j.stop = k; o = function () { return a(q.location.href) }; l = function (v, s) { var u = q.document, t = $.fn[c].domain; if (v !== s) { u.title = h.title; u.open(); t && u.write('<script>document.domain="' + t + '"<\/script>'); u.close(); q.location.hash = v } } })(); return j })() })(jQuery, this);

/*! http://mths.be/placeholder v1.8.7 by @mathias */
(function (f, h, c) { var a = 'placeholder' in h.createElement('input'), d = 'placeholder' in h.createElement('textarea'), i = c.fn, j; if (a && d) { j = i.placeholder = function () { return this }; j.input = j.textarea = true } else { j = i.placeholder = function () { return this.filter((a ? 'textarea' : ':input') + '[placeholder]').not('.placeholder').bind('focus.placeholder', b).bind('blur.placeholder', e).trigger('blur.placeholder').end() }; j.input = a; j.textarea = d; c(function () { c(h).delegate('form', 'submit.placeholder', function () { var k = c('.placeholder', this).each(b); setTimeout(function () { k.each(e) }, 10) }) }); c(f).bind('unload.placeholder', function () { c('.placeholder').val('') }) } function g(l) { var k = {}, m = /^jQuery\d+$/; c.each(l.attributes, function (o, n) { if (n.specified && !m.test(n.name)) { k[n.name] = n.value } }); return k } function b() { var k = c(this); if (k.val() === k.attr('placeholder') && k.hasClass('placeholder')) { if (k.data('placeholder-password')) { k.hide().next().show().focus().attr('id', k.removeAttr('id').data('placeholder-id')) } else { k.val('').removeClass('placeholder') } } } function e() { var o, n = c(this), k = n, m = this.id; if (n.val() === '') { if (n.is(':password')) { if (!n.data('placeholder-textinput')) { try { o = n.clone().attr({ type: 'text' }) } catch (l) { o = c('<input>').attr(c.extend(g(this), { type: 'text' })) } o.removeAttr('name').data('placeholder-password', true).data('placeholder-id', m).bind('focus.placeholder', b); n.data('placeholder-textinput', o).data('placeholder-id', m).before(o) } n = n.removeAttr('id').hide().prev().attr('id', m).show() } n.addClass('placeholder').val(n.attr('placeholder')) } else { n.removeClass('placeholder') } } } (this, document, jQuery));

/*
* jQuery scrollintoview() plugin and :scrollable selector filter
*
* Version 1.8 (14 Jul 2011)
* Requires jQuery 1.4 or newer
*
* Copyright (c) 2011 Robert Koritnik
* Licensed under the terms of the MIT license
* http://www.opensource.org/licenses/mit-license.php
*/
(function (f) { var c = { vertical: { x: false, y: true }, horizontal: { x: true, y: false }, both: { x: true, y: true }, x: { x: true, y: false }, y: { x: false, y: true} }; var b = { duration: "fast", direction: "both" }; var e = /^(?:html)$/i; var g = function (k, j) { j = j || (document.defaultView && document.defaultView.getComputedStyle ? document.defaultView.getComputedStyle(k, null) : k.currentStyle); var i = document.defaultView && document.defaultView.getComputedStyle ? true : false; var h = { top: (parseFloat(i ? j.borderTopWidth : f.css(k, "borderTopWidth")) || 0), left: (parseFloat(i ? j.borderLeftWidth : f.css(k, "borderLeftWidth")) || 0), bottom: (parseFloat(i ? j.borderBottomWidth : f.css(k, "borderBottomWidth")) || 0), right: (parseFloat(i ? j.borderRightWidth : f.css(k, "borderRightWidth")) || 0) }; return { top: h.top, left: h.left, bottom: h.bottom, right: h.right, vertical: h.top + h.bottom, horizontal: h.left + h.right} }; var d = function (h) { var j = f(window); var i = e.test(h[0].nodeName); return { border: i ? { top: 0, left: 0, bottom: 0, right: 0} : g(h[0]), scroll: { top: (i ? j : h).scrollTop(), left: (i ? j : h).scrollLeft() }, scrollbar: { right: i ? 0 : h.innerWidth() - h[0].clientWidth, bottom: i ? 0 : h.innerHeight() - h[0].clientHeight }, rect: (function () { var k = h[0].getBoundingClientRect(); return { top: i ? 0 : k.top, left: i ? 0 : k.left, bottom: i ? h[0].clientHeight : k.bottom, right: i ? h[0].clientWidth : k.right} })()} }; f.fn.extend({ scrollintoview: function (j) { j = f.extend({}, b, j); j.direction = c[typeof (j.direction) === "string" && j.direction.toLowerCase()] || c.both; var n = ""; if (j.direction.x === true) { n = "horizontal" } if (j.direction.y === true) { n = n ? "both" : "vertical" } var l = this.eq(0); var i = l.closest(":scrollable(" + n + ")"); if (i.length > 0) { i = i.eq(0); var m = { e: d(l), s: d(i) }; var h = { top: m.e.rect.top - (m.s.rect.top + m.s.border.top), bottom: m.s.rect.bottom - m.s.border.bottom - m.s.scrollbar.bottom - m.e.rect.bottom, left: m.e.rect.left - (m.s.rect.left + m.s.border.left), right: m.s.rect.right - m.s.border.right - m.s.scrollbar.right - m.e.rect.right }; var k = {}; if (j.direction.y === true) { if (h.top < 0) { k.scrollTop = m.s.scroll.top + h.top } else { if (h.top > 0 && h.bottom < 0) { k.scrollTop = m.s.scroll.top + Math.min(h.top, -h.bottom) } } } if (j.direction.x === true) { if (h.left < 0) { k.scrollLeft = m.s.scroll.left + h.left } else { if (h.left > 0 && h.right < 0) { k.scrollLeft = m.s.scroll.left + Math.min(h.left, -h.right) } } } if (!f.isEmptyObject(k)) { if (e.test(i[0].nodeName)) { i = f("html,body") } i.animate(k, j.duration).eq(0).queue(function (o) { f.isFunction(j.complete) && j.complete.call(i[0]); o() }) } else { f.isFunction(j.complete) && j.complete.call(i[0]) } } return this } }); var a = { auto: true, scroll: true, visible: false, hidden: false }; f.extend(f.expr[":"], { scrollable: function (k, i, n, h) { var m = c[typeof (n[3]) === "string" && n[3].toLowerCase()] || c.both; var l = (document.defaultView && document.defaultView.getComputedStyle ? document.defaultView.getComputedStyle(k, null) : k.currentStyle); var o = { x: a[l.overflowX.toLowerCase()] || false, y: a[l.overflowY.toLowerCase()] || false, isRoot: e.test(k.nodeName) }; if (!o.x && !o.y && !o.isRoot) { return false } var j = { height: { scroll: k.scrollHeight, client: k.clientHeight }, width: { scroll: k.scrollWidth, client: k.clientWidth }, scrollableX: function () { return (o.x || o.isRoot) && this.width.scroll > this.width.client }, scrollableY: function () { return (o.y || o.isRoot) && this.height.scroll > this.height.client } }; return m.y && j.scrollableY() || m.x && j.scrollableX() } }) })(jQuery);

/**
 * jQuery.browser.mobile (http://detectmobilebrowser.com/)
 *
 * jQuery.browser.mobile will be true if the browser is a mobile device
 *
 **/
(function (a) { (jQuery.browser = jQuery.browser || {}).mobile = /(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino/i.test(a) || /1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i.test(a.substr(0, 4)) })(navigator.userAgent || navigator.vendor || window.opera);

/*
* Foundation Responsive Library
* http://foundation.zurb.com
* Copyright 2014, ZURB
* Free to use under the MIT license.
* http://www.opensource.org/licenses/mit-license.php
*
* Foundation Zurb - Off Canvas layout jQuery
*/
(function (e, t, n) { var r = n("#topMenu"), i = "click.fndtn"; if (r.length > 0) r.css("margin-top", r.height() * -1); var s = n("#sidebarButton"); if (s.length > 0) { n("#sidebarButton").on(i, function (e) { e.preventDefault(); n("body").toggleClass("active") }) } var o = n("#menuButton"); if (o.length > 0) { n("#menuButton").on(i, function (e) { e.preventDefault(); n("body").toggleClass("active-menu") }) } var u = n("#switchPanels"); if (u.length > 0) { n("#switchPanels dd").on(i, function (e) { e.preventDefault(); var t = n(this).children("a").attr("href"), r = n(t).index(); n(this).toggleClass("active").siblings().removeClass("active"); n(t).parent().css("left", r * -100 + "%") }) } n("#nav li a").on(i, function (e) { e.preventDefault(); var t = n(this).attr("href"), r = n(t); n("html, body").animate({ scrollTop: r.offset().top }, 300) }) })(this, document, jQuery)

/*
highlight v4

Highlights arbitrary terms.

<http://johannburkard.de/blog/programming/javascript/highlight-javascript-text-higlighting-jquery-plugin.html>

MIT license.

Johann Burkard
<http://johannburkard.de>
<mailto:jb@eaio.com>
*/
jQuery.fn.highlight = function (e, t, n) { function d(e, o, h) { if (this.skip = 0, 3 == e.nodeType) { if (e.data.length != h(e.data).length || o.length != h(o).length) return !1; var l = h(o), r = h(e.data); if (!/MCHelpControl/.test(e.parentNode.className) && (/\s/.test(o) || new RegExp("\\s*" + l + "\\s*").test(r))) { var s = h(e.data).indexOf(h(o)); if (s >= 0) { var c = document.createElement(n); t && (c.className = t); var p = e.splitText(s), u = (p.splitText(h(o).length), p.cloneNode(!0)); c.appendChild(u), p.parentNode.replaceChild(c, p), this.skip = 1 } else this.skip = 0 } } else if (1 == e.nodeType && e.childNodes && !/(script|style)/i.test(e.tagName)) for (var N = 0; N < e.childNodes.length; ++N) N += d(e.childNodes[N], o, i) ? this.skip : d(e.childNodes[N], o, a) ? this.skip : this.skip; return !0 } n || (n = "span"); var i = function (e) { return e.toUpperCase() }, a = function (e) { return e.toLowerCase() }, o = function (e) { return e }; return this.length && e && e.length ? this.each(function () { 1 == this.childNodes.length && "undefined" == typeof this.recoveryData && (this.recoveryData = this.firstChild.data), d(this, e, i) || d(this, e, a) || d(this, e, o) }) : this }, jQuery.fn.removeHighlight = function (e, t) { function n(e) { for (var t = 0; t < e.childNodes.length; t++) if (e.childNodes[t].nodeType == Node.TEXT_NODE) { for (var n = new Array, d = e.childNodes[t].nextSibling; null != d && d.nodeType == Node.TEXT_NODE;) e.childNodes[t].data += d.data, n.push(d), d = d.nextSibling; n.forEach(function (t) { e.removeChild(t) }) } } function d() { var e = document.createElement("p"); e.appendChild(document.createTextNode("")), e.appendChild(document.createTextNode("this-")), e.appendChild(document.createTextNode("を終了しますa")), e.appendChild(document.createTextNode("♋uü")), e.appendChild(document.createTextNode("is-a")), e.appendChild(document.createTextNode("nother-testｽ")), e.appendChild(document.createTextNode("¤xyz")), e.appendChild(document.createTextNode("xyz¤Ø")), document.getElementsByTagName("head")[0].appendChild(e), e.normalize(); var t = 1 != e.childNodes.length || e.childNodes[0].length != "this-を終了しますa♋uüis-another-testｽ¤xyzxyz¤Ø".length; return document.getElementsByTagName("head")[0].removeChild(e), t } function i(e) { for (var t = e.childNodes.length > 1, n = 0; n < e.childNodes.length; n++) e.childNodes[n].nodeType == Node.ELEMENT_NODE && (t = !1); return t } return t || (t = "span"), this.find(t + "." + e).each(function () { var e = this, t = e.parentNode; if (null != t && null != t.firstChild) { var a = e.firstChild.cloneNode(); if (t.replaceChild(a, e), d()) n(t); else { var o = t.firstChild.wholeText; t.normalize(), "undefined" != typeof t.recoveryData ? 1 == t.childNodes.length && t.childNodes[0].wholeText != t.recoveryData ? t.innerText = t.recoveryData : i(t) && (t.innerText = t.recoveryData) : t.childNodes[0].data && void 0 != o && o.length > t.childNodes[0].data.length && (t.innerText = o) } } }).end() };