var Sylvester={version:"0.1.3",precision:1.0E-6};function Vector(){}
Vector.prototype={e:function(a){return a<1||a>this.elements.length?null:this.elements[a-1]},dimensions:function(){return this.elements.length},modulus:function(){return Math.sqrt(this.dot(this))},eql:function(a){var c=this.elements.length;a=a.elements||a;if(c!=a.length)return false;do if(Math.abs(this.elements[c-1]-a[c-1])>Sylvester.precision)return false;while(--c);return true},dup:function(){return Vector.create(this.elements)},map:function(a){var c=[];this.each(function(f,d){c.push(a(f,d))});return Vector.create(c)},
each:function(a){var c=this.elements.length,f=c,d;do{d=f-c;a(this.elements[d],d+1)}while(--c)},toUnitVector:function(){var a=this.modulus();if(a===0)return this.dup();return this.map(function(c){return c/a})},angleFrom:function(a){var c=a.elements||a;if(this.elements.length!=c.length)return null;var f=0,d=0,e=0;this.each(function(i,m){f+=i*c[m-1];d+=i*i;e+=c[m-1]*c[m-1]});d=Math.sqrt(d);e=Math.sqrt(e);if(d*e===0)return null;a=f/(d*e);if(a<-1)a=-1;if(a>1)a=1;return Math.acos(a)},isParallelTo:function(a){a=
this.angleFrom(a);return a===null?null:a<=Sylvester.precision},isAntiparallelTo:function(a){a=this.angleFrom(a);return a===null?null:Math.abs(a-Math.PI)<=Sylvester.precision},isPerpendicularTo:function(a){a=this.dot(a);return a===null?null:Math.abs(a)<=Sylvester.precision},add:function(a){var c=a.elements||a;if(this.elements.length!=c.length)return null;return this.map(function(f,d){return f+c[d-1]})},subtract:function(a){var c=a.elements||a;if(this.elements.length!=c.length)return null;return this.map(function(f,
d){return f-c[d-1]})},multiply:function(a){return this.map(function(c){return c*a})},x:function(a){return this.multiply(a)},dot:function(a){a=a.elements||a;var c=0,f=this.elements.length;if(f!=a.length)return null;do c+=this.elements[f-1]*a[f-1];while(--f);return c},cross:function(a){a=a.elements||a;if(this.elements.length!=3||a.length!=3)return null;var c=this.elements;return Vector.create([c[1]*a[2]-c[2]*a[1],c[2]*a[0]-c[0]*a[2],c[0]*a[1]-c[1]*a[0]])},max:function(){var a=0,c=this.elements.length,
f=c,d;do{d=f-c;if(Math.abs(this.elements[d])>Math.abs(a))a=this.elements[d]}while(--c);return a},indexOf:function(a){var c=null,f=this.elements.length,d=f,e;do{e=d-f;if(c===null&&this.elements[e]==a)c=e+1}while(--f);return c},toDiagonalMatrix:function(){return Matrix.Diagonal(this.elements)},round:function(){return this.map(function(a){return Math.round(a)})},snapTo:function(a){return this.map(function(c){return Math.abs(c-a)<=Sylvester.precision?a:c})},distanceFrom:function(a){if(a.anchor)return a.distanceFrom(this);
var c=a.elements||a;if(c.length!=this.elements.length)return null;var f=0,d;this.each(function(e,i){d=e-c[i-1];f+=d*d});return Math.sqrt(f)},liesOn:function(a){return a.contains(this)},liesIn:function(a){return a.contains(this)},rotate:function(a,c){var f,d,e;switch(this.elements.length){case 2:f=c.elements||c;if(f.length!=2)return null;a=Matrix.Rotation(a).elements;c=this.elements[0]-f[0];d=this.elements[1]-f[1];return Vector.create([f[0]+a[0][0]*c+a[0][1]*d,f[1]+a[1][0]*c+a[1][1]*d]);case 3:if(!c.direction)return null;
f=c.pointClosestTo(this).elements;a=Matrix.Rotation(a,c.direction).elements;c=this.elements[0]-f[0];d=this.elements[1]-f[1];e=this.elements[2]-f[2];return Vector.create([f[0]+a[0][0]*c+a[0][1]*d+a[0][2]*e,f[1]+a[1][0]*c+a[1][1]*d+a[1][2]*e,f[2]+a[2][0]*c+a[2][1]*d+a[2][2]*e]);default:return null}},reflectionIn:function(a){if(a.anchor){var c=this.elements.slice();a=a.pointClosestTo(c).elements;return Vector.create([a[0]+(a[0]-c[0]),a[1]+(a[1]-c[1]),a[2]+(a[2]-(c[2]||0))])}else{var f=a.elements||a;
if(this.elements.length!=f.length)return null;return this.map(function(d,e){return f[e-1]+(f[e-1]-d)})}},to3D:function(){var a=this.dup();switch(a.elements.length){case 3:break;case 2:a.elements.push(0);break;default:return null}return a},inspect:function(){return"["+this.elements.join(", ")+"]"},setElements:function(a){this.elements=(a.elements||a).slice();return this}};Vector.create=function(a){return(new Vector).setElements(a)};Vector.i=Vector.create([1,0,0]);Vector.j=Vector.create([0,1,0]);
Vector.k=Vector.create([0,0,1]);Vector.Random=function(a){var c=[];do c.push(Math.random());while(--a);return Vector.create(c)};Vector.Zero=function(a){var c=[];do c.push(0);while(--a);return Vector.create(c)};function Matrix(){}
Matrix.prototype={e:function(a,c){if(a<1||a>this.elements.length||c<1||c>this.elements[0].length)return null;return this.elements[a-1][c-1]},row:function(a){if(a>this.elements.length)return null;return Vector.create(this.elements[a-1])},col:function(a){if(a>this.elements[0].length)return null;var c=[],f=this.elements.length,d=f,e;do{e=d-f;c.push(this.elements[e][a-1])}while(--f);return Vector.create(c)},dimensions:function(){return{rows:this.elements.length,cols:this.elements[0].length}},rows:function(){return this.elements.length},
cols:function(){return this.elements[0].length},eql:function(a){a=a.elements||a;if(typeof a[0][0]=="undefined")a=Matrix.create(a).elements;if(this.elements.length!=a.length||this.elements[0].length!=a[0].length)return false;var c=this.elements.length,f=c,d,e,i=this.elements[0].length,m;do{d=f-c;e=i;do{m=i-e;if(Math.abs(this.elements[d][m]-a[d][m])>Sylvester.precision)return false}while(--e)}while(--c);return true},dup:function(){return Matrix.create(this.elements)},map:function(a){var c=[],f=this.elements.length,
d=f,e,i,m=this.elements[0].length,q;do{e=d-f;i=m;c[e]=[];do{q=m-i;c[e][q]=a(this.elements[e][q],e+1,q+1)}while(--i)}while(--f);return Matrix.create(c)},isSameSizeAs:function(a){a=a.elements||a;if(typeof a[0][0]=="undefined")a=Matrix.create(a).elements;return this.elements.length==a.length&&this.elements[0].length==a[0].length},add:function(a){var c=a.elements||a;if(typeof c[0][0]=="undefined")c=Matrix.create(c).elements;if(!this.isSameSizeAs(c))return null;return this.map(function(f,d,e){return f+
c[d-1][e-1]})},subtract:function(a){var c=a.elements||a;if(typeof c[0][0]=="undefined")c=Matrix.create(c).elements;if(!this.isSameSizeAs(c))return null;return this.map(function(f,d,e){return f-c[d-1][e-1]})},canMultiplyFromLeft:function(a){a=a.elements||a;if(typeof a[0][0]=="undefined")a=Matrix.create(a).elements;return this.elements[0].length==a.length},multiply:function(a){if(!a.elements)return this.map(function(y){return y*a});var c=a.modulus?true:false,f=a.elements||a;if(typeof f[0][0]=="undefined")f=
Matrix.create(f).elements;if(!this.canMultiplyFromLeft(f))return null;var d=this.elements.length,e=d,i,m,q=f[0].length,o,s=this.elements[0].length,C=[],z,g,A;do{i=e-d;C[i]=[];m=q;do{o=q-m;z=0;g=s;do{A=s-g;z+=this.elements[i][A]*f[A][o]}while(--g);C[i][o]=z}while(--m)}while(--d);f=Matrix.create(C);return c?f.col(1):f},x:function(a){return this.multiply(a)},minor:function(a,c,f,d){var e=[],i=f,m,q,o,s=this.elements.length,C=this.elements[0].length;do{m=f-i;e[m]=[];q=d;do{o=d-q;e[m][o]=this.elements[(a+
m-1)%s][(c+o-1)%C]}while(--q)}while(--i);return Matrix.create(e)},transpose:function(){var a=this.elements.length,c=this.elements[0].length,f=[],d=c,e,i,m;do{e=c-d;f[e]=[];i=a;do{m=a-i;f[e][m]=this.elements[m][e]}while(--i)}while(--d);return Matrix.create(f)},isSquare:function(){return this.elements.length==this.elements[0].length},max:function(){var a=0,c=this.elements.length,f=c,d,e,i=this.elements[0].length,m;do{d=f-c;e=i;do{m=i-e;if(Math.abs(this.elements[d][m])>Math.abs(a))a=this.elements[d][m]}while(--e)}while(--c);
return a},indexOf:function(a){var c=this.elements.length,f=c,d,e,i=this.elements[0].length,m;do{d=f-c;e=i;do{m=i-e;if(this.elements[d][m]==a)return{i:d+1,j:m+1}}while(--e)}while(--c);return null},diagonal:function(){if(!this.isSquare)return null;var a=[],c=this.elements.length,f=c,d;do{d=f-c;a.push(this.elements[d][d])}while(--c);return Vector.create(a)},toRightTriangular:function(){var a=this.dup(),c,f=this.elements.length,d=f,e,i,m=this.elements[0].length,q;do{e=d-f;if(a.elements[e][e]==0)for(j=
e+1;j<d;j++)if(a.elements[j][e]!=0){c=[];i=m;do{q=m-i;c.push(a.elements[e][q]+a.elements[j][q])}while(--i);a.elements[e]=c;break}if(a.elements[e][e]!=0)for(j=e+1;j<d;j++){var o=a.elements[j][e]/a.elements[e][e];c=[];i=m;do{q=m-i;c.push(q<=e?0:a.elements[j][q]-a.elements[e][q]*o)}while(--i);a.elements[j]=c}}while(--f);return a},toUpperTriangular:function(){return this.toRightTriangular()},determinant:function(){if(!this.isSquare())return null;var a=this.toRightTriangular(),c=a.elements[0][0],f=a.elements.length-
1,d=f,e;do{e=d-f+1;c*=a.elements[e][e]}while(--f);return c},det:function(){return this.determinant()},isSingular:function(){return this.isSquare()&&this.determinant()===0},trace:function(){if(!this.isSquare())return null;var a=this.elements[0][0],c=this.elements.length-1,f=c,d;do{d=f-c+1;a+=this.elements[d][d]}while(--c);return a},tr:function(){return this.trace()},rank:function(){var a=this.toRightTriangular(),c=0,f=this.elements.length,d=f,e,i,m=this.elements[0].length,q;do{e=d-f;i=m;do{q=m-i;if(Math.abs(a.elements[e][q])>
Sylvester.precision){c++;break}}while(--i)}while(--f);return c},rk:function(){return this.rank()},augment:function(a){a=a.elements||a;if(typeof a[0][0]=="undefined")a=Matrix.create(a).elements;var c=this.dup(),f=c.elements[0].length,d=c.elements.length,e=d,i,m,q=a[0].length,o;if(d!=a.length)return null;do{i=e-d;m=q;do{o=q-m;c.elements[i][f+o]=a[i][o]}while(--m)}while(--d);return c},inverse:function(){if(!this.isSquare()||this.isSingular())return null;var a=this.elements.length,c=a,f,d,e=this.augment(Matrix.I(a)).toRightTriangular(),
i,m=e.elements[0].length,q,o,s=[],C;do{f=a-1;o=[];i=m;s[f]=[];d=e.elements[f][f];do{q=m-i;C=e.elements[f][q]/d;o.push(C);q>=c&&s[f].push(C)}while(--i);e.elements[f]=o;for(d=0;d<f;d++){o=[];i=m;do{q=m-i;o.push(e.elements[d][q]-e.elements[f][q]*e.elements[d][f])}while(--i);e.elements[d]=o}}while(--a);return Matrix.create(s)},inv:function(){return this.inverse()},round:function(){return this.map(function(a){return Math.round(a)})},snapTo:function(a){return this.map(function(c){return Math.abs(c-a)<=
Sylvester.precision?a:c})},inspect:function(){var a=[],c=this.elements.length,f=c,d;do{d=f-c;a.push(Vector.create(this.elements[d]).inspect())}while(--c);return a.join("\n")},setElements:function(a){var c=a.elements||a;if(typeof c[0][0]!="undefined"){var f=c.length,d=f,e,i,m;this.elements=[];do{a=d-f;i=e=c[a].length;this.elements[a]=[];do{m=i-e;this.elements[a][m]=c[a][m]}while(--e)}while(--f);return this}d=f=c.length;this.elements=[];do{a=d-f;this.elements.push([c[a]])}while(--f);return this}};
Matrix.create=function(a){return(new Matrix).setElements(a)};Matrix.I=function(a){var c=[],f=a,d,e,i;do{d=f-a;c[d]=[];e=f;do{i=f-e;c[d][i]=d==i?1:0}while(--e)}while(--a);return Matrix.create(c)};Matrix.Diagonal=function(a){var c=a.length,f=c,d,e=Matrix.I(c);do{d=f-c;e.elements[d][d]=a[d]}while(--c);return e};
Matrix.Rotation=function(a,c){if(!c)return Matrix.create([[Math.cos(a),-Math.sin(a)],[Math.sin(a),Math.cos(a)]]);var f=c.dup();if(f.elements.length!=3)return null;var d=f.modulus();c=f.elements[0]/d;var e=f.elements[1]/d;f=f.elements[2]/d;d=Math.sin(a);a=Math.cos(a);var i=1-a;return Matrix.create([[i*c*c+a,i*c*e-d*f,i*c*f+d*e],[i*c*e+d*f,i*e*e+a,i*e*f-d*c],[i*c*f-d*e,i*e*f+d*c,i*f*f+a]])};Matrix.RotationX=function(a){var c=Math.cos(a);a=Math.sin(a);return Matrix.create([[1,0,0],[0,c,-a],[0,a,c]])};
Matrix.RotationY=function(a){var c=Math.cos(a);a=Math.sin(a);return Matrix.create([[c,0,a],[0,1,0],[-a,0,c]])};Matrix.RotationZ=function(a){var c=Math.cos(a);a=Math.sin(a);return Matrix.create([[c,-a,0],[a,c,0],[0,0,1]])};Matrix.Random=function(a,c){return Matrix.Zero(a,c).map(function(){return Math.random()})};Matrix.Zero=function(a,c){var f=[],d=a,e,i,m;do{e=a-d;f[e]=[];i=c;do{m=c-i;f[e][m]=0}while(--i)}while(--d);return Matrix.create(f)};function Line(){}
Line.prototype={eql:function(a){return this.isParallelTo(a)&&this.contains(a.anchor)},dup:function(){return Line.create(this.anchor,this.direction)},translate:function(a){a=a.elements||a;return Line.create([this.anchor.elements[0]+a[0],this.anchor.elements[1]+a[1],this.anchor.elements[2]+(a[2]||0)],this.direction)},isParallelTo:function(a){if(a.normal)return a.isParallelTo(this);a=this.direction.angleFrom(a.direction);return Math.abs(a)<=Sylvester.precision||Math.abs(a-Math.PI)<=Sylvester.precision},
distanceFrom:function(a){if(a.normal)return a.distanceFrom(this);if(a.direction){if(this.isParallelTo(a))return this.distanceFrom(a.anchor);var c=this.direction.cross(a.direction).toUnitVector().elements,f=this.anchor.elements;a=a.anchor.elements;return Math.abs((f[0]-a[0])*c[0]+(f[1]-a[1])*c[1]+(f[2]-a[2])*c[2])}else{var d=a.elements||a;f=this.anchor.elements;c=this.direction.elements;a=d[0]-f[0];var e=d[1]-f[1];d=(d[2]||0)-f[2];f=Math.sqrt(a*a+e*e+d*d);if(f===0)return 0;c=(a*c[0]+e*c[1]+d*c[2])/
f;c=1-c*c;return Math.abs(f*Math.sqrt(c<0?0:c))}},contains:function(a){a=this.distanceFrom(a);return a!==null&&a<=Sylvester.precision},liesIn:function(a){return a.contains(this)},intersects:function(a){if(a.normal)return a.intersects(this);return!this.isParallelTo(a)&&this.distanceFrom(a)<=Sylvester.precision},intersectionWith:function(a){if(a.normal)return a.intersectionWith(this);if(!this.intersects(a))return null;var c=this.anchor.elements,f=this.direction.elements,d=a.anchor.elements,e=a.direction.elements;
a=f[0];var i=f[1];f=f[2];var m=e[0],q=e[1];e=e[2];var o=c[0]-d[0],s=c[1]-d[1];d=c[2]-d[2];var C=m*m+q*q+e*e,z=a*m+i*q+f*e;m=((-a*o-i*s-f*d)*C/(a*a+i*i+f*f)+z*(m*o+q*s+e*d))/(C-z*z);return Vector.create([c[0]+m*a,c[1]+m*i,c[2]+m*f])},pointClosestTo:function(a){if(a.direction){if(this.intersects(a))return this.intersectionWith(a);if(this.isParallelTo(a))return null;var c=this.direction.elements,f=a.direction.elements,d=c[0],e=c[1];c=c[2];var i=f[0],m=f[1],q=f[2];f=c*i-d*q;var o=d*m-e*i,s=e*q-c*m;d=
Vector.create([f*q-o*m,o*i-s*q,s*m-f*i]);a=Plane.create(a.anchor,d);return a.intersectionWith(this)}else{a=a.elements||a;if(this.contains(a))return Vector.create(a);f=this.anchor.elements;c=this.direction.elements;d=c[0];e=c[1];c=c[2];i=f[0];o=f[1];m=f[2];f=d*(a[1]-o)-e*(a[0]-i);o=e*((a[2]||0)-m)-c*(a[1]-o);s=c*(a[0]-i)-d*((a[2]||0)-m);d=Vector.create([e*f-c*s,c*o-d*f,d*s-e*o]);e=this.distanceFrom(a)/d.modulus();return Vector.create([a[0]+d.elements[0]*e,a[1]+d.elements[1]*e,(a[2]||0)+d.elements[2]*
e])}},rotate:function(a,c){if(typeof c.direction=="undefined")c=Line.create(c.to3D(),Vector.k);a=Matrix.Rotation(a,c.direction).elements;var f=c.pointClosestTo(this.anchor).elements,d=this.anchor.elements;c=this.direction.elements;var e=f[0],i=f[1];f=f[2];var m=d[0]-e,q=d[1]-i;d=d[2]-f;return Line.create([e+a[0][0]*m+a[0][1]*q+a[0][2]*d,i+a[1][0]*m+a[1][1]*q+a[1][2]*d,f+a[2][0]*m+a[2][1]*q+a[2][2]*d],[a[0][0]*c[0]+a[0][1]*c[1]+a[0][2]*c[2],a[1][0]*c[0]+a[1][1]*c[1]+a[1][2]*c[2],a[2][0]*c[0]+a[2][1]*
c[1]+a[2][2]*c[2]])},reflectionIn:function(a){if(a.normal){var c=this.anchor.elements,f=this.direction.elements,d=c[0],e=c[1];c=c[2];var i=f[0],m=f[1],q=f[2];f=this.anchor.reflectionIn(a).elements;d=d+i;e=e+m;c=c+q;a=a.pointClosestTo([d,e,c]).elements;return Line.create(f,[a[0]+(a[0]-d)-f[0],a[1]+(a[1]-e)-f[1],a[2]+(a[2]-c)-f[2]])}else if(a.direction)return this.rotate(Math.PI,a);else{a=a.elements||a;return Line.create(this.anchor.reflectionIn([a[0],a[1],a[2]||0]),this.direction)}},setVectors:function(a,
c){a=Vector.create(a);c=Vector.create(c);a.elements.length==2&&a.elements.push(0);c.elements.length==2&&c.elements.push(0);if(a.elements.length>3||c.elements.length>3)return null;var f=c.modulus();if(f===0)return null;this.anchor=a;this.direction=Vector.create([c.elements[0]/f,c.elements[1]/f,c.elements[2]/f]);return this}};Line.create=function(a,c){return(new Line).setVectors(a,c)};Line.X=Line.create(Vector.Zero(3),Vector.i);Line.Y=Line.create(Vector.Zero(3),Vector.j);
Line.Z=Line.create(Vector.Zero(3),Vector.k);function Plane(){}
Plane.prototype={eql:function(a){return this.contains(a.anchor)&&this.isParallelTo(a)},dup:function(){return Plane.create(this.anchor,this.normal)},translate:function(a){a=a.elements||a;return Plane.create([this.anchor.elements[0]+a[0],this.anchor.elements[1]+a[1],this.anchor.elements[2]+(a[2]||0)],this.normal)},isParallelTo:function(a){if(a.normal){a=this.normal.angleFrom(a.normal);return Math.abs(a)<=Sylvester.precision||Math.abs(Math.PI-a)<=Sylvester.precision}else if(a.direction)return this.normal.isPerpendicularTo(a.direction);
return null},isPerpendicularTo:function(a){a=this.normal.angleFrom(a.normal);return Math.abs(Math.PI/2-a)<=Sylvester.precision},distanceFrom:function(a){if(this.intersects(a)||this.contains(a))return 0;if(a.anchor){var c=this.anchor.elements,f=a.anchor.elements;a=this.normal.elements;return Math.abs((c[0]-f[0])*a[0]+(c[1]-f[1])*a[1]+(c[2]-f[2])*a[2])}else{f=a.elements||a;c=this.anchor.elements;a=this.normal.elements;return Math.abs((c[0]-f[0])*a[0]+(c[1]-f[1])*a[1]+(c[2]-(f[2]||0))*a[2])}},contains:function(a){if(a.normal)return null;
if(a.direction)return this.contains(a.anchor)&&this.contains(a.anchor.add(a.direction));else{a=a.elements||a;var c=this.anchor.elements,f=this.normal.elements;return Math.abs(f[0]*(c[0]-a[0])+f[1]*(c[1]-a[1])+f[2]*(c[2]-(a[2]||0)))<=Sylvester.precision}},intersects:function(a){if(typeof a.direction=="undefined"&&typeof a.normal=="undefined")return null;return!this.isParallelTo(a)},intersectionWith:function(a){if(!this.intersects(a))return null;if(a.direction){var c=a.anchor.elements,f=a.direction.elements;
a=this.anchor.elements;var d=this.normal.elements;a=(d[0]*(a[0]-c[0])+d[1]*(a[1]-c[1])+d[2]*(a[2]-c[2]))/(d[0]*f[0]+d[1]*f[1]+d[2]*f[2]);return Vector.create([c[0]+f[0]*a,c[1]+f[1]*a,c[2]+f[2]*a])}else if(a.normal){f=this.normal.cross(a.normal).toUnitVector();d=this.normal.elements;c=this.anchor.elements;var e=a.normal.elements,i=a.anchor.elements,m=Matrix.Zero(2,2);for(a=0;m.isSingular();){a++;m=Matrix.create([[d[a%3],d[(a+1)%3]],[e[a%3],e[(a+1)%3]]])}m=m.inverse().elements;c=d[0]*c[0]+d[1]*c[1]+
d[2]*c[2];d=e[0]*i[0]+e[1]*i[1]+e[2]*i[2];c=[m[0][0]*c+m[0][1]*d,m[1][0]*c+m[1][1]*d];d=[];for(e=1;e<=3;e++)d.push(a==e?0:c[(e+(5-a)%3)%3]);return Line.create(d,f)}},pointClosestTo:function(a){a=a.elements||a;var c=this.anchor.elements,f=this.normal.elements;c=(c[0]-a[0])*f[0]+(c[1]-a[1])*f[1]+(c[2]-(a[2]||0))*f[2];return Vector.create([a[0]+f[0]*c,a[1]+f[1]*c,(a[2]||0)+f[2]*c])},rotate:function(a,c){a=Matrix.Rotation(a,c.direction).elements;var f=c.pointClosestTo(this.anchor).elements,d=this.anchor.elements;
c=this.normal.elements;var e=f[0],i=f[1];f=f[2];var m=d[0]-e,q=d[1]-i;d=d[2]-f;return Plane.create([e+a[0][0]*m+a[0][1]*q+a[0][2]*d,i+a[1][0]*m+a[1][1]*q+a[1][2]*d,f+a[2][0]*m+a[2][1]*q+a[2][2]*d],[a[0][0]*c[0]+a[0][1]*c[1]+a[0][2]*c[2],a[1][0]*c[0]+a[1][1]*c[1]+a[1][2]*c[2],a[2][0]*c[0]+a[2][1]*c[1]+a[2][2]*c[2]])},reflectionIn:function(a){if(a.normal){var c=this.anchor.elements,f=this.normal.elements,d=c[0],e=c[1];c=c[2];var i=f[0],m=f[1],q=f[2];f=this.anchor.reflectionIn(a).elements;d=d+i;e=e+
m;c=c+q;a=a.pointClosestTo([d,e,c]).elements;return Plane.create(f,[a[0]+(a[0]-d)-f[0],a[1]+(a[1]-e)-f[1],a[2]+(a[2]-c)-f[2]])}else if(a.direction)return this.rotate(Math.PI,a);else{a=a.elements||a;return Plane.create(this.anchor.reflectionIn([a[0],a[1],a[2]||0]),this.normal)}},setVectors:function(a,c,f){a=Vector.create(a);a=a.to3D();if(a===null)return null;c=Vector.create(c);c=c.to3D();if(c===null)return null;if(typeof f=="undefined")f=null;else{f=Vector.create(f);f=f.to3D();if(f===null)return null}var d=
a.elements[0],e=a.elements[1],i=a.elements[2],m=c.elements[0],q=c.elements[1],o=c.elements[2];if(f!==null){c=f.elements[0];var s=f.elements[1];f=f.elements[2];e=Vector.create([(q-e)*(f-i)-(o-i)*(s-e),(o-i)*(c-d)-(m-d)*(f-i),(m-d)*(s-e)-(q-e)*(c-d)]);d=e.modulus();if(d===0)return null;e=Vector.create([e.elements[0]/d,e.elements[1]/d,e.elements[2]/d])}else{d=Math.sqrt(m*m+q*q+o*o);if(d===0)return null;e=Vector.create([c.elements[0]/d,c.elements[1]/d,c.elements[2]/d])}this.anchor=a;this.normal=e;return this}};
Plane.create=function(a,c,f){return(new Plane).setVectors(a,c,f)};Plane.XY=Plane.create(Vector.Zero(3),Vector.k);Plane.YZ=Plane.create(Vector.Zero(3),Vector.i);Plane.ZX=Plane.create(Vector.Zero(3),Vector.j);Plane.YX=Plane.XY;Plane.ZY=Plane.YZ;Plane.XZ=Plane.ZX;var $V=Vector.create,$M=Matrix.create,$L=Line.create,$P=Plane.create;
(function(){function a(b,h){h.src?g.ajax({url:h.src,async:false,dataType:"script"}):g.globalEval(h.text||h.textContent||h.innerHTML||"");h.parentNode&&h.parentNode.removeChild(h)}function c(){return+new Date}function f(b,h){return b[0]&&parseInt(g.curCSS(b[0],h,true),10)||0}function d(){return false}function e(){return true}function i(b){var h=RegExp("(^|\\.)"+b.type+"(\\.|$)"),k=true,n=[];g.each(g.data(this,"events").live||[],function(r,v){if(h.test(v.type))(r=g(b.target).closest(v.data)[0])&&n.push({elem:r,
fn:v})});n.sort(function(r,v){return g.data(r.elem,"closest")-g.data(v.elem,"closest")});g.each(n,function(){if(this.fn.call(this.elem,b,this.fn.data)===false)return k=false});return k}function m(b,h){return["live",b,h.replace(/\./g,"`").replace(/ /g,"|")].join(".")}function q(){if(!Y){Y=true;if(document.addEventListener)document.addEventListener("DOMContentLoaded",function(){document.removeEventListener("DOMContentLoaded",arguments.callee,false);g.ready()},false);else if(document.attachEvent){document.attachEvent("onreadystatechange",
function(){if(document.readyState==="complete"){document.detachEvent("onreadystatechange",arguments.callee);g.ready()}});document.documentElement.doScroll&&s==s.top&&function(){if(!g.isReady){try{document.documentElement.doScroll("left")}catch(b){setTimeout(arguments.callee,0);return}g.ready()}}()}g.event.add(s,"load",g.ready)}}function o(b,h){var k={};g.each(ha.concat.apply([],ha.slice(0,h)),function(){k[this]=b});return k}var s=this,C=s.jQuery,z=s.$,g=s.jQuery=s.$=function(b,h){return new g.fn.init(b,
h)},A=/^[^<]*(<(.|\s)+>)[^>]*$|^#([\w-]+)$/,y=/^.[^:#\[\.,]*$/;g.fn=g.prototype={init:function(b,h){b=b||document;if(b.nodeType){this[0]=b;this.length=1;this.context=b;return this}if(typeof b==="string"){var k=A.exec(b);if(k&&(k[1]||!h))if(k[1])b=g.clean([k[1]],h);else{if((h=document.getElementById(k[3]))&&h.id!=k[3])return g().find(b);k=g(h||[]);k.context=document;k.selector=b;return k}else return g(h).find(b)}else if(g.isFunction(b))return g(document).ready(b);if(b.selector&&b.context){this.selector=
b.selector;this.context=b.context}return this.setArray(g.isArray(b)?b:g.makeArray(b))},selector:"",jquery:"1.3.2",size:function(){return this.length},get:function(b){return b===void 0?Array.prototype.slice.call(this):this[b]},pushStack:function(b,h,k){b=g(b);b.prevObject=this;b.context=this.context;if(h==="find")b.selector=this.selector+(this.selector?" ":"")+k;else if(h)b.selector=this.selector+"."+h+"("+k+")";return b},setArray:function(b){this.length=0;Array.prototype.push.apply(this,b);return this},
each:function(b,h){return g.each(this,b,h)},index:function(b){return g.inArray(b&&b.jquery?b[0]:b,this)},attr:function(b,h,k){var n=b;if(typeof b==="string")if(h===void 0)return this[0]&&g[k||"attr"](this[0],b);else{n={};n[b]=h}return this.each(function(r){for(b in n)g.attr(k?this.style:this,b,g.prop(this,n[b],k,r,b))})},css:function(b,h){if((b=="width"||b=="height")&&parseFloat(h)<0)h=void 0;return this.attr(b,h,"curCSS")},text:function(b){if(typeof b!=="object"&&b!=null)return this.empty().append((this[0]&&
this[0].ownerDocument||document).createTextNode(b));var h="";g.each(b||this,function(){g.each(this.childNodes,function(){if(this.nodeType!=8)h+=this.nodeType!=1?this.nodeValue:g.fn.text([this])})});return h},wrapAll:function(b){if(this[0]){b=g(b,this[0].ownerDocument).clone();this[0].parentNode&&b.insertBefore(this[0]);b.map(function(){for(var h=this;h.firstChild;)h=h.firstChild;return h}).append(this)}return this},wrapInner:function(b){return this.each(function(){g(this).contents().wrapAll(b)})},
wrap:function(b){return this.each(function(){g(this).wrapAll(b)})},append:function(){return this.domManip(arguments,true,function(b){this.nodeType==1&&this.appendChild(b)})},prepend:function(){return this.domManip(arguments,true,function(b){this.nodeType==1&&this.insertBefore(b,this.firstChild)})},before:function(){return this.domManip(arguments,false,function(b){this.parentNode.insertBefore(b,this)})},after:function(){return this.domManip(arguments,false,function(b){this.parentNode.insertBefore(b,
this.nextSibling)})},end:function(){return this.prevObject||g([])},push:[].push,sort:[].sort,splice:[].splice,find:function(b){if(this.length===1){var h=this.pushStack([],"find",b);h.length=0;g.find(b,this[0],h);return h}else return this.pushStack(g.unique(g.map(this,function(k){return g.find(b,k)})),"find",b)},clone:function(b){var h=this.map(function(){if(!g.support.noCloneEvent&&!g.isXMLDoc(this)){var r=this.outerHTML;if(!r){r=this.ownerDocument.createElement("div");r.appendChild(this.cloneNode(true));
r=r.innerHTML}return g.clean([r.replace(/ jQuery\d+="(?:\d+|null)"/g,"").replace(/^\s*/,"")])[0]}else return this.cloneNode(true)});if(b===true){var k=this.find("*").andSelf(),n=0;h.find("*").andSelf().each(function(){if(this.nodeName===k[n].nodeName){var r=g.data(k[n],"events");for(var v in r)for(var x in r[v])g.event.add(this,v,r[v][x],r[v][x].data);n++}})}return h},filter:function(b){return this.pushStack(g.isFunction(b)&&g.grep(this,function(h,k){return b.call(h,k)})||g.multiFilter(b,g.grep(this,
function(h){return h.nodeType===1})),"filter",b)},closest:function(b){var h=g.expr.match.POS.test(b)?g(b):null,k=0;return this.map(function(){for(var n=this;n&&n.ownerDocument;){if(h?h.index(n)>-1:g(n).is(b)){g.data(n,"closest",k);return n}n=n.parentNode;k++}})},not:function(b){if(typeof b==="string")if(y.test(b))return this.pushStack(g.multiFilter(b,this,true),"not",b);else b=g.multiFilter(b,this);var h=b.length&&b[b.length-1]!==void 0&&!b.nodeType;return this.filter(function(){return h?g.inArray(this,
b)<0:this!=b})},add:function(b){return this.pushStack(g.unique(g.merge(this.get(),typeof b==="string"?g(b):g.makeArray(b))))},is:function(b){return!!b&&g.multiFilter(b,this).length>0},hasClass:function(b){return!!b&&this.is("."+b)},val:function(b){if(b===void 0){var h=this[0];if(h){if(g.nodeName(h,"option"))return(h.attributes.value||{}).specified?h.value:h.text;if(g.nodeName(h,"select")){var k=h.selectedIndex,n=[],r=h.options;h=h.type=="select-one";if(k<0)return null;var v=h?k:0;for(k=h?k+1:r.length;v<
k;v++){var x=r[v];if(x.selected){b=g(x).val();if(h)return b;n.push(b)}}return n}return(h.value||"").replace(/\r/g,"")}}else{if(typeof b==="number")b+="";return this.each(function(){if(this.nodeType==1)if(g.isArray(b)&&/radio|checkbox/.test(this.type))this.checked=g.inArray(this.value,b)>=0||g.inArray(this.name,b)>=0;else if(g.nodeName(this,"select")){var B=g.makeArray(b);g("option",this).each(function(){this.selected=g.inArray(this.value,B)>=0||g.inArray(this.text,B)>=0});if(!B.length)this.selectedIndex=
-1}else this.value=b})}},html:function(b){return b===void 0?this[0]?this[0].innerHTML.replace(/ jQuery\d+="(?:\d+|null)"/g,""):null:this.empty().append(b)},replaceWith:function(b){return this.after(b).remove()},eq:function(b){return this.slice(b,+b+1)},slice:function(){return this.pushStack(Array.prototype.slice.apply(this,arguments),"slice",Array.prototype.slice.call(arguments).join(","))},map:function(b){return this.pushStack(g.map(this,function(h,k){return b.call(h,k,h)}))},andSelf:function(){return this.add(this.prevObject)},
domManip:function(b,h,k){function n(K,O){return h&&g.nodeName(K,"table")&&g.nodeName(O,"tr")?K.getElementsByTagName("tbody")[0]||K.appendChild(K.ownerDocument.createElement("tbody")):K}if(this[0]){var r=(this[0].ownerDocument||this[0]).createDocumentFragment();b=g.clean(b,this[0].ownerDocument||this[0],r);var v=r.firstChild;if(v)for(var x=0,B=this.length;x<B;x++)k.call(n(this[x],v),this.length>1||x>0?r.cloneNode(true):r);b&&g.each(b,a)}return this}};g.fn.init.prototype=g.fn;g.extend=g.fn.extend=function(){var b=
arguments[0]||{},h=1,k=arguments.length,n=false,r;if(typeof b==="boolean"){n=b;b=arguments[1]||{};h=2}if(typeof b!=="object"&&!g.isFunction(b))b={};if(k==h){b=this;--h}for(;h<k;h++)if((r=arguments[h])!=null)for(var v in r){var x=b[v],B=r[v];if(b!==B)if(n&&B&&typeof B==="object"&&!B.nodeType)b[v]=g.extend(n,x||(B.length!=null?[]:{}),B);else if(B!==void 0)b[v]=B}return b};var F=/z-?index|font-?weight|opacity|zoom|line-?height/i,L=document.defaultView||{},Q=Object.prototype.toString;g.extend({noConflict:function(b){s.$=
z;if(b)s.jQuery=C;return g},isFunction:function(b){return Q.call(b)==="[object Function]"},isArray:function(b){return Q.call(b)==="[object Array]"},isXMLDoc:function(b){return b.nodeType===9&&b.documentElement.nodeName!=="HTML"||!!b.ownerDocument&&g.isXMLDoc(b.ownerDocument)},globalEval:function(b){if(b&&/\S/.test(b)){var h=document.getElementsByTagName("head")[0]||document.documentElement,k=document.createElement("script");k.type="text/javascript";if(g.support.scriptEval)k.appendChild(document.createTextNode(b));
else k.text=b;h.insertBefore(k,h.firstChild);h.removeChild(k)}},nodeName:function(b,h){return b.nodeName&&b.nodeName.toUpperCase()==h.toUpperCase()},each:function(b,h,k){var n,r=0,v=b.length;if(k)if(v===void 0)for(n in b){if(h.apply(b[n],k)===false)break}else for(;r<v;){if(h.apply(b[r++],k)===false)break}else if(v===void 0)for(n in b){if(h.call(b[n],n,b[n])===false)break}else for(k=b[0];r<v&&h.call(k,r,k)!==false;k=b[++r]);return b},prop:function(b,h,k,n,r){if(g.isFunction(h))h=h.call(b,n);return typeof h===
"number"&&k=="curCSS"&&!F.test(r)?h+"px":h},className:{add:function(b,h){g.each((h||"").split(/\s+/),function(k,n){if(b.nodeType==1&&!g.className.has(b.className,n))b.className+=(b.className?" ":"")+n})},remove:function(b,h){if(b.nodeType==1)b.className=h!==void 0?g.grep(b.className.split(/\s+/),function(k){return!g.className.has(h,k)}).join(" "):""},has:function(b,h){return b&&g.inArray(h,(b.className||b).toString().split(/\s+/))>-1}},swap:function(b,h,k){var n={};for(var r in h){n[r]=b.style[r];
b.style[r]=h[r]}k.call(b);for(r in h)b.style[r]=n[r]},css:function(b,h,k,n){if(h=="width"||h=="height"){var r;k={position:"absolute",visibility:"hidden",display:"block"};var v=h=="width"?["Left","Right"]:["Top","Bottom"];function x(){r=h=="width"?b.offsetWidth:b.offsetHeight;n!=="border"&&g.each(v,function(){n||(r-=parseFloat(g.curCSS(b,"padding"+this,true))||0);if(n==="margin")r+=parseFloat(g.curCSS(b,"margin"+this,true))||0;else r-=parseFloat(g.curCSS(b,"border"+this+"Width",true))||0})}b.offsetWidth!==
0?x():g.swap(b,k,x);return Math.max(0,Math.round(r))}return g.curCSS(b,h,k)},curCSS:function(b,h,k){var n,r=b.style;if(h=="opacity"&&!g.support.opacity){n=g.attr(r,"opacity");return n==""?"1":n}if(h.match(/float/i))h=J;if(!k&&r&&r[h])n=r[h];else if(L.getComputedStyle){if(h.match(/float/i))h="float";h=h.replace(/([A-Z])/g,"-$1").toLowerCase();if(b=L.getComputedStyle(b,null))n=b.getPropertyValue(h);if(h=="opacity"&&n=="")n="1"}else if(b.currentStyle){n=h.replace(/\-(\w)/g,function(v,x){return x.toUpperCase()});
n=b.currentStyle[h]||b.currentStyle[n];if(!/^\d+(px)?$/i.test(n)&&/^\d/.test(n)){h=r.left;k=b.runtimeStyle.left;b.runtimeStyle.left=b.currentStyle.left;r.left=n||0;n=r.pixelLeft+"px";r.left=h;b.runtimeStyle.left=k}}return n},clean:function(b,h,k){h=h||document;if(typeof h.createElement==="undefined")h=h.ownerDocument||h[0]&&h[0].ownerDocument||document;if(!k&&b.length===1&&typeof b[0]==="string"){var n=/^<(\w+)\s*\/?>$/.exec(b[0]);if(n)return[h.createElement(n[1])]}var r=[];n=[];var v=h.createElement("div");
g.each(b,function(x,B){if(typeof B==="number")B+="";if(B){if(typeof B==="string"){B=B.replace(/(<(\w+)[^>]*?)\/>/g,function(M,S,U){return U.match(/^(abbr|br|col|img|input|link|meta|param|hr|area|embed)$/i)?M:S+"></"+U+">"});x=B.replace(/^\s+/,"").substring(0,10).toLowerCase();var K=!x.indexOf("<opt")&&[1,"<select multiple='multiple'>","</select>"]||!x.indexOf("<leg")&&[1,"<fieldset>","</fieldset>"]||x.match(/^<(thead|tbody|tfoot|colg|cap)/)&&[1,"<table>","</table>"]||!x.indexOf("<tr")&&[2,"<table><tbody>",
"</tbody></table>"]||(!x.indexOf("<td")||!x.indexOf("<th"))&&[3,"<table><tbody><tr>","</tr></tbody></table>"]||!x.indexOf("<col")&&[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"]||!g.support.htmlSerialize&&[1,"div<div>","</div>"]||[0,"",""];for(v.innerHTML=K[1]+B+K[2];K[0]--;)v=v.lastChild;if(!g.support.tbody){var O=/<tbody/i.test(B);x=!x.indexOf("<table")&&!O?v.firstChild&&v.firstChild.childNodes:K[1]=="<table>"&&!O?v.childNodes:[];for(K=x.length-1;K>=0;--K)g.nodeName(x[K],"tbody")&&
!x[K].childNodes.length&&x[K].parentNode.removeChild(x[K])}!g.support.leadingWhitespace&&/^\s/.test(B)&&v.insertBefore(h.createTextNode(B.match(/^\s*/)[0]),v.firstChild);B=g.makeArray(v.childNodes)}if(B.nodeType)r.push(B);else r=g.merge(r,B)}});if(k){for(b=0;r[b];b++)if(g.nodeName(r[b],"script")&&(!r[b].type||r[b].type.toLowerCase()==="text/javascript"))n.push(r[b].parentNode?r[b].parentNode.removeChild(r[b]):r[b]);else{r[b].nodeType===1&&r.splice.apply(r,[b+1,0].concat(g.makeArray(r[b].getElementsByTagName("script"))));
k.appendChild(r[b])}return n}return r},attr:function(b,h,k){if(!(!b||b.nodeType==3||b.nodeType==8)){var n=!g.isXMLDoc(b),r=k!==void 0;h=n&&g.props[h]||h;if(b.tagName){var v=/href|src|style/.test(h);if(h in b&&n&&!v){if(r){if(h=="type"&&g.nodeName(b,"input")&&b.parentNode)throw"type property can't be changed";b[h]=k}if(g.nodeName(b,"form")&&b.getAttributeNode(h))return b.getAttributeNode(h).nodeValue;if(h=="tabIndex")return(h=b.getAttributeNode("tabIndex"))&&h.specified?h.value:b.nodeName.match(/(button|input|object|select|textarea)/i)?
0:b.nodeName.match(/^(a|area)$/i)&&b.href?0:void 0;return b[h]}if(!g.support.style&&n&&h=="style")return g.attr(b.style,"cssText",k);r&&b.setAttribute(h,""+k);b=!g.support.hrefNormalized&&n&&v?b.getAttribute(h,2):b.getAttribute(h);return b===null?void 0:b}if(!g.support.opacity&&h=="opacity"){if(r){b.zoom=1;b.filter=(b.filter||"").replace(/alpha\([^)]*\)/,"")+(parseInt(k)+""=="NaN"?"":"alpha(opacity="+k*100+")")}return b.filter&&b.filter.indexOf("opacity=")>=0?parseFloat(b.filter.match(/opacity=([^)]*)/)[1])/
100+"":""}h=h.replace(/-([a-z])/ig,function(x,B){return B.toUpperCase()});if(r)b[h]=k;return b[h]}},trim:function(b){return(b||"").replace(/^\s+|\s+$/g,"")},makeArray:function(b){var h=[];if(b!=null){var k=b.length;if(k==null||typeof b==="string"||g.isFunction(b)||b.setInterval)h[0]=b;else for(;k;)h[--k]=b[k]}return h},inArray:function(b,h){for(var k=0,n=h.length;k<n;k++)if(h[k]===b)return k;return-1},merge:function(b,h){var k=0,n,r=b.length;if(g.support.getAll)for(;(n=h[k++])!=null;)b[r++]=n;else for(;(n=
h[k++])!=null;)if(n.nodeType!=8)b[r++]=n;return b},unique:function(b){var h=[],k={};try{for(var n=0,r=b.length;n<r;n++){var v=g.data(b[n]);if(!k[v]){k[v]=true;h.push(b[n])}}}catch(x){h=b}return h},grep:function(b,h,k){for(var n=[],r=0,v=b.length;r<v;r++)!k!=!h(b[r],r)&&n.push(b[r]);return n},map:function(b,h){for(var k=[],n=0,r=b.length;n<r;n++){var v=h(b[n],n);if(v!=null)k[k.length]=v}return k.concat.apply([],k)}});var P=navigator.userAgent.toLowerCase();g.browser={version:(P.match(/.+(?:rv|it|ra|ie)[\/: ]([\d.]+)/)||
[0,"0"])[1],safari:/webkit/.test(P),opera:/opera/.test(P),msie:/msie/.test(P)&&!/opera/.test(P),mozilla:/mozilla/.test(P)&&!/(compatible|webkit)/.test(P)};g.each({parent:function(b){return b.parentNode},parents:function(b){return g.dir(b,"parentNode")},next:function(b){return g.nth(b,2,"nextSibling")},prev:function(b){return g.nth(b,2,"previousSibling")},nextAll:function(b){return g.dir(b,"nextSibling")},prevAll:function(b){return g.dir(b,"previousSibling")},siblings:function(b){return g.sibling(b.parentNode.firstChild,
b)},children:function(b){return g.sibling(b.firstChild)},contents:function(b){return g.nodeName(b,"iframe")?b.contentDocument||b.contentWindow.document:g.makeArray(b.childNodes)}},function(b,h){g.fn[b]=function(k){var n=g.map(this,h);if(k&&typeof k=="string")n=g.multiFilter(k,n);return this.pushStack(g.unique(n),b,k)}});g.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(b,h){g.fn[b]=function(k){for(var n=[],r=g(k),v=0,x=r.length;v<
x;v++){var B=(v>0?this.clone(true):this).get();g.fn[h].apply(g(r[v]),B);n=n.concat(B)}return this.pushStack(n,b,k)}});g.each({removeAttr:function(b){g.attr(this,b,"");this.nodeType==1&&this.removeAttribute(b)},addClass:function(b){g.className.add(this,b)},removeClass:function(b){g.className.remove(this,b)},toggleClass:function(b,h){if(typeof h!=="boolean")h=!g.className.has(this,b);g.className[h?"add":"remove"](this,b)},remove:function(b){if(!b||g.filter(b,[this]).length){g("*",this).add([this]).each(function(){g.event.remove(this);
g.removeData(this)});this.parentNode&&this.parentNode.removeChild(this)}},empty:function(){for(g(this).children().remove();this.firstChild;)this.removeChild(this.firstChild)}},function(b,h){g.fn[b]=function(){return this.each(h,arguments)}});var N="jQuery"+c(),da=0,ea={};g.extend({cache:{},data:function(b,h,k){b=b==s?ea:b;var n=b[N];n||(n=b[N]=++da);if(h&&!g.cache[n])g.cache[n]={};if(k!==void 0)g.cache[n][h]=k;return h?g.cache[n][h]:n},removeData:function(b,h){b=b==s?ea:b;var k=b[N];if(h){if(g.cache[k]){delete g.cache[k][h];
h="";for(h in g.cache[k])break;h||g.removeData(b)}}else{try{delete b[N]}catch(n){b.removeAttribute&&b.removeAttribute(N)}delete g.cache[k]}},queue:function(b,h,k){if(b){h=(h||"fx")+"queue";var n=g.data(b,h);if(!n||g.isArray(k))n=g.data(b,h,g.makeArray(k));else k&&n.push(k)}return n},dequeue:function(b,h){var k=g.queue(b,h),n=k.shift();if(!h||h==="fx")n=k[0];n!==void 0&&n.call(b)}});g.fn.extend({data:function(b,h){var k=b.split(".");k[1]=k[1]?"."+k[1]:"";if(h===void 0){var n=this.triggerHandler("getData"+
k[1]+"!",[k[0]]);if(n===void 0&&this.length)n=g.data(this[0],b);return n===void 0&&k[1]?this.data(k[0]):n}else return this.trigger("setData"+k[1]+"!",[k[0],h]).each(function(){g.data(this,b,h)})},removeData:function(b){return this.each(function(){g.removeData(this,b)})},queue:function(b,h){if(typeof b!=="string"){h=b;b="fx"}if(h===void 0)return g.queue(this[0],b);return this.each(function(){var k=g.queue(this,b,h);b=="fx"&&k.length==1&&k[0].call(this)})},dequeue:function(b){return this.each(function(){g.dequeue(this,
b)})}});(function(){function b(l,p,u,w,D,E){D=l=="previousSibling"&&!E;for(var G=0,R=w.length;G<R;G++){var H=w[G];if(H){if(D&&H.nodeType===1){H.sizcache=u;H.sizset=G}H=H[l];for(var T=false;H;){if(H.sizcache===u){T=w[H.sizset];break}if(H.nodeType===1&&!E){H.sizcache=u;H.sizset=G}if(H.nodeName===p){T=H;break}H=H[l]}w[G]=T}}}function h(l,p,u,w,D,E){D=l=="previousSibling"&&!E;for(var G=0,R=w.length;G<R;G++){var H=w[G];if(H){if(D&&H.nodeType===1){H.sizcache=u;H.sizset=G}H=H[l];for(var T=false;H;){if(H.sizcache===
u){T=w[H.sizset];break}if(H.nodeType===1){if(!E){H.sizcache=u;H.sizset=G}if(typeof p!=="string"){if(H===p){T=true;break}}else if(v.filter(p,[H]).length>0){T=H;break}}H=H[l]}w[G]=T}}}var k=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^[\]]*\]|['"][^'"]*['"]|[^[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?/g,n=0,r=Object.prototype.toString,v=function(l,p,u,w){u=u||[];p=p||document;if(p.nodeType!==1&&p.nodeType!==9)return[];if(!l||typeof l!=="string")return u;var D=[],E,G,R,H=true;for(k.lastIndex=0;(E=
k.exec(l))!==null;){D.push(E[1]);if(E[2]){R=RegExp.rightContext;break}}if(D.length>1&&B.exec(l))if(D.length===2&&x.relative[D[0]])E=Z(D[0]+D[1],p);else for(E=x.relative[D[0]]?[p]:v(D.shift(),p);D.length;){l=D.shift();if(x.relative[l])l+=D.shift();E=Z(l,E)}else{E=w?{expr:D.pop(),set:O(w)}:v.find(D.pop(),D.length===1&&p.parentNode?p.parentNode:p,I(p));E=v.filter(E.expr,E.set);if(D.length>0)G=O(E);else H=false;for(;D.length;){var T=D.pop(),X=T;if(x.relative[T])X=D.pop();else T="";if(X==null)X=p;x.relative[T](G,
X,I(p))}}G||(G=E);if(!G)throw"Syntax error, unrecognized expression: "+(T||l);if(r.call(G)==="[object Array]")if(H)if(p.nodeType===1)for(l=0;G[l]!=null;l++){if(G[l]&&(G[l]===true||G[l].nodeType===1&&U(p,G[l])))u.push(E[l])}else for(l=0;G[l]!=null;l++)G[l]&&G[l].nodeType===1&&u.push(E[l]);else u.push.apply(u,G);else O(G,u);if(R){v(R,p,u,w);if(S){hasDuplicate=false;u.sort(S);if(hasDuplicate)for(l=1;l<u.length;l++)u[l]===u[l-1]&&u.splice(l--,1)}}return u};v.matches=function(l,p){return v(l,null,null,
p)};v.find=function(l,p,u){var w,D;if(!l)return[];for(var E=0,G=x.order.length;E<G;E++){var R=x.order[E];if(D=x.match[R].exec(l)){var H=RegExp.leftContext;if(H.substr(H.length-1)!=="\\"){D[1]=(D[1]||"").replace(/\\/g,"");w=x.find[R](D,p,u);if(w!=null){l=l.replace(x.match[R],"");break}}}}w||(w=p.getElementsByTagName("*"));return{set:w,expr:l}};v.filter=function(l,p,u,w){for(var D=l,E=[],G=p,R,H,T=p&&p[0]&&I(p[0]);l&&p.length;){for(var X in x.filter)if((R=x.match[X].exec(l))!=null){var ja=x.filter[X],
ba,fa;H=false;if(G==E)E=[];if(x.preFilter[X])if(R=x.preFilter[X](R,G,u,E,w,T)){if(R===true)continue}else H=ba=true;if(R)for(var ga=0;(fa=G[ga])!=null;ga++)if(fa){ba=ja(fa,R,ga,G);var ia=w^!!ba;if(u&&ba!=null)if(ia)H=true;else G[ga]=false;else if(ia){E.push(fa);H=true}}if(ba!==void 0){u||(G=E);l=l.replace(x.match[X],"");if(!H)return[];break}}if(l==D)if(H==null)throw"Syntax error, unrecognized expression: "+l;else break;D=l}return G};var x=v.selectors={order:["ID","NAME","TAG"],match:{ID:/#((?:[\w\u00c0-\uFFFF_-]|\\.)+)/,
CLASS:/\.((?:[\w\u00c0-\uFFFF_-]|\\.)+)/,NAME:/\[name=['"]*((?:[\w\u00c0-\uFFFF_-]|\\.)+)['"]*\]/,ATTR:/\[\s*((?:[\w\u00c0-\uFFFF_-]|\\.)+)\s*(?:(\S?=)\s*(['"]*)(.*?)\3|)\s*\]/,TAG:/^((?:[\w\u00c0-\uFFFF\*_-]|\\.)+)/,CHILD:/:(only|nth|last|first)-child(?:\((even|odd|[\dn+-]*)\))?/,POS:/:(nth|eq|gt|lt|first|last|even|odd)(?:\((\d*)\))?(?=[^-]|$)/,PSEUDO:/:((?:[\w\u00c0-\uFFFF_-]|\\.)+)(?:\((['"]*)((?:\([^\)]+\)|[^\2\(\)]*)+)\2\))?/},attrMap:{"class":"className","for":"htmlFor"},attrHandle:{href:function(l){return l.getAttribute("href")}},
relative:{"+":function(l,p,u){var w=typeof p==="string",D=w&&!/\W/.test(p);w=w&&!D;if(D&&!u)p=p.toUpperCase();u=0;D=l.length;for(var E;u<D;u++)if(E=l[u]){for(;(E=E.previousSibling)&&E.nodeType!==1;);l[u]=w||E&&E.nodeName===p?E||false:E===p}w&&v.filter(p,l,true)},">":function(l,p,u){var w=typeof p==="string";if(w&&!/\W/.test(p)){p=u?p:p.toUpperCase();u=0;for(var D=l.length;u<D;u++){var E=l[u];if(E){w=E.parentNode;l[u]=w.nodeName===p?w:false}}}else{u=0;for(D=l.length;u<D;u++)if(E=l[u])l[u]=w?E.parentNode:
E.parentNode===p;w&&v.filter(p,l,true)}},"":function(l,p,u){var w=n++,D=h;if(!p.match(/\W/)){var E=p=u?p:p.toUpperCase();D=b}D("parentNode",p,w,l,E,u)},"~":function(l,p,u){var w=n++,D=h;if(typeof p==="string"&&!p.match(/\W/)){var E=p=u?p:p.toUpperCase();D=b}D("previousSibling",p,w,l,E,u)}},find:{ID:function(l,p,u){if(typeof p.getElementById!=="undefined"&&!u)return(l=p.getElementById(l[1]))?[l]:[]},NAME:function(l,p){if(typeof p.getElementsByName!=="undefined"){var u=[];p=p.getElementsByName(l[1]);
for(var w=0,D=p.length;w<D;w++)p[w].getAttribute("name")===l[1]&&u.push(p[w]);return u.length===0?null:u}},TAG:function(l,p){return p.getElementsByTagName(l[1])}},preFilter:{CLASS:function(l,p,u,w,D,E){l=" "+l[1].replace(/\\/g,"")+" ";if(E)return l;E=0;for(var G;(G=p[E])!=null;E++)if(G)if(D^(G.className&&(" "+G.className+" ").indexOf(l)>=0))u||w.push(G);else if(u)p[E]=false;return false},ID:function(l){return l[1].replace(/\\/g,"")},TAG:function(l,p){for(var u=0;p[u]===false;u++);return p[u]&&I(p[u])?
l[1]:l[1].toUpperCase()},CHILD:function(l){if(l[1]=="nth"){var p=/(-?)(\d*)n((?:\+|-)?\d*)/.exec(l[2]=="even"&&"2n"||l[2]=="odd"&&"2n+1"||!/\D/.test(l[2])&&"0n+"+l[2]||l[2]);l[2]=p[1]+(p[2]||1)-0;l[3]=p[3]-0}l[0]=n++;return l},ATTR:function(l,p,u,w,D,E){p=l[1].replace(/\\/g,"");if(!E&&x.attrMap[p])l[1]=x.attrMap[p];if(l[2]==="~=")l[4]=" "+l[4]+" ";return l},PSEUDO:function(l,p,u,w,D){if(l[1]==="not")if(l[3].match(k).length>1||/^\w/.test(l[3]))l[3]=v(l[3],null,null,p);else{l=v.filter(l[3],p,u,true^
D);u||w.push.apply(w,l);return false}else if(x.match.POS.test(l[0])||x.match.CHILD.test(l[0]))return true;return l},POS:function(l){l.unshift(true);return l}},filters:{enabled:function(l){return l.disabled===false&&l.type!=="hidden"},disabled:function(l){return l.disabled===true},checked:function(l){return l.checked===true},selected:function(l){return l.selected===true},parent:function(l){return!!l.firstChild},empty:function(l){return!l.firstChild},has:function(l,p,u){return!!v(u[3],l).length},header:function(l){return/h\d/i.test(l.nodeName)},
text:function(l){return"text"===l.type},radio:function(l){return"radio"===l.type},checkbox:function(l){return"checkbox"===l.type},file:function(l){return"file"===l.type},password:function(l){return"password"===l.type},submit:function(l){return"submit"===l.type},image:function(l){return"image"===l.type},reset:function(l){return"reset"===l.type},button:function(l){return"button"===l.type||l.nodeName.toUpperCase()==="BUTTON"},input:function(l){return/input|select|textarea|button/i.test(l.nodeName)}},
setFilters:{first:function(l,p){return p===0},last:function(l,p,u,w){return p===w.length-1},even:function(l,p){return p%2===0},odd:function(l,p){return p%2===1},lt:function(l,p,u){return p<u[3]-0},gt:function(l,p,u){return p>u[3]-0},nth:function(l,p,u){return u[3]-0==p},eq:function(l,p,u){return u[3]-0==p}},filter:{PSEUDO:function(l,p,u,w){var D=p[1],E=x.filters[D];if(E)return E(l,u,p,w);else if(D==="contains")return(l.textContent||l.innerText||"").indexOf(p[3])>=0;else if(D==="not"){p=p[3];u=0;for(w=
p.length;u<w;u++)if(p[u]===l)return false;return true}},CHILD:function(l,p){var u=p[1],w=l;switch(u){case "only":case "first":for(;w=w.previousSibling;)if(w.nodeType===1)return false;if(u=="first")return true;w=l;case "last":for(;w=w.nextSibling;)if(w.nodeType===1)return false;return true;case "nth":u=p[2];var D=p[3];if(u==1&&D==0)return true;p=p[0];var E=l.parentNode;if(E&&(E.sizcache!==p||!l.nodeIndex)){var G=0;for(w=E.firstChild;w;w=w.nextSibling)if(w.nodeType===1)w.nodeIndex=++G;E.sizcache=p}l=
l.nodeIndex-D;return u==0?l==0:l%u==0&&l/u>=0}},ID:function(l,p){return l.nodeType===1&&l.getAttribute("id")===p},TAG:function(l,p){return p==="*"&&l.nodeType===1||l.nodeName===p},CLASS:function(l,p){return(" "+(l.className||l.getAttribute("class"))+" ").indexOf(p)>-1},ATTR:function(l,p){var u=p[1];l=x.attrHandle[u]?x.attrHandle[u](l):l[u]!=null?l[u]:l.getAttribute(u);u=l+"";var w=p[2];p=p[4];return l==null?w==="!=":w==="="?u===p:w==="*="?u.indexOf(p)>=0:w==="~="?(" "+u+" ").indexOf(p)>=0:!p?u&&l!==
false:w==="!="?u!=p:w==="^="?u.indexOf(p)===0:w==="$="?u.substr(u.length-p.length)===p:w==="|="?u===p||u.substr(0,p.length+1)===p+"-":false},POS:function(l,p,u,w){var D=x.setFilters[p[2]];if(D)return D(l,u,p,w)}}},B=x.match.POS;for(var K in x.match)x.match[K]=RegExp(x.match[K].source+/(?![^\[]*\])(?![^\(]*\))/.source);var O=function(l,p){l=Array.prototype.slice.call(l);if(p){p.push.apply(p,l);return p}return l};try{Array.prototype.slice.call(document.documentElement.childNodes)}catch(M){O=function(l,
p){p=p||[];if(r.call(l)==="[object Array]")Array.prototype.push.apply(p,l);else if(typeof l.length==="number")for(var u=0,w=l.length;u<w;u++)p.push(l[u]);else for(u=0;l[u];u++)p.push(l[u]);return p}}var S;if(document.documentElement.compareDocumentPosition)S=function(l,p){l=l.compareDocumentPosition(p)&4?-1:l===p?0:1;if(l===0)hasDuplicate=true;return l};else if("sourceIndex"in document.documentElement)S=function(l,p){l=l.sourceIndex-p.sourceIndex;if(l===0)hasDuplicate=true;return l};else if(document.createRange)S=
function(l,p){var u=l.ownerDocument.createRange(),w=p.ownerDocument.createRange();u.selectNode(l);u.collapse(true);w.selectNode(p);w.collapse(true);l=u.compareBoundaryPoints(Range.START_TO_END,w);if(l===0)hasDuplicate=true;return l};(function(){var l=document.createElement("form"),p="script"+(new Date).getTime();l.innerHTML="<input name='"+p+"'/>";var u=document.documentElement;u.insertBefore(l,u.firstChild);if(document.getElementById(p)){x.find.ID=function(w,D,E){if(typeof D.getElementById!=="undefined"&&
!E)return(D=D.getElementById(w[1]))?D.id===w[1]||typeof D.getAttributeNode!=="undefined"&&D.getAttributeNode("id").nodeValue===w[1]?[D]:void 0:[]};x.filter.ID=function(w,D){var E=typeof w.getAttributeNode!=="undefined"&&w.getAttributeNode("id");return w.nodeType===1&&E&&E.nodeValue===D}}u.removeChild(l)})();(function(){var l=document.createElement("div");l.appendChild(document.createComment(""));if(l.getElementsByTagName("*").length>0)x.find.TAG=function(p,u){u=u.getElementsByTagName(p[1]);if(p[1]===
"*"){p=[];for(var w=0;u[w];w++)u[w].nodeType===1&&p.push(u[w]);u=p}return u};l.innerHTML="<a href='#'></a>";if(l.firstChild&&typeof l.firstChild.getAttribute!=="undefined"&&l.firstChild.getAttribute("href")!=="#")x.attrHandle.href=function(p){return p.getAttribute("href",2)}})();document.querySelectorAll&&function(){var l=v,p=document.createElement("div");p.innerHTML="<p class='TEST'></p>";if(!(p.querySelectorAll&&p.querySelectorAll(".TEST").length===0)){v=function(u,w,D,E){w=w||document;if(!E&&w.nodeType===
9&&!I(w))try{return O(w.querySelectorAll(u),D)}catch(G){}return l(u,w,D,E)};v.find=l.find;v.filter=l.filter;v.selectors=l.selectors;v.matches=l.matches}}();document.getElementsByClassName&&document.documentElement.getElementsByClassName&&function(){var l=document.createElement("div");l.innerHTML="<div class='test e'></div><div class='test'></div>";if(l.getElementsByClassName("e").length!==0){l.lastChild.className="e";if(l.getElementsByClassName("e").length!==1){x.order.splice(1,0,"CLASS");x.find.CLASS=
function(p,u,w){if(typeof u.getElementsByClassName!=="undefined"&&!w)return u.getElementsByClassName(p[1])}}}}();var U=document.compareDocumentPosition?function(l,p){return l.compareDocumentPosition(p)&16}:function(l,p){return l!==p&&(l.contains?l.contains(p):true)},I=function(l){return l.nodeType===9&&l.documentElement.nodeName!=="HTML"||!!l.ownerDocument&&I(l.ownerDocument)},Z=function(l,p){var u=[],w="",D;for(p=p.nodeType?[p]:p;D=x.match.PSEUDO.exec(l);){w+=D[0];l=l.replace(x.match.PSEUDO,"")}l=
x.relative[l]?l+"*":l;D=0;for(var E=p.length;D<E;D++)v(l,p[D],u);return v.filter(w,u)};g.find=v;g.filter=v.filter;g.expr=v.selectors;g.expr[":"]=g.expr.filters;v.selectors.filters.hidden=function(l){return l.offsetWidth===0||l.offsetHeight===0};v.selectors.filters.visible=function(l){return l.offsetWidth>0||l.offsetHeight>0};v.selectors.filters.animated=function(l){return g.grep(g.timers,function(p){return l===p.elem}).length};g.multiFilter=function(l,p,u){if(u)l=":not("+l+")";return v.matches(l,
p)};g.dir=function(l,p){var u=[];for(l=l[p];l&&l!=document;){l.nodeType==1&&u.push(l);l=l[p]}return u};g.nth=function(l,p,u){p=p||1;for(var w=0;l;l=l[u])if(l.nodeType==1&&++w==p)break;return l};g.sibling=function(l,p){for(var u=[];l;l=l.nextSibling)l.nodeType==1&&l!=p&&u.push(l);return u}})();g.event={add:function(b,h,k,n){if(!(b.nodeType==3||b.nodeType==8)){if(b.setInterval&&b!=s)b=s;if(!k.guid)k.guid=this.guid++;if(n!==void 0){k=this.proxy(k);k.data=n}var r=g.data(b,"events")||g.data(b,"events",
{}),v=g.data(b,"handle")||g.data(b,"handle",function(){return typeof g!=="undefined"&&!g.event.triggered?g.event.handle.apply(arguments.callee.elem,arguments):void 0});v.elem=b;g.each(h.split(/\s+/),function(x,B){x=B.split(".");B=x.shift();k.type=x.slice().sort().join(".");var K=r[B];g.event.specialAll[B]&&g.event.specialAll[B].setup.call(b,n,x);if(!K){K=r[B]={};if(!g.event.special[B]||g.event.special[B].setup.call(b,n,x)===false)if(b.addEventListener)b.addEventListener(B,v,false);else b.attachEvent&&
b.attachEvent("on"+B,v)}K[k.guid]=k;g.event.global[B]=true});b=null}},guid:1,global:{},remove:function(b,h,k){if(!(b.nodeType==3||b.nodeType==8)){var n=g.data(b,"events"),r;if(n){if(h===void 0||typeof h==="string"&&h.charAt(0)==".")for(var v in n)this.remove(b,v+(h||""));else{if(h.type){k=h.handler;h=h.type}g.each(h.split(/\s+/),function(x,B){x=B.split(".");B=x.shift();var K=RegExp("(^|\\.)"+x.slice().sort().join(".*\\.")+"(\\.|$)");if(n[B]){if(k)delete n[B][k.guid];else for(var O in n[B])K.test(n[B][O].type)&&
delete n[B][O];g.event.specialAll[B]&&g.event.specialAll[B].teardown.call(b,x);for(r in n[B])break;if(!r){if(!g.event.special[B]||g.event.special[B].teardown.call(b,x)===false)if(b.removeEventListener)b.removeEventListener(B,g.data(b,"handle"),false);else b.detachEvent&&b.detachEvent("on"+B,g.data(b,"handle"));r=null;delete n[B]}}})}for(r in n)break;if(!r){if(h=g.data(b,"handle"))h.elem=null;g.removeData(b,"events");g.removeData(b,"handle")}}}},trigger:function(b,h,k,n){var r=b.type||b;if(!n){b=typeof b===
"object"?b[N]?b:g.extend(g.Event(r),b):g.Event(r);if(r.indexOf("!")>=0){b.type=r=r.slice(0,-1);b.exclusive=true}if(!k){b.stopPropagation();this.global[r]&&g.each(g.cache,function(){this.events&&this.events[r]&&g.event.trigger(b,h,this.handle.elem)})}if(!k||k.nodeType==3||k.nodeType==8)return;b.result=void 0;b.target=k;h=g.makeArray(h);h.unshift(b)}b.currentTarget=k;var v=g.data(k,"handle");v&&v.apply(k,h);if((!k[r]||g.nodeName(k,"a")&&r=="click")&&k["on"+r]&&k["on"+r].apply(k,h)===false)b.result=
false;if(!n&&k[r]&&!b.isDefaultPrevented()&&!(g.nodeName(k,"a")&&r=="click")){this.triggered=true;try{k[r]()}catch(x){}}this.triggered=false;if(!b.isPropagationStopped())(k=k.parentNode||k.ownerDocument)&&g.event.trigger(b,h,k,true)},handle:function(b){var h,k;b=arguments[0]=g.event.fix(b||s.event);b.currentTarget=this;k=b.type.split(".");b.type=k.shift();h=!k.length&&!b.exclusive;var n=RegExp("(^|\\.)"+k.slice().sort().join(".*\\.")+"(\\.|$)");k=(g.data(this,"events")||{})[b.type];for(var r in k){var v=
k[r];if(h||n.test(v.type)){b.handler=v;b.data=v.data;v=v.apply(this,arguments);if(v!==void 0){b.result=v;if(v===false){b.preventDefault();b.stopPropagation()}}if(b.isImmediatePropagationStopped())break}}},props:"altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode metaKey newValue originalTarget pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target toElement view wheelDelta which".split(" "),
fix:function(b){if(b[N])return b;var h=b;b=g.Event(h);for(var k=this.props.length,n;k;){n=this.props[--k];b[n]=h[n]}if(!b.target)b.target=b.srcElement||document;if(b.target.nodeType==3)b.target=b.target.parentNode;if(!b.relatedTarget&&b.fromElement)b.relatedTarget=b.fromElement==b.target?b.toElement:b.fromElement;if(b.pageX==null&&b.clientX!=null){h=document.documentElement;k=document.body;b.pageX=b.clientX+(h&&h.scrollLeft||k&&k.scrollLeft||0)-(h.clientLeft||0);b.pageY=b.clientY+(h&&h.scrollTop||
k&&k.scrollTop||0)-(h.clientTop||0)}if(!b.which&&(b.charCode||b.charCode===0?b.charCode:b.keyCode))b.which=b.charCode||b.keyCode;if(!b.metaKey&&b.ctrlKey)b.metaKey=b.ctrlKey;if(!b.which&&b.button)b.which=b.button&1?1:b.button&2?3:b.button&4?2:0;return b},proxy:function(b,h){h=h||function(){return b.apply(this,arguments)};h.guid=b.guid=b.guid||h.guid||this.guid++;return h},special:{ready:{setup:q,teardown:function(){}}},specialAll:{live:{setup:function(b,h){g.event.add(this,h[0],i)},teardown:function(b){if(b.length){var h=
0,k=RegExp("(^|\\.)"+b[0]+"(\\.|$)");g.each(g.data(this,"events").live||{},function(){k.test(this.type)&&h++});h<1&&g.event.remove(this,b[0],i)}}}}};g.Event=function(b){if(!this.preventDefault)return new g.Event(b);if(b&&b.type){this.originalEvent=b;this.type=b.type}else this.type=b;this.timeStamp=c();this[N]=true};g.Event.prototype={preventDefault:function(){this.isDefaultPrevented=e;var b=this.originalEvent;if(b){b.preventDefault&&b.preventDefault();b.returnValue=false}},stopPropagation:function(){this.isPropagationStopped=
e;var b=this.originalEvent;if(b){b.stopPropagation&&b.stopPropagation();b.cancelBubble=true}},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=e;this.stopPropagation()},isDefaultPrevented:d,isPropagationStopped:d,isImmediatePropagationStopped:d};var ca=function(b){for(var h=b.relatedTarget;h&&h!=this;)try{h=h.parentNode}catch(k){h=this}if(h!=this){b.type=b.data;g.event.handle.apply(this,arguments)}};g.each({mouseover:"mouseenter",mouseout:"mouseleave"},function(b,h){g.event.special[h]=
{setup:function(){g.event.add(this,b,ca,h)},teardown:function(){g.event.remove(this,b,ca)}}});g.fn.extend({bind:function(b,h,k){return b=="unload"?this.one(b,h,k):this.each(function(){g.event.add(this,b,k||h,k&&h)})},one:function(b,h,k){var n=g.event.proxy(k||h,function(r){g(this).unbind(r,n);return(k||h).apply(this,arguments)});return this.each(function(){g.event.add(this,b,n,k&&h)})},unbind:function(b,h){return this.each(function(){g.event.remove(this,b,h)})},trigger:function(b,h){return this.each(function(){g.event.trigger(b,
h,this)})},triggerHandler:function(b,h){if(this[0]){b=g.Event(b);b.preventDefault();b.stopPropagation();g.event.trigger(b,h,this[0]);return b.result}},toggle:function(b){for(var h=arguments,k=1;k<h.length;)g.event.proxy(b,h[k++]);return this.click(g.event.proxy(b,function(n){this.lastToggle=(this.lastToggle||0)%k;n.preventDefault();return h[this.lastToggle++].apply(this,arguments)||false}))},hover:function(b,h){return this.mouseenter(b).mouseleave(h)},ready:function(b){q();g.isReady?b.call(document,
g):g.readyList.push(b);return this},live:function(b,h){h=g.event.proxy(h);h.guid+=this.selector+b;g(document).bind(m(b,this.selector),this.selector,h);return this},die:function(b,h){g(document).unbind(m(b,this.selector),h?{guid:h.guid+this.selector+b}:null);return this}});g.extend({isReady:false,readyList:[],ready:function(){if(!g.isReady){g.isReady=true;if(g.readyList){g.each(g.readyList,function(){this.call(document,g)});g.readyList=null}g(document).triggerHandler("ready")}}});var Y=false;g.each("blur,focus,load,resize,scroll,unload,click,dblclick,mousedown,mouseup,mousemove,mouseover,mouseout,mouseenter,mouseleave,change,select,submit,keydown,keypress,keyup,error".split(","),
function(b,h){g.fn[h]=function(k){return k?this.bind(h,k):this.trigger(h)}});g(s).bind("unload",function(){for(var b in g.cache)b!=1&&g.cache[b].handle&&g.event.remove(g.cache[b].handle.elem)});(function(){g.support={};var b=document.documentElement,h=document.createElement("script"),k=document.createElement("div"),n="script"+(new Date).getTime();k.style.display="none";k.innerHTML='   <link/><table></table><a href="/a" style="color:red;float:left;opacity:.5;">a</a><select><option>text</option></select><object><param/></object>';
var r=k.getElementsByTagName("*"),v=k.getElementsByTagName("a")[0];if(!(!r||!r.length||!v)){g.support={leadingWhitespace:k.firstChild.nodeType==3,tbody:!k.getElementsByTagName("tbody").length,objectAll:!!k.getElementsByTagName("object")[0].getElementsByTagName("*").length,htmlSerialize:!!k.getElementsByTagName("link").length,style:/red/.test(v.getAttribute("style")),hrefNormalized:v.getAttribute("href")==="/a",opacity:v.style.opacity==="0.5",cssFloat:!!v.style.cssFloat,scriptEval:false,noCloneEvent:true,
boxModel:null};h.type="text/javascript";try{h.appendChild(document.createTextNode("window."+n+"=1;"))}catch(x){}b.insertBefore(h,b.firstChild);if(s[n]){g.support.scriptEval=true;delete s[n]}b.removeChild(h);if(k.attachEvent&&k.fireEvent){k.attachEvent("onclick",function(){g.support.noCloneEvent=false;k.detachEvent("onclick",arguments.callee)});k.cloneNode(true).fireEvent("onclick")}g(function(){var B=document.createElement("div");B.style.width=B.style.paddingLeft="1px";document.body.appendChild(B);
g.boxModel=g.support.boxModel=B.offsetWidth===2;document.body.removeChild(B).style.display="none"})}})();var J=g.support.cssFloat?"cssFloat":"styleFloat";g.props={"for":"htmlFor","class":"className","float":J,cssFloat:J,styleFloat:J,readonly:"readOnly",maxlength:"maxLength",cellspacing:"cellSpacing",rowspan:"rowSpan",tabindex:"tabIndex"};g.fn.extend({_load:g.fn.load,load:function(b,h,k){if(typeof b!=="string")return this._load(b);var n=b.indexOf(" ");if(n>=0){var r=b.slice(n,b.length);b=b.slice(0,
n)}n="GET";if(h)if(g.isFunction(h)){k=h;h=null}else if(typeof h==="object"){h=g.param(h);n="POST"}var v=this;g.ajax({url:b,type:n,dataType:"html",data:h,complete:function(x,B){if(B=="success"||B=="notmodified")v.html(r?g("<div/>").append(x.responseText.replace(/<script(.|\s)*?\/script>/g,"")).find(r):x.responseText);k&&v.each(k,[x.responseText,B,x])}});return this},serialize:function(){return g.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?
g.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||/select|textarea/i.test(this.nodeName)||/text|hidden|password|search/i.test(this.type))}).map(function(b,h){b=g(this).val();return b==null?null:g.isArray(b)?g.map(b,function(k){return{name:h.name,value:k}}):{name:h.name,value:b}}).get()}});g.each("ajaxStart,ajaxStop,ajaxComplete,ajaxError,ajaxSuccess,ajaxSend".split(","),function(b,h){g.fn[h]=function(k){return this.bind(h,k)}});var V=c();g.extend({get:function(b,
h,k,n){if(g.isFunction(h)){k=h;h=null}return g.ajax({type:"GET",url:b,data:h,success:k,dataType:n})},getScript:function(b,h){return g.get(b,null,h,"script")},getJSON:function(b,h,k){return g.get(b,h,k,"json")},post:function(b,h,k,n){if(g.isFunction(h)){k=h;h={}}return g.ajax({type:"POST",url:b,data:h,success:k,dataType:n})},ajaxSetup:function(b){g.extend(g.ajaxSettings,b)},ajaxSettings:{url:location.href,global:true,type:"GET",contentType:"application/x-www-form-urlencoded",processData:true,async:true,
xhr:function(){return s.ActiveXObject?new ActiveXObject("Microsoft.XMLHTTP"):new XMLHttpRequest},accepts:{xml:"application/xml, text/xml",html:"text/html",script:"text/javascript, application/javascript",json:"application/json, text/javascript",text:"text/plain",_default:"*/*"}},lastModified:{},ajax:function(b){function h(){b.success&&b.success(x,v);b.global&&g.event.trigger("ajaxSuccess",[I,b])}function k(){b.complete&&b.complete(I,v);b.global&&g.event.trigger("ajaxComplete",[I,b]);b.global&&!--g.active&&
g.event.trigger("ajaxStop")}b=g.extend(true,b,g.extend(true,{},g.ajaxSettings,b));var n,r=/=\?(&|$)/g,v,x,B=b.type.toUpperCase();if(b.data&&b.processData&&typeof b.data!=="string")b.data=g.param(b.data);if(b.dataType=="jsonp"){if(B=="GET")b.url.match(r)||(b.url+=(b.url.match(/\?/)?"&":"?")+(b.jsonp||"callback")+"=?");else if(!b.data||!b.data.match(r))b.data=(b.data?b.data+"&":"")+(b.jsonp||"callback")+"=?";b.dataType="json"}if(b.dataType=="json"&&(b.data&&b.data.match(r)||b.url.match(r))){n="jsonp"+
V++;if(b.data)b.data=(b.data+"").replace(r,"="+n+"$1");b.url=b.url.replace(r,"="+n+"$1");b.dataType="script";s[n]=function(w){x=w;h();k();s[n]=void 0;try{delete s[n]}catch(D){}O&&O.removeChild(M)}}if(b.dataType=="script"&&b.cache==null)b.cache=false;if(b.cache===false&&B=="GET"){r=c();var K=b.url.replace(/(\?|&)_=.*?(&|$)/,"$1_="+r+"$2");b.url=K+(K==b.url?(b.url.match(/\?/)?"&":"?")+"_="+r:"")}if(b.data&&B=="GET"){b.url+=(b.url.match(/\?/)?"&":"?")+b.data;b.data=null}b.global&&!g.active++&&g.event.trigger("ajaxStart");
r=/^(\w+:)?\/\/([^\/?#]+)/.exec(b.url);if(b.dataType=="script"&&B=="GET"&&r&&(r[1]&&r[1]!=location.protocol||r[2]!=location.host)){var O=document.getElementsByTagName("head")[0],M=document.createElement("script");M.src=b.url;if(b.scriptCharset)M.charset=b.scriptCharset;if(!n){var S=false;M.onload=M.onreadystatechange=function(){if(!S&&(!this.readyState||this.readyState=="loaded"||this.readyState=="complete")){S=true;h();k();M.onload=M.onreadystatechange=null;O.removeChild(M)}}}O.appendChild(M)}else{var U=
false,I=b.xhr();b.username?I.open(B,b.url,b.async,b.username,b.password):I.open(B,b.url,b.async);try{b.data&&I.setRequestHeader("Content-Type",b.contentType);if(b.ifModified)I.setRequestHeader("If-Modified-Since",g.lastModified[b.url]||"Thu, 01 Jan 1970 00:00:00 GMT");I.setRequestHeader("X-Requested-With","XMLHttpRequest");I.setRequestHeader("Accept",b.dataType&&b.accepts[b.dataType]?b.accepts[b.dataType]+", */*":b.accepts._default)}catch(Z){}if(b.beforeSend&&b.beforeSend(I,b)===false){b.global&&
!--g.active&&g.event.trigger("ajaxStop");I.abort();return false}b.global&&g.event.trigger("ajaxSend",[I,b]);var l=function(w){if(I.readyState==0){if(p){clearInterval(p);p=null;b.global&&!--g.active&&g.event.trigger("ajaxStop")}}else if(!U&&I&&(I.readyState==4||w=="timeout")){U=true;if(p){clearInterval(p);p=null}v=w=="timeout"?"timeout":!g.httpSuccess(I)?"error":b.ifModified&&g.httpNotModified(I,b.url)?"notmodified":"success";if(v=="success")try{x=g.httpData(I,b.dataType,b)}catch(D){v="parsererror"}if(v==
"success"){var E;try{E=I.getResponseHeader("Last-Modified")}catch(G){}if(b.ifModified&&E)g.lastModified[b.url]=E;n||h()}else g.handleError(b,I,v);k();w&&I.abort();if(b.async)I=null}};if(b.async){var p=setInterval(l,13);b.timeout>0&&setTimeout(function(){I&&!U&&l("timeout")},b.timeout)}try{I.send(b.data)}catch(u){g.handleError(b,I,null,u)}b.async||l();return I}},handleError:function(b,h,k,n){b.error&&b.error(h,k,n);b.global&&g.event.trigger("ajaxError",[h,b,n])},active:0,httpSuccess:function(b){try{return!b.status&&
location.protocol=="file:"||b.status>=200&&b.status<300||b.status==304||b.status==1223}catch(h){}return false},httpNotModified:function(b,h){try{var k=b.getResponseHeader("Last-Modified");return b.status==304||k==g.lastModified[h]}catch(n){}return false},httpData:function(b,h,k){var n=b.getResponseHeader("content-type");b=(n=h=="xml"||!h&&n&&n.indexOf("xml")>=0)?b.responseXML:b.responseText;if(n&&b.documentElement.tagName=="parsererror")throw"parsererror";if(k&&k.dataFilter)b=k.dataFilter(b,h);if(typeof b===
"string"){h=="script"&&g.globalEval(b);if(h=="json")b=s.eval("("+b+")")}return b},param:function(b){function h(r,v){k[k.length]=encodeURIComponent(r)+"="+encodeURIComponent(v)}var k=[];if(g.isArray(b)||b.jquery)g.each(b,function(){h(this.name,this.value)});else for(var n in b)g.isArray(b[n])?g.each(b[n],function(){h(n,this)}):h(n,g.isFunction(b[n])?b[n]():b[n]);return k.join("&").replace(/%20/g,"+")}});var aa={},W,ha=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft",
"marginRight","paddingLeft","paddingRight"],["opacity"]];g.fn.extend({show:function(b,h){if(b)return this.animate(o("show",3),b,h);else{b=0;for(h=this.length;b<h;b++){var k=g.data(this[b],"olddisplay");this[b].style.display=k||"";if(g.css(this[b],"display")==="none"){k=this[b].tagName;var n;if(aa[k])n=aa[k];else{var r=g("<"+k+" />").appendTo("body");n=r.css("display");if(n==="none")n="block";r.remove();aa[k]=n}g.data(this[b],"olddisplay",n)}}b=0;for(h=this.length;b<h;b++)this[b].style.display=g.data(this[b],
"olddisplay")||"";return this}},hide:function(b,h){if(b)return this.animate(o("hide",3),b,h);else{b=0;for(h=this.length;b<h;b++){var k=g.data(this[b],"olddisplay");!k&&k!=="none"&&g.data(this[b],"olddisplay",g.css(this[b],"display"))}b=0;for(h=this.length;b<h;b++)this[b].style.display="none";return this}},_toggle:g.fn.toggle,toggle:function(b,h){var k=typeof b==="boolean";return g.isFunction(b)&&g.isFunction(h)?this._toggle.apply(this,arguments):b==null||k?this.each(function(){var n=k?b:g(this).is(":hidden");
g(this)[n?"show":"hide"]()}):this.animate(o("toggle",3),b,h)},fadeTo:function(b,h,k){return this.animate({opacity:h},b,k)},animate:function(b,h,k,n){var r=g.speed(h,k,n);return this[r.queue===false?"each":"queue"](function(){var v=g.extend({},r),x,B=this.nodeType==1&&g(this).is(":hidden"),K=this;for(x in b){if(b[x]=="hide"&&B||b[x]=="show"&&!B)return v.complete.call(this);if((x=="height"||x=="width")&&this.style){v.display=g.css(this,"display");v.overflow=this.style.overflow}}if(v.overflow!=null)this.style.overflow=
"hidden";v.curAnim=g.extend({},b);g.each(b,function(O,M){var S=new g.fx(K,v,O);if(/toggle|show|hide/.test(M))S[M=="toggle"?B?"show":"hide":M](b);else{var U=M.toString().match(/^([+-]=)?([\d+-.]+)(.*)$/),I=S.cur(true)||0;if(U){M=parseFloat(U[2]);var Z=U[3]||"px";if(Z!="px"){K.style[O]=(M||1)+Z;I=(M||1)/S.cur(true)*I;K.style[O]=I+Z}if(U[1])M=(U[1]=="-="?-1:1)*M+I;S.custom(I,M,Z)}else S.custom(I,M,"")}});return true})},stop:function(b,h){var k=g.timers;b&&this.queue([]);this.each(function(){for(var n=
k.length-1;n>=0;n--)if(k[n].elem==this){h&&k[n](true);k.splice(n,1)}});h||this.dequeue();return this}});g.each({slideDown:o("show",1),slideUp:o("hide",1),slideToggle:o("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"}},function(b,h){g.fn[b]=function(k,n){return this.animate(h,k,n)}});g.extend({speed:function(b,h,k){var n=typeof b==="object"?b:{complete:k||!k&&h||g.isFunction(b)&&b,duration:b,easing:k&&h||h&&!g.isFunction(h)&&h};n.duration=g.fx.off?0:typeof n.duration==="number"?n.duration:
g.fx.speeds[n.duration]||g.fx.speeds._default;n.old=n.complete;n.complete=function(){n.queue!==false&&g(this).dequeue();g.isFunction(n.old)&&n.old.call(this)};return n},easing:{linear:function(b,h,k,n){return k+n*b},swing:function(b,h,k,n){return(-Math.cos(b*Math.PI)/2+0.5)*n+k}},timers:[],fx:function(b,h,k){this.options=h;this.elem=b;this.prop=k;if(!h.orig)h.orig={}}});g.fx.prototype={update:function(){this.options.step&&this.options.step.call(this.elem,this.now,this);(g.fx.step[this.prop]||g.fx.step._default)(this);
if((this.prop=="height"||this.prop=="width")&&this.elem.style)this.elem.style.display="block"},cur:function(b){if(this.elem[this.prop]!=null&&(!this.elem.style||this.elem.style[this.prop]==null))return this.elem[this.prop];return(b=parseFloat(g.css(this.elem,this.prop,b)))&&b>-10000?b:parseFloat(g.curCSS(this.elem,this.prop))||0},custom:function(b,h,k){function n(v){return r.step(v)}this.startTime=c();this.start=b;this.end=h;this.unit=k||this.unit||"px";this.now=this.start;this.pos=this.state=0;var r=
this;n.elem=this.elem;if(n()&&g.timers.push(n)&&!W)W=setInterval(function(){for(var v=g.timers,x=0;x<v.length;x++)v[x]()||v.splice(x--,1);if(!v.length){clearInterval(W);W=void 0}},13)},show:function(){this.options.orig[this.prop]=g.attr(this.elem.style,this.prop);this.options.show=true;this.custom(this.prop=="width"||this.prop=="height"?1:0,this.cur());g(this.elem).show()},hide:function(){this.options.orig[this.prop]=g.attr(this.elem.style,this.prop);this.options.hide=true;this.custom(this.cur(),
0)},step:function(b){var h=c();if(b||h>=this.options.duration+this.startTime){this.now=this.end;this.pos=this.state=1;this.update();b=this.options.curAnim[this.prop]=true;for(var k in this.options.curAnim)if(this.options.curAnim[k]!==true)b=false;if(b){if(this.options.display!=null){this.elem.style.overflow=this.options.overflow;this.elem.style.display=this.options.display;if(g.css(this.elem,"display")=="none")this.elem.style.display="block"}this.options.hide&&g(this.elem).hide();if(this.options.hide||
this.options.show)for(var n in this.options.curAnim)g.attr(this.elem.style,n,this.options.orig[n]);this.options.complete.call(this.elem)}return false}else{k=h-this.startTime;this.state=k/this.options.duration;this.pos=g.easing[this.options.easing||(g.easing.swing?"swing":"linear")](this.state,k,0,1,this.options.duration);this.now=this.start+(this.end-this.start)*this.pos;this.update()}return true}};g.extend(g.fx,{speeds:{slow:600,fast:200,_default:400},step:{opacity:function(b){g.attr(b.elem.style,
"opacity",b.now)},_default:function(b){if(b.elem.style&&b.elem.style[b.prop]!=null)b.elem.style[b.prop]=b.now+b.unit;else b.elem[b.prop]=b.now}}});g.fn.offset=document.documentElement.getBoundingClientRect?function(){if(!this[0])return{top:0,left:0};if(this[0]===this[0].ownerDocument.body)return g.offset.bodyOffset(this[0]);var b=this[0].getBoundingClientRect(),h=this[0].ownerDocument,k=h.body;h=h.documentElement;return{top:b.top+(self.pageYOffset||g.boxModel&&h.scrollTop||k.scrollTop)-(h.clientTop||
k.clientTop||0),left:b.left+(self.pageXOffset||g.boxModel&&h.scrollLeft||k.scrollLeft)-(h.clientLeft||k.clientLeft||0)}}:function(){if(!this[0])return{top:0,left:0};if(this[0]===this[0].ownerDocument.body)return g.offset.bodyOffset(this[0]);g.offset.initialized||g.offset.initialize();var b=this[0],h=b.offsetParent,k=b.ownerDocument,n,r=k.documentElement,v=k.body;k=k.defaultView;n=k.getComputedStyle(b,null);for(var x=b.offsetTop,B=b.offsetLeft;(b=b.parentNode)&&b!==v&&b!==r;){n=k.getComputedStyle(b,
null);x-=b.scrollTop;B-=b.scrollLeft;if(b===h){x+=b.offsetTop;B+=b.offsetLeft;if(g.offset.doesNotAddBorder&&!(g.offset.doesAddBorderForTableAndCells&&/^t(able|d|h)$/i.test(b.tagName))){x+=parseInt(n.borderTopWidth,10)||0;B+=parseInt(n.borderLeftWidth,10)||0}h=b.offsetParent}if(g.offset.subtractsBorderForOverflowNotVisible&&n.overflow!=="visible"){x+=parseInt(n.borderTopWidth,10)||0;B+=parseInt(n.borderLeftWidth,10)||0}n=n}if(n.position==="relative"||n.position==="static"){x+=v.offsetTop;B+=v.offsetLeft}if(n.position===
"fixed"){x+=Math.max(r.scrollTop,v.scrollTop);B+=Math.max(r.scrollLeft,v.scrollLeft)}return{top:x,left:B}};g.offset={initialize:function(){if(!this.initialized){var b=document.body,h=document.createElement("div"),k,n,r,v=b.style.marginTop;k={position:"absolute",top:0,left:0,margin:0,border:0,width:"1px",height:"1px",visibility:"hidden"};for(n in k)h.style[n]=k[n];h.innerHTML='<div style="position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;"><div></div></div><table style="position:absolute;top:0;left:0;margin:0;border:5px solid #000;padding:0;width:1px;height:1px;" cellpadding="0" cellspacing="0"><tr><td></td></tr></table>';
b.insertBefore(h,b.firstChild);k=h.firstChild;n=k.firstChild;r=k.nextSibling.firstChild.firstChild;this.doesNotAddBorder=n.offsetTop!==5;this.doesAddBorderForTableAndCells=r.offsetTop===5;k.style.overflow="hidden";k.style.position="relative";this.subtractsBorderForOverflowNotVisible=n.offsetTop===-5;b.style.marginTop="1px";this.doesNotIncludeMarginInBodyOffset=b.offsetTop===0;b.style.marginTop=v;b.removeChild(h);this.initialized=true}},bodyOffset:function(b){g.offset.initialized||g.offset.initialize();
var h=b.offsetTop,k=b.offsetLeft;if(g.offset.doesNotIncludeMarginInBodyOffset){h+=parseInt(g.curCSS(b,"marginTop",true),10)||0;k+=parseInt(g.curCSS(b,"marginLeft",true),10)||0}return{top:h,left:k}}};g.fn.extend({position:function(){var b;if(this[0]){b=this.offsetParent();var h=this.offset(),k=/^body|html$/i.test(b[0].tagName)?{top:0,left:0}:b.offset();h.top-=f(this,"marginTop");h.left-=f(this,"marginLeft");k.top+=f(b,"borderTopWidth");k.left+=f(b,"borderLeftWidth");b={top:h.top-k.top,left:h.left-
k.left}}return b},offsetParent:function(){for(var b=this[0].offsetParent||document.body;b&&!/^body|html$/i.test(b.tagName)&&g.css(b,"position")=="static";)b=b.offsetParent;return g(b)}});g.each(["Left","Top"],function(b,h){var k="scroll"+h;g.fn[k]=function(n){if(!this[0])return null;return n!==void 0?this.each(function(){this==s||this==document?s.scrollTo(!b?n:g(s).scrollLeft(),b?n:g(s).scrollTop()):(this[k]=n)}):this[0]==s||this[0]==document?self[b?"pageYOffset":"pageXOffset"]||g.boxModel&&document.documentElement[k]||
document.body[k]:this[0][k]}});g.each(["Height","Width"],function(b,h){var k=h.toLowerCase();g.fn["inner"+h]=function(){return this[0]?g.css(this[0],k,false,"padding"):null};g.fn["outer"+h]=function(r){return this[0]?g.css(this[0],k,false,r?"margin":"border"):null};var n=h.toLowerCase();g.fn[n]=function(r){return this[0]==s?document.compatMode=="CSS1Compat"&&document.documentElement["client"+h]||document.body["client"+h]:this[0]==document?Math.max(document.documentElement["client"+h],document.body["scroll"+
h],document.documentElement["scroll"+h],document.body["offset"+h],document.documentElement["offset"+h]):r===void 0?this.length?g.css(this[0],n):null:this.css(n,typeof r==="string"?r:r+"px")}})})();
(function(a){a.fn.hoverIntent=function(c,f){var d={sensitivity:7,interval:100,timeout:0};d=a.extend(d,f?{over:c,out:f}:c);var e,i,m,q,o=function(z){e=z.pageX;i=z.pageY},s=function(z,g){g.hoverIntent_t=clearTimeout(g.hoverIntent_t);if(Math.abs(m-e)+Math.abs(q-i)<d.sensitivity){a(g).unbind("mousemove",o);g.hoverIntent_s=1;return d.over.apply(g,[z])}else{m=e;q=i;g.hoverIntent_t=setTimeout(function(){s(z,g)},d.interval)}},C=function(z,g){g.hoverIntent_t=clearTimeout(g.hoverIntent_t);g.hoverIntent_s=0;
return d.out.apply(g,[z])};c=function(z){for(var g=(z.type=="mouseover"?z.fromElement:z.toElement)||z.relatedTarget;g&&g!=this;)try{g=g.parentNode}catch(A){g=this}if(g==this)return false;var y=jQuery.extend({},z),F=this;if(F.hoverIntent_t)F.hoverIntent_t=clearTimeout(F.hoverIntent_t);if(z.type=="mouseover"){m=y.pageX;q=y.pageY;a(F).bind("mousemove",o);if(F.hoverIntent_s!=1)F.hoverIntent_t=setTimeout(function(){s(y,F)},d.interval)}else{a(F).unbind("mousemove",o);if(F.hoverIntent_s==1)F.hoverIntent_t=
setTimeout(function(){C(y,F)},d.timeout)}};return this.mouseover(c).mouseout(c)}})(jQuery);
(function(a){a.superfish={};a.superfish.o=[];a.superfish.op={};a.superfish.defaults={hoverClass:"sfHover",pathClass:"overideThisToUse",delay:800,animation:{opacity:"show"},speed:"normal",oldJquery:false,disableHI:false,onInit:function(){},onBeforeShow:function(){},onShow:function(){},onHide:function(){}};a.fn.superfish=function(c){var f=function(){var q=a(this),o=e(q);i(o,true);clearTimeout(o.sfTimer);q.showSuperfishUl().siblings().hideSuperfishUl()},d=function(){var q=a(this),o=e(q),s=i(o,true);
clearTimeout(o.sfTimer);if(!q.is(".sfbreadcrumb"))o.sfTimer=setTimeout(function(){q.hideSuperfishUl();s.$path.length&&f.call(s.$path)},s.delay)},e=function(q){return q.parents("ul.superfish:first")[0]},i=function(q,o){q=o?q:e(q);return a.superfish.op=a.superfish.o[q.serial]},m=function(){return a.superfish.op.oldJquery?"li[ul]":"li:has(ul)"};return this.each(function(){var q=this.serial=a.superfish.o.length,o=a.extend({},a.superfish.defaults,c);o.$path=a("li."+o.pathClass,this).each(function(){a(this).addClass(o.hoverClass+
" sfbreadcrumb").filter(m()).removeClass(o.pathClass)});a.superfish.o[q]=a.superfish.op=o;a(m(),this)[a.fn.hoverIntent&&!o.disableHI?"hoverIntent":"hover"](f,d).not(".sfbreadcrumb").hideSuperfishUl();var s=a("a",this);s.each(function(C){var z=s.eq(C).parents("li");s.eq(C).focus(function(){f.call(z)}).blur(function(){d.call(z)})});o.onInit.call(this)}).addClass("superfish")};a.fn.extend({hideSuperfishUl:function(){var c=a.superfish.op,f=a("li."+c.hoverClass,this).add(this).removeClass(c.hoverClass).find(">ul").hide().css("visibility",
"hidden");c.onHide.call(f);return this},showSuperfishUl:function(){var c=a.superfish.op,f=this.addClass(c.hoverClass).find(">ul:hidden").css("visibility","visible");c.onBeforeShow.call(f);f.animate(c.animation,c.speed,function(){c.onShow.call(this)});return this}});a(window).unload(function(){a("ul.superfish").each(function(){a("li",this).unbind("mouseover","mouseout","mouseenter","mouseleave")})})})(jQuery);
(function(a){a.extend(a.expr[":"],{shadowed:"(' '+a.className+' ').indexOf(' fx-shadowed ')"});a.fn.shadowEnable=function(){return a(this).find("+ .fx-shadow").show().end()};a.fn.shadowDisable=function(){return a(this).find("+ .fx-shadow").hide().end()};a.fn.shadowDestroy=function(){return a(this).find("+ .fx-shadow").remove().end()};a.fn.shadow=function(c){c=a.extend({offset:1,opacity:0.3,color:"#000",monitor:false,fade:false},c||{});c.offset-=1;return this.each(function(){var f=a(this).shadowDestroy(),
d=a("<div class='fx-shadow' style='position: relative; opacity:0;'></div>").insertAfter(f);baseWidth=f.outerWidth();baseHeight=f.outerHeight();position=f.position();zIndex=parseInt(f.css("zIndex"))||0;a('<div class="fx-shadow-color fx-shadow-layer-1"></div>').css({position:"absolute",opacity:0,left:c.offset,top:c.offset,width:baseWidth+1,height:baseHeight+1}).appendTo(d);a('<div class="fx-shadow-color fx-shadow-layer-2"></div>').css({position:"absolute",opacity:0,left:c.offset+2,top:c.offset+2,width:baseWidth,
height:baseHeight-3}).appendTo(d);a('<div class="fx-shadow-color fx-shadow-layer-3"></div>').css({position:"absolute",opacity:0,left:c.offset+2,top:c.offset+2,width:baseWidth-3,height:baseHeight}).appendTo(d);a('<div class="fx-shadow-color fx-shadow-layer-4"></div>').css({position:"absolute",opacity:0,left:c.offset+1,top:c.offset+1,width:baseWidth-1,height:baseHeight-1}).appendTo(d);a("div.fx-shadow-color",d).css("background-color",c.color);f.css({zIndex:zIndex+1,position:f.css("position")=="static"?
"relative":""});d.css({position:"absolute",zIndex:zIndex,top:position.top+"px",left:position.left+"px",width:baseWidth,height:baseHeight,marginLeft:f.css("marginLeft"),marginRight:f.css("marginRight"),marginBottom:f.css("marginBottom"),marginTop:f.css("marginTop")});if(c.fade){a("div.fx-shadow-layer-1",d).animate({opacity:c.opacity-0.05},4444);a("div.fx-shadow-layer-2",d).animate({opacity:c.opacity-0.1},4444);a("div.fx-shadow-layer-3",d).animate({opacity:c.opacity-0.15},4444);a("div.fx-shadow-layer-4",
d).animate({opacity:c.opacity},4444);jQuery.browser.msie||d.animate({opacity:c.opacity},4444)}else{a("div.fx-shadow-layer-1",d).css("opacity",c.opacity-0.05);a("div.fx-shadow-layer-2",d).css("opacity",c.opacity-0.1);a("div.fx-shadow-layer-3",d).css("opacity",c.opacity-0.15);a("div.fx-shadow-layer-4",d).css("opacity",c.opacity);jQuery.browser.msie||d.css("opacity",c.opacity)}if(c.monitor){function e(){var i=a(this),m=i.next();m.css({top:parseInt(i.css("top"))+"px",left:parseInt(i.css("left"))+"px"});
a(">*",m).css({height:this.offsetHeight+"px",width:this.offsetWidth+"px"})}f.bind("DOMAttrModified",e);if(d[0].style.setExpression){d[0].style.setExpression("top","parseInt(this.previousSibling.currentStyle.top ) + 'px'");d[0].style.setExpression("left","parseInt(this.previousSibling.currentStyle.left) + 'px'")}}})}})(jQuery);
(function(a){function c(z,g){return parseInt(a.css(z,g))||0}function f(z){z=parseInt(z).toString(16);return z.length<2?"0"+z:z}function d(z){for(;z;){var g=a.css(z,"backgroundColor");if(g&&g!="transparent"&&g!="rgba(0, 0, 0, 0)"){if(g.indexOf("rgb")>=0){z=g.match(/\d+/g);return"#"+f(z[0])+f(z[1])+f(z[2])}return g}z=z.parentNode}return"#ffffff"}function e(z,g,A){switch(z){case "round":return Math.round(A*(1-Math.cos(Math.asin(g/A))));case "cool":return Math.round(A*(1+Math.cos(Math.asin(g/A))));case "sharp":return Math.round(A*
(1-Math.cos(Math.acos(g/A))));case "bite":return Math.round(A*Math.cos(Math.asin((A-g-1)/A)));case "slide":return Math.round(A*Math.atan2(g,A/g));case "jut":return Math.round(A*Math.atan2(A,A-g-1));case "curl":return Math.round(A*Math.atan(g));case "tear":return Math.round(A*Math.cos(g));case "wicked":return Math.round(A*Math.tan(g));case "long":return Math.round(A*Math.sqrt(g));case "sculpt":return Math.round(A*Math.log(A-g-1,A));case "dogfold":case "dog":return g&1?g+1:A;case "dog2":return g&2?
g+1:A;case "dog3":return g&3?g+1:A;case "fray":return g%2*A;case "notch":return A;case "bevelfold":case "bevel":return g+1}}var i=document.createElement("div").style,m=i.MozBorderRadius!==undefined,q=i.WebkitBorderRadius!==undefined,o=i.borderRadius!==undefined||i.BorderRadius!==undefined;i=document.documentMode||0;var s=a.browser.msie&&(a.browser.version<8&&!i||i<8),C=a.browser.msie&&function(){var z=document.createElement("div");try{z.style.setExpression("width","0+0");z.style.removeExpression("width")}catch(g){return false}return true}();
a.fn.corner=function(z){if(this.length==0){if(!a.isReady&&this.selector){var g=this.selector,A=this.context;a(function(){a(g,A).corner(z)})}return this}return this.each(function(){var y=a(this),F=[y.attr(a.fn.corner.defaults.metaAttr)||"",z||""].join(" ").toLowerCase(),L=/keep/.test(F),Q=(F.match(/cc:(#[0-9a-f]+)/)||[])[1],P=(F.match(/sc:(#[0-9a-f]+)/)||[])[1],N=parseInt((F.match(/(\d+)px/)||[])[1])||10,da=(F.match(/round|bevelfold|bevel|notch|bite|cool|sharp|slide|jut|curl|tear|fray|wicked|sculpt|long|dog3|dog2|dogfold|dog/)||
["round"])[0],ea=/dogfold|bevelfold/.test(F),ca={T:0,B:1};F={TL:/top|tl|left/.test(F),TR:/top|tr|right/.test(F),BL:/bottom|bl|left/.test(F),BR:/bottom|br|right/.test(F)};if(!F.TL&&!F.TR&&!F.BL&&!F.BR)F={TL:1,TR:1,BL:1,BR:1};if(a.fn.corner.defaults.useNative&&da=="round"&&(o||m||q)&&!Q&&!P){if(F.TL)y.css(o?"border-top-left-radius":m?"-moz-border-radius-topleft":"-webkit-border-top-left-radius",N+"px");if(F.TR)y.css(o?"border-top-right-radius":m?"-moz-border-radius-topright":"-webkit-border-top-right-radius",
N+"px");if(F.BL)y.css(o?"border-bottom-left-radius":m?"-moz-border-radius-bottomleft":"-webkit-border-bottom-left-radius",N+"px");if(F.BR)y.css(o?"border-bottom-right-radius":m?"-moz-border-radius-bottomright":"-webkit-border-bottom-right-radius",N+"px")}else{y=document.createElement("div");a(y).css({overflow:"hidden",height:"1px",minHeight:"1px",fontSize:"1px",backgroundColor:P||"transparent",borderStyle:"solid"});P={T:parseInt(a.css(this,"paddingTop"))||0,R:parseInt(a.css(this,"paddingRight"))||
0,B:parseInt(a.css(this,"paddingBottom"))||0,L:parseInt(a.css(this,"paddingLeft"))||0};if(typeof this.style.zoom!=undefined)this.style.zoom=1;if(!L)this.style.border="none";y.style.borderColor=Q||d(this.parentNode);a(this).outerHeight();for(var Y in ca)if((L=ca[Y])&&(F.BL||F.BR)||!L&&(F.TL||F.TR)){y.style.borderStyle="none "+(F[Y+"R"]?"solid":"none")+" none "+(F[Y+"L"]?"solid":"none");Q=document.createElement("div");a(Q).addClass("jquery-corner");var J=Q.style;L?this.appendChild(Q):this.insertBefore(Q,
this.firstChild);if(L){if(a.css(this,"position")=="static")this.style.position="relative";J.position="absolute";J.bottom=J.left=J.padding=J.margin="0";if(C)J.setExpression("width","this.parentNode.offsetWidth");else J.width="100%"}else if(!L&&a.browser.msie){if(a.css(this,"position")=="static")this.style.position="relative";J.position="absolute";J.top=J.left=J.right=J.padding=J.margin="0";if(C){var V=c(this,"borderLeftWidth")+c(this,"borderRightWidth");J.setExpression("width","this.parentNode.offsetWidth - "+
V+'+ "px"')}else J.width="100%"}else{J.position="relative";J.margin=!L?"-"+P.T+"px -"+P.R+"px "+(P.T-N)+"px -"+P.L+"px":P.B-N+"px -"+P.R+"px -"+P.B+"px -"+P.L+"px"}for(J=0;J<N;J++){V=Math.max(0,e(da,J,N));var aa=y.cloneNode(false);aa.style.borderWidth="0 "+(F[Y+"R"]?V:0)+"px 0 "+(F[Y+"L"]?V:0)+"px";L?Q.appendChild(aa):Q.insertBefore(aa,Q.firstChild)}if(ea&&a.support.boxModel)if(!(L&&s))for(var W in F)if(F[W])if(!(L&&(W=="TL"||W=="TR")))if(!(!L&&(W=="BL"||W=="BR"))){J={position:"absolute",border:"none",
margin:0,padding:0,overflow:"hidden",backgroundColor:y.style.borderColor};V=a("<div/>").css(J).css({width:N+"px",height:"1px"});switch(W){case "TL":V.css({bottom:0,left:0});break;case "TR":V.css({bottom:0,right:0});break;case "BL":V.css({top:0,left:0});break;case "BR":V.css({top:0,right:0});break}Q.appendChild(V[0]);J=a("<div/>").css(J).css({top:0,bottom:0,width:"1px",height:N+"px"});switch(W){case "TL":J.css({left:N});break;case "TR":J.css({right:N});break;case "BL":J.css({left:N});break;case "BR":J.css({right:N});
break}Q.appendChild(J[0])}}}})};a.fn.uncorner=function(){if(o||m||q)this.css(o?"border-radius":m?"-moz-border-radius":"-webkit-border-radius",0);a("div.jquery-corner",this).remove();return this};a.fn.corner.defaults={useNative:true,metaAttr:"data-corner"}})(jQuery);
jQuery.ui||function(a){function c(o,s,C,z){function g(y){y=a[o][s][y]||[];return typeof y=="string"?y.split(/,?\s+/):y}var A=g("getter");if(z.length==1&&typeof z[0]=="string")A=A.concat(g("getterSetter"));return a.inArray(C,A)!=-1}var f=a.fn.remove,d=a.browser.mozilla&&parseFloat(a.browser.version)<1.9;a.ui={version:"1.7.1",plugin:{add:function(o,s,C){o=a.ui[o].prototype;for(var z in C){o.plugins[z]=o.plugins[z]||[];o.plugins[z].push([s,C[z]])}},call:function(o,s,C){if((s=o.plugins[s])&&o.element[0].parentNode)for(var z=
0;z<s.length;z++)o.options[s[z][0]]&&s[z][1].apply(o.element,C)}},contains:function(o,s){return document.compareDocumentPosition?o.compareDocumentPosition(s)&16:o!==s&&o.contains(s)},hasScroll:function(o,s){if(a(o).css("overflow")=="hidden")return false;s=s&&s=="left"?"scrollLeft":"scrollTop";var C=false;if(o[s]>0)return true;o[s]=1;C=o[s]>0;o[s]=0;return C},isOverAxis:function(o,s,C){return o>s&&o<s+C},isOver:function(o,s,C,z,g,A){return a.ui.isOverAxis(o,C,g)&&a.ui.isOverAxis(s,z,A)},keyCode:{BACKSPACE:8,
CAPS_LOCK:20,COMMA:188,CONTROL:17,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,INSERT:45,LEFT:37,NUMPAD_ADD:107,NUMPAD_DECIMAL:110,NUMPAD_DIVIDE:111,NUMPAD_ENTER:108,NUMPAD_MULTIPLY:106,NUMPAD_SUBTRACT:109,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SHIFT:16,SPACE:32,TAB:9,UP:38}};if(d){var e=a.attr,i=a.fn.removeAttr,m=/^aria-/,q=/^wairole:/;a.attr=function(o,s,C){var z=C!==undefined;return s=="role"?z?e.call(this,o,s,"wairole:"+C):(e.apply(this,arguments)||"").replace(q,""):m.test(s)?z?o.setAttributeNS("http://www.w3.org/2005/07/aaa",
s.replace(m,"aaa:"),C):e.call(this,o,s.replace(m,"aaa:")):e.apply(this,arguments)};a.fn.removeAttr=function(o){return m.test(o)?this.each(function(){this.removeAttributeNS("http://www.w3.org/2005/07/aaa",o.replace(m,""))}):i.call(this,o)}}a.fn.extend({remove:function(){a("*",this).add(this).each(function(){a(this).triggerHandler("remove")});return f.apply(this,arguments)},enableSelection:function(){return this.attr("unselectable","off").css("MozUserSelect","").unbind("selectstart.ui")},disableSelection:function(){return this.attr("unselectable",
"on").css("MozUserSelect","none").bind("selectstart.ui",function(){return false})},scrollParent:function(){var o;o=a.browser.msie&&/(static|relative)/.test(this.css("position"))||/absolute/.test(this.css("position"))?this.parents().filter(function(){return/(relative|absolute|fixed)/.test(a.curCSS(this,"position",1))&&/(auto|scroll)/.test(a.curCSS(this,"overflow",1)+a.curCSS(this,"overflow-y",1)+a.curCSS(this,"overflow-x",1))}).eq(0):this.parents().filter(function(){return/(auto|scroll)/.test(a.curCSS(this,
"overflow",1)+a.curCSS(this,"overflow-y",1)+a.curCSS(this,"overflow-x",1))}).eq(0);return/fixed/.test(this.css("position"))||!o.length?a(document):o}});a.extend(a.expr[":"],{data:function(o,s,C){return!!a.data(o,C[3])},focusable:function(o){var s=o.nodeName.toLowerCase(),C=a.attr(o,"tabindex");return(/input|select|textarea|button|object/.test(s)?!o.disabled:"a"==s||"area"==s?o.href||!isNaN(C):!isNaN(C))&&!a(o)["area"==s?"parents":"closest"](":hidden").length},tabbable:function(o){var s=a.attr(o,"tabindex");
return(isNaN(s)||s>=0)&&a(o).is(":focusable")}});a.widget=function(o,s){var C=o.split(".")[0];o=o.split(".")[1];a.fn[o]=function(z){var g=typeof z=="string",A=Array.prototype.slice.call(arguments,1);if(g&&z.substring(0,1)=="_")return this;if(g&&c(C,o,z,A)){var y=a.data(this[0],o);return y?y[z].apply(y,A):undefined}return this.each(function(){var F=a.data(this,o);!F&&!g&&a.data(this,o,new a[C][o](this,z))._init();F&&g&&a.isFunction(F[z])&&F[z].apply(F,A)})};a[C]=a[C]||{};a[C][o]=function(z,g){var A=
this;this.namespace=C;this.widgetName=o;this.widgetEventPrefix=a[C][o].eventPrefix||o;this.widgetBaseClass=C+"-"+o;this.options=a.extend({},a.widget.defaults,a[C][o].defaults,a.metadata&&a.metadata.get(z)[o],g);this.element=a(z).bind("setData."+o,function(y,F,L){if(y.target==z)return A._setData(F,L)}).bind("getData."+o,function(y,F){if(y.target==z)return A._getData(F)}).bind("remove",function(){return A.destroy()})};a[C][o].prototype=a.extend({},a.widget.prototype,s);a[C][o].getterSetter="option"};
a.widget.prototype={_init:function(){},destroy:function(){this.element.removeData(this.widgetName).removeClass(this.widgetBaseClass+"-disabled "+this.namespace+"-state-disabled").removeAttr("aria-disabled")},option:function(o,s){var C=o,z=this;if(typeof o=="string"){if(s===undefined)return this._getData(o);C={};C[o]=s}a.each(C,function(g,A){z._setData(g,A)})},_getData:function(o){return this.options[o]},_setData:function(o,s){this.options[o]=s;if(o=="disabled")this.element[s?"addClass":"removeClass"](this.widgetBaseClass+
"-disabled "+this.namespace+"-state-disabled").attr("aria-disabled",s)},enable:function(){this._setData("disabled",false)},disable:function(){this._setData("disabled",true)},_trigger:function(o,s,C){var z=this.options[o];o=o==this.widgetEventPrefix?o:this.widgetEventPrefix+o;s=a.Event(s);s.type=o;if(s.originalEvent){o=a.event.props.length;for(var g;o;){g=a.event.props[--o];s[g]=s.originalEvent[g]}}this.element.trigger(s,C);return!(a.isFunction(z)&&z.call(this.element[0],s,C)===false||s.isDefaultPrevented())}};
a.widget.defaults={disabled:false};a.ui.mouse={_mouseInit:function(){var o=this;this.element.bind("mousedown."+this.widgetName,function(s){return o._mouseDown(s)}).bind("click."+this.widgetName,function(s){if(o._preventClickEvent){o._preventClickEvent=false;s.stopImmediatePropagation();return false}});if(a.browser.msie){this._mouseUnselectable=this.element.attr("unselectable");this.element.attr("unselectable","on")}this.started=false},_mouseDestroy:function(){this.element.unbind("."+this.widgetName);
a.browser.msie&&this.element.attr("unselectable",this._mouseUnselectable)},_mouseDown:function(o){o.originalEvent=o.originalEvent||{};if(!o.originalEvent.mouseHandled){this._mouseStarted&&this._mouseUp(o);this._mouseDownEvent=o;var s=this,C=o.which==1,z=typeof this.options.cancel=="string"?a(o.target).parents().add(o.target).filter(this.options.cancel).length:false;if(!C||z||!this._mouseCapture(o))return true;this.mouseDelayMet=!this.options.delay;if(!this.mouseDelayMet)this._mouseDelayTimer=setTimeout(function(){s.mouseDelayMet=
true},this.options.delay);if(this._mouseDistanceMet(o)&&this._mouseDelayMet(o)){this._mouseStarted=this._mouseStart(o)!==false;if(!this._mouseStarted){o.preventDefault();return true}}this._mouseMoveDelegate=function(g){return s._mouseMove(g)};this._mouseUpDelegate=function(g){return s._mouseUp(g)};a(document).bind("mousemove."+this.widgetName,this._mouseMoveDelegate).bind("mouseup."+this.widgetName,this._mouseUpDelegate);a.browser.safari||o.preventDefault();return o.originalEvent.mouseHandled=true}},
_mouseMove:function(o){if(a.browser.msie&&!o.button)return this._mouseUp(o);if(this._mouseStarted){this._mouseDrag(o);return o.preventDefault()}if(this._mouseDistanceMet(o)&&this._mouseDelayMet(o))(this._mouseStarted=this._mouseStart(this._mouseDownEvent,o)!==false)?this._mouseDrag(o):this._mouseUp(o);return!this._mouseStarted},_mouseUp:function(o){a(document).unbind("mousemove."+this.widgetName,this._mouseMoveDelegate).unbind("mouseup."+this.widgetName,this._mouseUpDelegate);if(this._mouseStarted){this._mouseStarted=
false;this._preventClickEvent=o.target==this._mouseDownEvent.target;this._mouseStop(o)}return false},_mouseDistanceMet:function(o){return Math.max(Math.abs(this._mouseDownEvent.pageX-o.pageX),Math.abs(this._mouseDownEvent.pageY-o.pageY))>=this.options.distance},_mouseDelayMet:function(){return this.mouseDelayMet},_mouseStart:function(){},_mouseDrag:function(){},_mouseStop:function(){},_mouseCapture:function(){return true}};a.ui.mouse.defaults={cancel:null,distance:1,delay:0}}(jQuery);
function getRGB(a){var c;if(a&&a.constructor==Array&&a.length==3)return a;if(c=/rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/.exec(a))return[parseInt(c[1],10),parseInt(c[2],10),parseInt(c[3],10)];if(c=/rgb\(\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*\)/.exec(a))return[parseFloat(c[1])*2.55,parseFloat(c[2])*2.55,parseFloat(c[3])*2.55];if(c=/#([a-fA-F0-9]{2})([a-fA-F0-9]{2})([a-fA-F0-9]{2})/.exec(a))return[parseInt(c[1],16),parseInt(c[2],
16),parseInt(c[3],16)];if(c=/#([a-fA-F0-9])([a-fA-F0-9])([a-fA-F0-9])/.exec(a))return[parseInt(c[1]+c[1],16),parseInt(c[2]+c[2],16),parseInt(c[3]+c[3],16)];if(/rgba\(0, 0, 0, 0\)/.exec(a))return colors.transparent;return colors[$.trim(a).toLowerCase()]}
jQuery.effects||function(a){function c(d,e){var i=d[1]&&d[1].constructor==Object?d[1]:{};if(e)i.mode=e;e=d[1]&&d[1].constructor!=Object?d[1]:i.duration?i.duration:d[2];e=a.fx.off?0:typeof e==="number"?e:a.fx.speeds[e]||a.fx.speeds._default;var m=i.callback||a.isFunction(d[1])&&d[1]||a.isFunction(d[2])&&d[2]||a.isFunction(d[3])&&d[3];return[d[0],i,e,m]}function f(d,e){var i;do{i=a.curCSS(d,e);if(i!=""&&i!="transparent"&&i!="rgba(0, 0, 0, 0)"||a.nodeName(d,"body"))break;e="backgroundColor"}while(d=
d.parentNode);return getRGB(i)}a.effects={version:"1.7.1",save:function(d,e){for(var i=0;i<e.length;i++)e[i]!==null&&d.data("ec.storage."+e[i],d[0].style[e[i]])},restore:function(d,e){for(var i=0;i<e.length;i++)e[i]!==null&&d.css(e[i],d.data("ec.storage."+e[i]))},setMode:function(d,e){if(e=="toggle")e=d.is(":hidden")?"show":"hide";return e},getBaseline:function(d,e){var i;switch(d[0]){case "top":i=0;break;case "middle":i=0.5;break;case "bottom":i=1;break;default:i=d[0]/e.height}switch(d[1]){case "left":d=
0;break;case "center":d=0.5;break;case "right":d=1;break;default:d=d[1]/e.width}return{x:d,y:i}},createWrapper:function(d){if(d.parent().is(".ui-effects-wrapper"))return d.parent();var e={width:d.outerWidth(true),height:d.outerHeight(true),"float":d.css("float")};d.wrap('<div class="ui-effects-wrapper" style="font-size:100%;background:transparent;border:none;margin:0;padding:0"></div>');var i=d.parent();if(d.css("position")=="static"){i.css({position:"relative"});d.css({position:"relative"})}else{var m=
d.css("top");if(isNaN(parseInt(m,10)))m="auto";var q=d.css("left");if(isNaN(parseInt(q,10)))q="auto";i.css({position:d.css("position"),top:m,left:q,zIndex:d.css("z-index")}).show();d.css({position:"relative",top:0,left:0})}i.css(e);return i},removeWrapper:function(d){if(d.parent().is(".ui-effects-wrapper"))return d.parent().replaceWith(d);return d},setTransition:function(d,e,i,m){m=m||{};a.each(e,function(q,o){unit=d.cssUnit(o);if(unit[0]>0)m[o]=unit[0]*i+unit[1]});return m},animateClass:function(d,
e,i,m){var q=typeof i=="function"?i:m?m:null,o=typeof i=="string"?i:null;return this.each(function(){var s={},C=a(this),z=C.attr("style")||"";if(typeof z=="object")z=z.cssText;if(d.toggle)C.hasClass(d.toggle)?(d.remove=d.toggle):(d.add=d.toggle);var g=a.extend({},document.defaultView?document.defaultView.getComputedStyle(this,null):this.currentStyle);d.add&&C.addClass(d.add);d.remove&&C.removeClass(d.remove);var A=a.extend({},document.defaultView?document.defaultView.getComputedStyle(this,null):this.currentStyle);
d.add&&C.removeClass(d.add);d.remove&&C.addClass(d.remove);for(var y in A)if(typeof A[y]!="function"&&A[y]&&y.indexOf("Moz")==-1&&y.indexOf("length")==-1&&A[y]!=g[y]&&(y.match(/color/i)||!y.match(/color/i)&&!isNaN(parseInt(A[y],10)))&&(g.position!="static"||g.position=="static"&&!y.match(/left|top|bottom|right/)))s[y]=A[y];C.animate(s,e,o,function(){if(typeof a(this).attr("style")=="object"){a(this).attr("style").cssText="";a(this).attr("style").cssText=z}else a(this).attr("style",z);d.add&&a(this).addClass(d.add);
d.remove&&a(this).removeClass(d.remove);q&&q.apply(this,arguments)})})}};a.fn.extend({_show:a.fn.show,_hide:a.fn.hide,__toggle:a.fn.toggle,_addClass:a.fn.addClass,_removeClass:a.fn.removeClass,_toggleClass:a.fn.toggleClass,effect:function(d,e,i,m){return a.effects[d]?a.effects[d].call(this,{method:d,options:e||{},duration:i,callback:m}):null},show:function(){return!arguments[0]||arguments[0].constructor==Number||/(slow|normal|fast)/.test(arguments[0])?this._show.apply(this,arguments):this.effect.apply(this,
c(arguments,"show"))},hide:function(){return!arguments[0]||arguments[0].constructor==Number||/(slow|normal|fast)/.test(arguments[0])?this._hide.apply(this,arguments):this.effect.apply(this,c(arguments,"hide"))},toggle:function(){return!arguments[0]||arguments[0].constructor==Number||/(slow|normal|fast)/.test(arguments[0])||arguments[0].constructor==Function?this.__toggle.apply(this,arguments):this.effect.apply(this,c(arguments,"toggle"))},addClass:function(d,e,i,m){return e?a.effects.animateClass.apply(this,
[{add:d},e,i,m]):this._addClass(d)},removeClass:function(d,e,i,m){return e?a.effects.animateClass.apply(this,[{remove:d},e,i,m]):this._removeClass(d)},toggleClass:function(d,e,i,m){return typeof e!=="boolean"&&e?a.effects.animateClass.apply(this,[{toggle:d},e,i,m]):this._toggleClass(d,e)},morph:function(d,e,i,m,q){return a.effects.animateClass.apply(this,[{add:e,remove:d},i,m,q])},switchClass:function(){return this.morph.apply(this,arguments)},cssUnit:function(d){var e=this.css(d),i=[];a.each(["em",
"px","%","pt"],function(m,q){if(e.indexOf(q)>0)i=[parseFloat(e),q]});return i}});a.each(["backgroundColor","borderBottomColor","borderLeftColor","borderRightColor","borderTopColor","color","outlineColor"],function(d,e){a.fx.step[e]=function(i){if(i.state==0){i.start=f(i.elem,e);i.end=getRGB(i.end)}try{i.elem.style[e]="rgb("+[Math.max(Math.min(parseInt(i.pos*(i.end[0]-i.start[0])+i.start[0],10),255),0),Math.max(Math.min(parseInt(i.pos*(i.end[1]-i.start[1])+i.start[1],10),255),0),Math.max(Math.min(parseInt(i.pos*
(i.end[2]-i.start[2])+i.start[2],10),255),0)].join(",")+")"}catch(m){}}});a.easing.jswing=a.easing.swing;a.extend(a.easing,{def:"easeOutQuad",swing:function(d,e,i,m,q){return a.easing[a.easing.def](d,e,i,m,q)},easeInQuad:function(d,e,i,m,q){return m*(e/=q)*e+i},easeOutQuad:function(d,e,i,m,q){return-m*(e/=q)*(e-2)+i},easeInOutQuad:function(d,e,i,m,q){if((e/=q/2)<1)return m/2*e*e+i;return-m/2*(--e*(e-2)-1)+i},easeInCubic:function(d,e,i,m,q){return m*(e/=q)*e*e+i},easeOutCubic:function(d,e,i,m,q){return m*
((e=e/q-1)*e*e+1)+i},easeInOutCubic:function(d,e,i,m,q){if((e/=q/2)<1)return m/2*e*e*e+i;return m/2*((e-=2)*e*e+2)+i},easeInQuart:function(d,e,i,m,q){return m*(e/=q)*e*e*e+i},easeOutQuart:function(d,e,i,m,q){return-m*((e=e/q-1)*e*e*e-1)+i},easeInOutQuart:function(d,e,i,m,q){if((e/=q/2)<1)return m/2*e*e*e*e+i;return-m/2*((e-=2)*e*e*e-2)+i},easeInQuint:function(d,e,i,m,q){return m*(e/=q)*e*e*e*e+i},easeOutQuint:function(d,e,i,m,q){return m*((e=e/q-1)*e*e*e*e+1)+i},easeInOutQuint:function(d,e,i,m,q){if((e/=
q/2)<1)return m/2*e*e*e*e*e+i;return m/2*((e-=2)*e*e*e*e+2)+i},easeInSine:function(d,e,i,m,q){return-m*Math.cos(e/q*(Math.PI/2))+m+i},easeOutSine:function(d,e,i,m,q){return m*Math.sin(e/q*(Math.PI/2))+i},easeInOutSine:function(d,e,i,m,q){return-m/2*(Math.cos(Math.PI*e/q)-1)+i},easeInExpo:function(d,e,i,m,q){return e==0?i:m*Math.pow(2,10*(e/q-1))+i},easeOutExpo:function(d,e,i,m,q){return e==q?i+m:m*(-Math.pow(2,-10*e/q)+1)+i},easeInOutExpo:function(d,e,i,m,q){if(e==0)return i;if(e==q)return i+m;if((e/=
q/2)<1)return m/2*Math.pow(2,10*(e-1))+i;return m/2*(-Math.pow(2,-10*--e)+2)+i},easeInCirc:function(d,e,i,m,q){return-m*(Math.sqrt(1-(e/=q)*e)-1)+i},easeOutCirc:function(d,e,i,m,q){return m*Math.sqrt(1-(e=e/q-1)*e)+i},easeInOutCirc:function(d,e,i,m,q){if((e/=q/2)<1)return-m/2*(Math.sqrt(1-e*e)-1)+i;return m/2*(Math.sqrt(1-(e-=2)*e)+1)+i},easeInElastic:function(d,e,i,m,q){d=1.70158;var o=0,s=m;if(e==0)return i;if((e/=q)==1)return i+m;o||(o=q*0.3);if(s<Math.abs(m)){s=m;d=o/4}else d=o/(2*Math.PI)*Math.asin(m/
s);return-(s*Math.pow(2,10*(e-=1))*Math.sin((e*q-d)*2*Math.PI/o))+i},easeOutElastic:function(d,e,i,m,q){d=1.70158;var o=0,s=m;if(e==0)return i;if((e/=q)==1)return i+m;o||(o=q*0.3);if(s<Math.abs(m)){s=m;d=o/4}else d=o/(2*Math.PI)*Math.asin(m/s);return s*Math.pow(2,-10*e)*Math.sin((e*q-d)*2*Math.PI/o)+m+i},easeInOutElastic:function(d,e,i,m,q){d=1.70158;var o=0,s=m;if(e==0)return i;if((e/=q/2)==2)return i+m;o||(o=q*0.3*1.5);if(s<Math.abs(m)){s=m;d=o/4}else d=o/(2*Math.PI)*Math.asin(m/s);if(e<1)return-0.5*
s*Math.pow(2,10*(e-=1))*Math.sin((e*q-d)*2*Math.PI/o)+i;return s*Math.pow(2,-10*(e-=1))*Math.sin((e*q-d)*2*Math.PI/o)*0.5+m+i},easeInBack:function(d,e,i,m,q,o){if(o==undefined)o=1.70158;return m*(e/=q)*e*((o+1)*e-o)+i},easeOutBack:function(d,e,i,m,q,o){if(o==undefined)o=1.70158;return m*((e=e/q-1)*e*((o+1)*e+o)+1)+i},easeInOutBack:function(d,e,i,m,q,o){if(o==undefined)o=1.70158;if((e/=q/2)<1)return m/2*e*e*(((o*=1.525)+1)*e-o)+i;return m/2*((e-=2)*e*(((o*=1.525)+1)*e+o)+2)+i},easeInBounce:function(d,
e,i,m,q){return m-a.easing.easeOutBounce(d,q-e,0,m,q)+i},easeOutBounce:function(d,e,i,m,q){return(e/=q)<1/2.75?m*7.5625*e*e+i:e<2/2.75?m*(7.5625*(e-=1.5/2.75)*e+0.75)+i:e<2.5/2.75?m*(7.5625*(e-=2.25/2.75)*e+0.9375)+i:m*(7.5625*(e-=2.625/2.75)*e+0.984375)+i},easeInOutBounce:function(d,e,i,m,q){if(e<q/2)return a.easing.easeInBounce(d,e*2,0,m,q)*0.5+i;return a.easing.easeOutBounce(d,e*2-q,0,m,q)*0.5+m*0.5+i}})}(jQuery);
(function(a){a.widget("ui.tabs",{_init:function(){if(this.options.deselectable!==undefined)this.options.collapsible=this.options.deselectable;this._tabify(true)},_setData:function(c,f){if(c=="selected")this.options.collapsible&&f==this.options.selected||this.select(f);else{this.options[c]=f;if(c=="deselectable")this.options.collapsible=f;this._tabify()}},_tabId:function(c){return c.title&&c.title.replace(/\s/g,"_").replace(/[^A-Za-z0-9\-_:\.]/g,"")||this.options.idPrefix+a.data(c)},_sanitizeSelector:function(c){return c.replace(/:/g,
"\\:")},_cookie:function(){var c=this.cookie||(this.cookie=this.options.cookie.name||"ui-tabs-"+a.data(this.list[0]));return a.cookie.apply(null,[c].concat(a.makeArray(arguments)))},_ui:function(c,f){return{tab:c,panel:f,index:this.anchors.index(c)}},_cleanup:function(){this.lis.filter(".ui-state-processing").removeClass("ui-state-processing").find("span:data(label.tabs)").each(function(){var c=a(this);c.html(c.data("label.tabs")).removeData("label.tabs")})},_tabify:function(c){function f(A,y){A.css({display:""});
a.browser.msie&&y.opacity&&A[0].style.removeAttribute("filter")}this.list=this.element.children("ul:first");this.lis=a("li:has(a[href])",this.list);this.anchors=this.lis.map(function(){return a("a",this)[0]});this.panels=a([]);var d=this,e=this.options,i=/^#.+/;this.anchors.each(function(A,y){var F=a(y).attr("href"),L=F.split("#")[0],Q;if(L&&(L===location.toString().split("#")[0]||(Q=a("base")[0])&&L===Q.href)){F=y.hash;y.href=F}if(i.test(F))d.panels=d.panels.add(d._sanitizeSelector(F));else if(F!=
"#"){a.data(y,"href.tabs",F);a.data(y,"load.tabs",F.replace(/#.*$/,""));F=d._tabId(y);y.href="#"+F;y=a("#"+F);if(!y.length){y=a(e.panelTemplate).attr("id",F).addClass("ui-tabs-panel ui-widget-content ui-corner-bottom").insertAfter(d.panels[A-1]||d.list);y.data("destroy.tabs",true)}d.panels=d.panels.add(y)}else e.disabled.push(A)});if(c){this.element.addClass("ui-tabs ui-widget ui-widget-content ui-corner-all");this.list.addClass("ui-tabs-nav ui-helper-reset ui-helper-clearfix ui-widget-header ui-corner-all");
this.lis.addClass("ui-state-default ui-corner-top");this.panels.addClass("ui-tabs-panel ui-widget-content ui-corner-bottom");if(e.selected===undefined){location.hash&&this.anchors.each(function(A,y){if(y.hash==location.hash){e.selected=A;return false}});if(typeof e.selected!="number"&&e.cookie)e.selected=parseInt(d._cookie(),10);if(typeof e.selected!="number"&&this.lis.filter(".ui-tabs-selected").length)e.selected=this.lis.index(this.lis.filter(".ui-tabs-selected"));e.selected=e.selected||0}else if(e.selected===
null)e.selected=-1;e.selected=e.selected>=0&&this.anchors[e.selected]||e.selected<0?e.selected:0;e.disabled=a.unique(e.disabled.concat(a.map(this.lis.filter(".ui-state-disabled"),function(A){return d.lis.index(A)}))).sort();a.inArray(e.selected,e.disabled)!=-1&&e.disabled.splice(a.inArray(e.selected,e.disabled),1);this.panels.addClass("ui-tabs-hide");this.lis.removeClass("ui-tabs-selected ui-state-active");if(e.selected>=0&&this.anchors.length){this.panels.eq(e.selected).removeClass("ui-tabs-hide");
this.lis.eq(e.selected).addClass("ui-tabs-selected ui-state-active");d.element.queue("tabs",function(){d._trigger("show",null,d._ui(d.anchors[e.selected],d.panels[e.selected]))});this.load(e.selected)}a(window).bind("unload",function(){d.lis.add(d.anchors).unbind(".tabs");d.lis=d.anchors=d.panels=null})}else e.selected=this.lis.index(this.lis.filter(".ui-tabs-selected"));this.element[e.collapsible?"addClass":"removeClass"]("ui-tabs-collapsible");e.cookie&&this._cookie(e.selected,e.cookie);c=0;for(var m;m=
this.lis[c];c++)a(m)[a.inArray(c,e.disabled)!=-1&&!a(m).hasClass("ui-tabs-selected")?"addClass":"removeClass"]("ui-state-disabled");e.cache===false&&this.anchors.removeData("cache.tabs");this.lis.add(this.anchors).unbind(".tabs");if(e.event!="mouseover"){var q=function(A,y){y.is(":not(.ui-state-disabled)")&&y.addClass("ui-state-"+A)},o=function(A,y){y.removeClass("ui-state-"+A)};this.lis.bind("mouseover.tabs",function(){q("hover",a(this))});this.lis.bind("mouseout.tabs",function(){o("hover",a(this))});
this.anchors.bind("focus.tabs",function(){q("focus",a(this).closest("li"))});this.anchors.bind("blur.tabs",function(){o("focus",a(this).closest("li"))})}var s,C;if(e.fx)if(a.isArray(e.fx)){s=e.fx[0];C=e.fx[1]}else s=C=e.fx;var z=C?function(A,y){a(A).closest("li").removeClass("ui-state-default").addClass("ui-tabs-selected ui-state-active");y.hide().removeClass("ui-tabs-hide").animate(C,C.duration||"normal",function(){f(y,C);d._trigger("show",null,d._ui(A,y[0]))})}:function(A,y){a(A).closest("li").removeClass("ui-state-default").addClass("ui-tabs-selected ui-state-active");
y.removeClass("ui-tabs-hide");d._trigger("show",null,d._ui(A,y[0]))},g=s?function(A,y){y.animate(s,s.duration||"normal",function(){d.lis.removeClass("ui-tabs-selected ui-state-active").addClass("ui-state-default");y.addClass("ui-tabs-hide");f(y,s);d.element.dequeue("tabs")})}:function(A,y){d.lis.removeClass("ui-tabs-selected ui-state-active").addClass("ui-state-default");y.addClass("ui-tabs-hide");d.element.dequeue("tabs")};this.anchors.bind(e.event+".tabs",function(){var A=this,y=a(this).closest("li"),
F=d.panels.filter(":not(.ui-tabs-hide)"),L=a(d._sanitizeSelector(this.hash));if(y.hasClass("ui-tabs-selected")&&!e.collapsible||y.hasClass("ui-state-disabled")||y.hasClass("ui-state-processing")||d._trigger("select",null,d._ui(this,L[0]))===false){this.blur();return false}e.selected=d.anchors.index(this);d.abort();if(e.collapsible)if(y.hasClass("ui-tabs-selected")){e.selected=-1;e.cookie&&d._cookie(e.selected,e.cookie);d.element.queue("tabs",function(){g(A,F)}).dequeue("tabs");this.blur();return false}else if(!F.length){e.cookie&&
d._cookie(e.selected,e.cookie);d.element.queue("tabs",function(){z(A,L)});d.load(d.anchors.index(this));this.blur();return false}e.cookie&&d._cookie(e.selected,e.cookie);if(L.length){F.length&&d.element.queue("tabs",function(){g(A,F)});d.element.queue("tabs",function(){z(A,L)});d.load(d.anchors.index(this))}else throw"jQuery UI Tabs: Mismatching fragment identifier.";a.browser.msie&&this.blur()});this.anchors.bind("click.tabs",function(){return false})},destroy:function(){var c=this.options;this.abort();
this.element.unbind(".tabs").removeClass("ui-tabs ui-widget ui-widget-content ui-corner-all ui-tabs-collapsible").removeData("tabs");this.list.removeClass("ui-tabs-nav ui-helper-reset ui-helper-clearfix ui-widget-header ui-corner-all");this.anchors.each(function(){var f=a.data(this,"href.tabs");if(f)this.href=f;var d=a(this).unbind(".tabs");a.each(["href","load","cache"],function(e,i){d.removeData(i+".tabs")})});this.lis.unbind(".tabs").add(this.panels).each(function(){a.data(this,"destroy.tabs")?
a(this).remove():a(this).removeClass("ui-state-default ui-corner-top ui-tabs-selected ui-state-active ui-state-hover ui-state-focus ui-state-disabled ui-tabs-panel ui-widget-content ui-corner-bottom ui-tabs-hide")});c.cookie&&this._cookie(null,c.cookie)},add:function(c,f,d){if(d===undefined)d=this.anchors.length;var e=this,i=this.options;f=a(i.tabTemplate.replace(/#\{href\}/g,c).replace(/#\{label\}/g,f));var m=!c.indexOf("#")?c.replace("#",""):this._tabId(a("a",f)[0]);alert(m+" "+c);f.addClass("ui-state-default ui-corner-top").data("destroy.tabs",
true);c=a("#"+m);c.length||(c=a(i.panelTemplate).attr("id",m).data("destroy.tabs",true));c.addClass("ui-tabs-panel ui-widget-content ui-corner-bottom ui-tabs-hide");if(d>=this.lis.length){f.appendTo(this.list);c.appendTo(this.list[0].parentNode)}else{f.insertBefore(this.lis[d]);c.insertBefore(this.panels[d])}i.disabled=a.map(i.disabled,function(q){return q>=d?++q:q});this._tabify();if(this.anchors.length==1){f.addClass("ui-tabs-selected ui-state-active");c.removeClass("ui-tabs-hide");this.element.queue("tabs",
function(){e._trigger("show",null,e._ui(e.anchors[0],e.panels[0]))});this.load(0)}this._trigger("add",null,this._ui(this.anchors[d],this.panels[d]))},remove:function(c){var f=this.options,d=this.lis.eq(c).remove(),e=this.panels.eq(c).remove();if(d.hasClass("ui-tabs-selected")&&this.anchors.length>1)this.select(c+(c+1<this.anchors.length?1:-1));f.disabled=a.map(a.grep(f.disabled,function(i){return i!=c}),function(i){return i>=c?--i:i});this._tabify();this._trigger("remove",null,this._ui(d.find("a")[0],
e[0]))},enable:function(c){var f=this.options;if(a.inArray(c,f.disabled)!=-1){this.lis.eq(c).removeClass("ui-state-disabled");f.disabled=a.grep(f.disabled,function(d){return d!=c});this._trigger("enable",null,this._ui(this.anchors[c],this.panels[c]))}},disable:function(c){var f=this.options;if(c!=f.selected){this.lis.eq(c).addClass("ui-state-disabled");f.disabled.push(c);f.disabled.sort();this._trigger("disable",null,this._ui(this.anchors[c],this.panels[c]))}},select:function(c){if(typeof c=="string")c=
this.anchors.index(this.anchors.filter("[href$="+c+"]"));else if(c===null)c=-1;if(c==-1&&this.options.collapsible)c=this.options.selected;this.anchors.eq(c).trigger(this.options.event+".tabs")},load:function(c){var f=this,d=this.options,e=this.anchors.eq(c)[0],i=a.data(e,"load.tabs");this.abort();if(!i||this.element.queue("tabs").length!==0&&a.data(e,"cache.tabs"))this.element.dequeue("tabs");else{this.lis.eq(c).addClass("ui-state-processing");if(d.spinner){var m=a("span",e);m.data("label.tabs",m.html()).html(d.spinner)}this.xhr=
a.ajax(a.extend({},d.ajaxOptions,{url:i,success:function(q,o){a(f._sanitizeSelector(e.hash)).html(q);f._cleanup();d.cache&&a.data(e,"cache.tabs",true);f._trigger("load",null,f._ui(f.anchors[c],f.panels[c]));try{d.ajaxOptions.success(q,o)}catch(s){}f.element.dequeue("tabs")}}))}},abort:function(){this.element.queue([]);this.panels.stop(false,true);if(this.xhr){this.xhr.abort();delete this.xhr}this._cleanup()},url:function(c,f){this.anchors.eq(c).removeData("cache.tabs").data("load.tabs",f)},length:function(){return this.anchors.length}});
a.extend(a.ui.tabs,{version:"1.7.1",getter:"length",defaults:{ajaxOptions:null,cache:false,cookie:null,collapsible:false,disabled:[],event:"click",fx:null,idPrefix:"ui-tabs-",panelTemplate:"<div></div>",spinner:"<em>Loading&#8230;</em>",tabTemplate:'<li><a href="#{href}"><span>#{label}</span></a></li>'}});a.extend(a.ui.tabs.prototype,{rotation:null,rotate:function(c,f){var d=this,e=this.options,i=d._rotate||(d._rotate=function(m){clearTimeout(d.rotation);d.rotation=setTimeout(function(){var q=e.selected;
d.select(++q<d.anchors.length?q:0)},c);m&&m.stopPropagation()});f=d._unrotate||(d._unrotate=!f?function(m){m.clientX&&d.rotate(null)}:function(){t=e.selected;i()});if(c){this.element.bind("tabsshow",i);this.anchors.bind(e.event+".tabs",f);i()}else{clearTimeout(d.rotation);this.element.unbind("tabsshow",i);this.anchors.unbind(e.event+".tabs",f);delete this._rotate;delete this._unrotate}}})})(jQuery);
(function(a){a.widget("ui.accordion",{_init:function(){var c=this.options,f=this;this.running=0;if(c.collapsible==a.ui.accordion.defaults.collapsible&&c.alwaysOpen!=a.ui.accordion.defaults.alwaysOpen)c.collapsible=!c.alwaysOpen;if(c.navigation){var d=this.element.find("a").filter(c.navigationFilter);if(d.length)if(d.filter(c.header).length)this.active=d;else{this.active=d.parent().parent().prev();d.addClass("ui-accordion-content-active")}}this.element.addClass("ui-accordion ui-widget ui-helper-reset");
this.element[0].nodeName=="UL"&&this.element.children("li").addClass("ui-accordion-li-fix");this.headers=this.element.find(c.header).addClass("ui-accordion-header ui-helper-reset ui-state-default ui-corner-all").bind("mouseenter.accordion",function(){a(this).addClass("ui-state-hover")}).bind("mouseleave.accordion",function(){a(this).removeClass("ui-state-hover")}).bind("focus.accordion",function(){a(this).addClass("ui-state-focus")}).bind("blur.accordion",function(){a(this).removeClass("ui-state-focus")});
this.headers.next().addClass("ui-accordion-content ui-helper-reset ui-widget-content ui-corner-bottom");this.active=this._findActive(this.active||c.active).toggleClass("ui-state-default").toggleClass("ui-state-active").toggleClass("ui-corner-all").toggleClass("ui-corner-top");this.active.next().addClass("ui-accordion-content-active");a("<span/>").addClass("ui-icon "+c.icons.header).prependTo(this.headers);this.active.find(".ui-icon").toggleClass(c.icons.header).toggleClass(c.icons.headerSelected);
a.browser.msie&&this.element.find("a").css("zoom","1");this.resize();this.element.attr("role","tablist");this.headers.attr("role","tab").bind("keydown",function(e){return f._keydown(e)}).next().attr("role","tabpanel");this.headers.not(this.active||"").attr("aria-expanded","false").attr("tabIndex","-1").next().hide();this.active.length?this.active.attr("aria-expanded","true").attr("tabIndex","0"):this.headers.eq(0).attr("tabIndex","0");a.browser.safari||this.headers.find("a").attr("tabIndex","-1");
c.event&&this.headers.bind(c.event+".accordion",function(e){return f._clickHandler.call(f,e,this)})},destroy:function(){var c=this.options;this.element.removeClass("ui-accordion ui-widget ui-helper-reset").removeAttr("role").unbind(".accordion").removeData("accordion");this.headers.unbind(".accordion").removeClass("ui-accordion-header ui-helper-reset ui-state-default ui-corner-all ui-state-active ui-corner-top").removeAttr("role").removeAttr("aria-expanded").removeAttr("tabindex");this.headers.find("a").removeAttr("tabindex");
this.headers.children(".ui-icon").remove();var f=this.headers.next().css("display","").removeAttr("role").removeClass("ui-helper-reset ui-widget-content ui-corner-bottom ui-accordion-content ui-accordion-content-active");if(c.autoHeight||c.fillHeight)f.css("height","")},_setData:function(c,f){if(c=="alwaysOpen"){c="collapsible";f=!f}a.widget.prototype._setData.apply(this,arguments)},_keydown:function(c){var f=a.ui.keyCode;if(!(this.options.disabled||c.altKey||c.ctrlKey)){var d=this.headers.length,
e=this.headers.index(c.target),i=false;switch(c.keyCode){case f.RIGHT:case f.DOWN:i=this.headers[(e+1)%d];break;case f.LEFT:case f.UP:i=this.headers[(e-1+d)%d];break;case f.SPACE:case f.ENTER:return this._clickHandler({target:c.target},c.target)}if(i){a(c.target).attr("tabIndex","-1");a(i).attr("tabIndex","0");i.focus();return false}return true}},resize:function(){var c=this.options,f;if(c.fillSpace){if(a.browser.msie){var d=this.element.parent().css("overflow");this.element.parent().css("overflow",
"hidden")}f=this.element.parent().height();a.browser.msie&&this.element.parent().css("overflow",d);this.headers.each(function(){f-=a(this).outerHeight()});var e=0;this.headers.next().each(function(){e=Math.max(e,a(this).innerHeight()-a(this).height())}).height(Math.max(0,f-e)).css("overflow","auto")}else if(c.autoHeight){f=0;this.headers.next().each(function(){f=Math.max(f,a(this).outerHeight())}).height(f)}},activate:function(c){c=this._findActive(c)[0];this._clickHandler({target:c},c)},_findActive:function(c){return c?
typeof c=="number"?this.headers.filter(":eq("+c+")"):this.headers.not(this.headers.not(c)):c===false?a([]):this.headers.filter(":eq(0)")},_clickHandler:function(c,f){var d=this.options;if(d.disabled)return false;if(!c.target&&d.collapsible){this.active.removeClass("ui-state-active ui-corner-top").addClass("ui-state-default ui-corner-all").find(".ui-icon").removeClass(d.icons.headerSelected).addClass(d.icons.header);this.active.next().removeClass("ui-accordion-content-active");c=this.active.next();
d={options:d,newHeader:a([]),oldHeader:d.active,newContent:a([]),oldContent:c};f=this.active=a([]);this._toggle(f,c,d);return false}var e=a(c.currentTarget||f),i=e[0]==this.active[0];if(this.running||!d.collapsible&&i)return false;this.active.removeClass("ui-state-active ui-corner-top").addClass("ui-state-default ui-corner-all").find(".ui-icon").removeClass(d.icons.headerSelected).addClass(d.icons.header);this.active.next().removeClass("ui-accordion-content-active");if(!i){e.removeClass("ui-state-default ui-corner-all").addClass("ui-state-active ui-corner-top").find(".ui-icon").removeClass(d.icons.header).addClass(d.icons.headerSelected);
e.next().addClass("ui-accordion-content-active")}f=e.next();c=this.active.next();d={options:d,newHeader:i&&d.collapsible?a([]):e,oldHeader:this.active,newContent:i&&d.collapsible?a([]):f.find("> *"),oldContent:c.find("> *")};var m=this.headers.index(this.active[0])>this.headers.index(e[0]);this.active=i?a([]):e;this._toggle(f,c,d,i,m);return false},_toggle:function(c,f,d,e,i){var m=this.options,q=this;this.toShow=c;this.toHide=f;this.data=d;var o=function(){if(q)return q._completed.apply(q,arguments)};
this._trigger("changestart",null,this.data);this.running=f.size()===0?c.size():f.size();if(m.animated){d={};d=m.collapsible&&e?{toShow:a([]),toHide:f,complete:o,down:i,autoHeight:m.autoHeight||m.fillSpace}:{toShow:c,toHide:f,complete:o,down:i,autoHeight:m.autoHeight||m.fillSpace};if(!m.proxied)m.proxied=m.animated;if(!m.proxiedDuration)m.proxiedDuration=m.duration;m.animated=a.isFunction(m.proxied)?m.proxied(d):m.proxied;m.duration=a.isFunction(m.proxiedDuration)?m.proxiedDuration(d):m.proxiedDuration;
e=a.ui.accordion.animations;var s=m.duration,C=m.animated;e[C]||(e[C]=function(z){this.slide(z,{easing:C,duration:s||700})});e[C](d)}else{if(m.collapsible&&e)c.toggle();else{f.hide();c.show()}o(true)}f.prev().attr("aria-expanded","false").attr("tabIndex","-1").blur();c.prev().attr("aria-expanded","true").attr("tabIndex","0").focus()},_completed:function(c){var f=this.options;this.running=c?0:--this.running;if(!this.running){f.clearStyle&&this.toShow.add(this.toHide).css({height:"",overflow:""});this._trigger("change",
null,this.data)}}});a.extend(a.ui.accordion,{version:"1.7.1",defaults:{active:null,alwaysOpen:true,animated:"slide",autoHeight:true,clearStyle:false,collapsible:false,event:"click",fillSpace:false,header:"> li > :first-child,> :not(li):even",icons:{header:"ui-icon-triangle-1-e",headerSelected:"ui-icon-triangle-1-s"},navigation:false,navigationFilter:function(){return this.href.toLowerCase()==location.href.toLowerCase()}},animations:{slide:function(c,f){c=a.extend({easing:"swing",duration:300},c,f);
if(c.toHide.size())if(c.toShow.size()){var d=c.toShow.css("overflow"),e,i={},m={};f=c.toShow;f.width(parseInt(f.parent().width(),10)-parseInt(f.css("paddingLeft"),10)-parseInt(f.css("paddingRight"),10)-(parseInt(f.css("borderLeftWidth"),10)||0)-(parseInt(f.css("borderRightWidth"),10)||0));a.each(["height","paddingTop","paddingBottom"],function(q,o){m[o]="hide";q=(""+a.css(c.toShow[0],o)).match(/^([\d+-.]+)(.*)$/);i[o]={value:q[1],unit:q[2]||"px"}});c.toShow.css({height:0,overflow:"hidden"}).show();
c.toHide.filter(":hidden").each(c.complete).end().filter(":visible").animate(m,{step:function(q,o){if(o.prop=="height")e=(o.now-o.start)/(o.end-o.start);c.toShow[0].style[o.prop]=e*i[o.prop].value+i[o.prop].unit},duration:c.duration,easing:c.easing,complete:function(){c.autoHeight||c.toShow.css("height","");c.toShow.css("width",parent.width());c.toShow.css({overflow:d});c.complete()}})}else c.toHide.animate({height:"hide"},c);else c.toShow.animate({height:"show"},c)},bounceslide:function(c){this.slide(c,
{easing:c.down?"easeOutBounce":"swing",duration:c.down?1E3:200})},easeslide:function(c){this.slide(c,{easing:"easeinout",duration:700})}}})})(jQuery);
(function(a){a.effects.puff=function(c){return this.queue(function(){var f=a(this),d=a.extend(true,{},c.options),e=a.effects.setMode(f,c.options.mode||"hide"),i=parseInt(c.options.percent,10)||150;d.fade=true;var m={height:f.height(),width:f.width()},q=i/100;f.from=e=="hide"?m:{height:m.height*q,width:m.width*q};d.from=f.from;d.percent=e=="hide"?i:100;d.mode=e;f.effect("scale",d,c.duration,c.callback);f.dequeue()})};a.effects.scale=function(c){return this.queue(function(){var f=a(this),d=a.extend(true,
{},c.options),e=a.effects.setMode(f,c.options.mode||"effect"),i=parseInt(c.options.percent,10)||(parseInt(c.options.percent,10)==0?0:e=="hide"?0:100),m=c.options.direction||"both",q=c.options.origin;if(e!="effect"){d.origin=q||["middle","center"];d.restore=true}q={height:f.height(),width:f.width()};f.from=c.options.from||(e=="show"?{height:0,width:0}:q);i={y:m!="horizontal"?i/100:1,x:m!="vertical"?i/100:1};f.to={height:q.height*i.y,width:q.width*i.x};if(c.options.fade){if(e=="show"){f.from.opacity=
0;f.to.opacity=1}if(e=="hide"){f.from.opacity=1;f.to.opacity=0}}d.from=f.from;d.to=f.to;d.mode=e;f.effect("size",d,c.duration,c.callback);f.dequeue()})};a.effects.size=function(c){return this.queue(function(){var f=a(this),d=["position","top","left","width","height","overflow","opacity"],e=["position","top","left","overflow","opacity"],i=["width","height","overflow"],m=["fontSize"],q=["borderTopWidth","borderBottomWidth","paddingTop","paddingBottom"],o=["borderLeftWidth","borderRightWidth","paddingLeft",
"paddingRight"],s=a.effects.setMode(f,c.options.mode||"effect"),C=c.options.restore||false,z=c.options.scale||"both",g=c.options.origin,A={height:f.height(),width:f.width()};f.from=c.options.from||A;f.to=c.options.to||A;if(g){g=a.effects.getBaseline(g,A);f.from.top=(A.height-f.from.height)*g.y;f.from.left=(A.width-f.from.width)*g.x;f.to.top=(A.height-f.to.height)*g.y;f.to.left=(A.width-f.to.width)*g.x}var y={from:{y:f.from.height/A.height,x:f.from.width/A.width},to:{y:f.to.height/A.height,x:f.to.width/
A.width}};if(z=="box"||z=="both"){if(y.from.y!=y.to.y){d=d.concat(q);f.from=a.effects.setTransition(f,q,y.from.y,f.from);f.to=a.effects.setTransition(f,q,y.to.y,f.to)}if(y.from.x!=y.to.x){d=d.concat(o);f.from=a.effects.setTransition(f,o,y.from.x,f.from);f.to=a.effects.setTransition(f,o,y.to.x,f.to)}}if(z=="content"||z=="both")if(y.from.y!=y.to.y){d=d.concat(m);f.from=a.effects.setTransition(f,m,y.from.y,f.from);f.to=a.effects.setTransition(f,m,y.to.y,f.to)}a.effects.save(f,C?d:e);f.show();a.effects.createWrapper(f);
f.css("overflow","hidden").css(f.from);if(z=="content"||z=="both"){q=q.concat(["marginTop","marginBottom"]).concat(m);o=o.concat(["marginLeft","marginRight"]);i=d.concat(q).concat(o);f.find("*[width]").each(function(){child=a(this);C&&a.effects.save(child,i);var F={height:child.height(),width:child.width()};child.from={height:F.height*y.from.y,width:F.width*y.from.x};child.to={height:F.height*y.to.y,width:F.width*y.to.x};if(y.from.y!=y.to.y){child.from=a.effects.setTransition(child,q,y.from.y,child.from);
child.to=a.effects.setTransition(child,q,y.to.y,child.to)}if(y.from.x!=y.to.x){child.from=a.effects.setTransition(child,o,y.from.x,child.from);child.to=a.effects.setTransition(child,o,y.to.x,child.to)}child.css(child.from);child.animate(child.to,c.duration,c.options.easing,function(){C&&a.effects.restore(child,i)})})}f.animate(f.to,{queue:false,duration:c.duration,easing:c.options.easing,complete:function(){s=="hide"&&f.hide();a.effects.restore(f,C?d:e);a.effects.removeWrapper(f);c.callback&&c.callback.apply(this,
arguments);f.dequeue()}})})}})(jQuery);
jQuery.extend({historyCurrentHash:undefined,historyCallback:undefined,historyIframeSrc:undefined,historyInit:function(a,c){jQuery.historyCallback=a;if(c)jQuery.historyIframeSrc=c;a=location.hash;jQuery.historyCurrentHash=a;if(jQuery.browser.msie){if(jQuery.historyCurrentHash=="")jQuery.historyCurrentHash="#";jQuery("body").prepend('<iframe id="jQuery_history" style="display: none;"'+(jQuery.historyIframeSrc?' src="'+jQuery.historyIframeSrc+'"':"")+"></iframe>");c=jQuery("#jQuery_history")[0].contentWindow.document;
c.open();c.close();c.location.hash=a}else if(jQuery.browser.safari){jQuery.historyBackStack=[];jQuery.historyBackStack.length=history.length;jQuery.historyForwardStack=[];jQuery.lastHistoryLength=history.length;jQuery.isFirst=true}a&&jQuery.historyCallback(a.replace(/^#/,""));setInterval(jQuery.historyCheck,100)},historyAddHistory:function(a){jQuery.historyBackStack.push(a);jQuery.historyForwardStack.length=0;this.isFirst=true},historyCheck:function(){if(jQuery.browser.msie){var a=jQuery("#jQuery_history")[0];
a=(a.contentDocument||a.contentWindow.document).location.hash;if(a!=jQuery.historyCurrentHash){location.hash=a;jQuery.historyCurrentHash=a;jQuery.historyCallback(a.replace(/^#/,""))}}else if(jQuery.browser.safari){jQuery.lastHistoryLength==history.length&&jQuery.historyBackStack.length>jQuery.lastHistoryLength&&jQuery.historyBackStack.shift();if(!jQuery.dontCheck){a=history.length-jQuery.historyBackStack.length;jQuery.lastHistoryLength=history.length;if(a){jQuery.isFirst=false;if(a<0)for(var c=0;c<
Math.abs(a);c++)jQuery.historyForwardStack.unshift(jQuery.historyBackStack.pop());else for(c=0;c<a;c++)jQuery.historyBackStack.push(jQuery.historyForwardStack.shift());a=jQuery.historyBackStack[jQuery.historyBackStack.length-1];if(a!=undefined){jQuery.historyCurrentHash=location.hash;jQuery.historyCallback(a)}}else if(jQuery.historyBackStack[jQuery.historyBackStack.length-1]==undefined&&!jQuery.isFirst){location.hash?jQuery.historyCallback(location.hash.replace(/^#/,"")):jQuery.historyCallback("");
jQuery.isFirst=true}}}else{a=location.hash;if(a!=jQuery.historyCurrentHash){jQuery.historyCurrentHash=a;jQuery.historyCallback(a.replace(/^#/,""))}}},historyLoad:function(a){var c;a=decodeURIComponent(a);if(jQuery.browser.safari)c=a;else{c="#"+a;location.hash=c}jQuery.historyCurrentHash=c;if(jQuery.browser.msie){var f=jQuery("#jQuery_history")[0].contentWindow.document;f.open();f.close();f.location.hash=c;jQuery.lastHistoryLength=history.length;jQuery.historyCallback(a)}else if(jQuery.browser.safari){jQuery.dontCheck=
true;this.historyAddHistory(a);window.setTimeout(function(){jQuery.dontCheck=false},200);jQuery.historyCallback(a);location.hash=c}else jQuery.historyCallback(a)}});
(function(a){a.fn.minimiser=function(c){return this.each(function(){var f=a(this).height();a(this).data("staticheight",f);c&&a(this).css("height","1")})};a.fn.minimise=function(c,f){return this.each(function(){a(this).stop().animate({height:"1"},c,f)})};a.fn.sneakpeek=function(){return this.each(function(){a(this).animate({height:12},345,function(){a(this).animate({height:1},234)})})};a.fn.maximise=function(c){return this.each(function(){a("html,body").animate({scrollTop:a(this).parent().offset().top-
23},c*3/4);var f=a(this).data("staticheight");a(this).stop().animate({height:f},c)})}})(jQuery);function throttle(a,c){clearTimeout(a._tId);a._tId=setTimeout(function(){a.call()},c)}function changeFrame(a,c){a.animate({opacity:"0"},1234,function(){newpos=Math.floor(Math.random()*10)*-252;$(this).css("background-position",newpos+"px 0px");$(this).animate({opacity:"0.9"},666);c.call()})}
function changeBackground(){throttle(changeBackground,54321);changeFrame($("img#bbi1"),function(){changeFrame($("img#bbi2"),function(){changeFrame($("img#bbi3"),function(){throttle(changeBackground,54321)})})})}function cycleLoading(){$("div#loadingyouarehere").animate({color:"#34715b"},1666,function(){$(this).text()=="Loading..."&&$(this).animate({color:"#cad3c0"},1666,function(){$(this).text()=="Loading..."&&cycleLoading()})})}
function hideLoading(){$("div#loadingyouarehere").text("You are here >").animate({color:"#34715b"},1666)}function showLoading(){$("div#loadingyouarehere").text("Loading...").animate({color:"#cad3c0"},1666,function(){cycleLoading()})}
function addComment(a,c){title=a.find("input#title").attr("value");name=a.find("input#nama").attr("value");body=a.find("textarea#body").attr("value");if(title==""||title=="Title")a.find("p.commentcomment").html("Please enter a title for your comment ...");else if(body==""||body=="Comment")a.find("p.commentcomment").html("Please write your comment before clicking OK  ...");else if(name==""||name=="Name")a.find("p.commentcomment").html("Please enter your name ...");else{a.find("p.commentcomment").html("Your comment has been referred for moderation");
a.find("button.cancel").css("visibility","hidden");a.find("button.ok").css("visibility","hidden");a.parent().find("a.addcomment").css("visibility","hidden");$.post("doaddcomm.php",{title:title,body:body,name:name,node:c})}}
function updateAddCommLinks(a){a.find("button.ok").click(function(){addComment(a,$(this).attr("value"));return false});a.find("button.cancel").click(function(){a.remove();return false});a.find("input#title").focus(function(){$(this).attr("value")=="Title"&&$(this).attr("value","")});a.find("input#nama").focus(function(){$(this).attr("value")=="Name"&&$(this).attr("value","")});a.find("textarea#body").focus(function(){$(this).attr("value")=="Comment"&&$(this).attr("value","")});$("html,body").animate({scrollTop:a.offset().top})}
function updateCommentLinks(a){a.find("div.comment-list").css("visibility","visible");a.find("a.showcomments").click(function(){$("html,body").animate({scrollTop:a.offset().top-53});$(this).parent().load($(this).attr("href"),null,function(){updateCommentLinks($(this))});return false});a.find("a.addcomment").click(function(){if($(this).parent().find("div.addcomments").length==0){$(this).parent().append("<div class='addcomments'></div>");$(this).parent().find("div.addcomments").load($(this).attr("href"),
null,function(){updateAddCommLinks($(this))})}return false});a.find("div.comment").corner("11px")}function updatePage(a){$o=$("div#"+a);$o.addClass($("div#nodetype").attr("class"));$o.addClass("itsapage");$o.animate({top:0},666,function(){hideLoading()});updatelements(a);$("html,body").animate({scrollTop:0},666);$("div.comment-links").css("visibility","visible").load($("div.comment-links>a").attr("href"),null,function(){updateCommentLinks($(this))})}
function updatelements(a){$o=$("div#"+a);if($o.hasClass("itsapage")){$o.find("div.tabs>ul>li>a").each(function(){link=$(this).attr("href");link=link.substr(link.indexOf("=")+1)+"&title=hide";ind=link.indexOf("&");link=link.substr(0,ind)+"?"+link.substr(ind+1);$(this).attr("href",link).addClass("dontmakemegreat")});$o.find("div.tabs").tabs({show:function(c,f){$(f.tab).parent().blur();changeBackground()},select:function(c,f){$("li.selectnothover").removeClass("selectnothover");$(f.tab).parent().trigger("mouseout").addClass("selectnothover");
return true},cache:true,fx:{opacity:"toggle"},load:function(c,f){$(f.panel).corner("round tr br 37");updatelements($(f.panel).attr("id"))}});$o.find("div.tabs>ul>li").corner("round top 15px").each(function(c){$thestr="tab_color_"+c%2;$(this).addClass($thestr).click(function(){$(this).find("a").click();return false});$(this).hover(function(){otherstr="tab_color_"+c%2;$(this).not("li.selectnothover").removeClass(otherstr).addClass("hover_"+otherstr)},function(){otherstr="tab_color_"+c%2;$(this).not("li.selectnothover").removeClass("hover_"+
otherstr).addClass(otherstr)})});$o.find("div.tabs>div").each(function(c){$thestr="tab_color_"+c%2;$(this).addClass($thestr)});$o.find("div.zones>a").addClass("zone");$o.find("a").each(function(){if(!this.className.length){$(this).css("color","");$(this).addClass("greatlink").animate({color:"#fcc884",padding:"0em"})}});$("a.greatlink").hover(function(){$(this).stop().animate({padding:"1em",color:"#3f3ffe"},432)},function(){$(this).stop().animate({color:"#fcc884",padding:"0em"},321)});$o.find("p font, p span").each(function(){var c=
$(this).css("color");if(c!=""&&c!=undefined){cola=getRGB(c);cola!="transparent"&&$(this).css("color","rgb(128"+(cola[0]&127)+",128"+(cola[1]&127)+",128"+(cola[2]&127)+")")}})}$o.find(".stripe:even").addClass("striped");$o.find("div.mritem > div.jquery-corner").length==0&&$o.find("div.mritem").corner("round 10px").hover(function(){$(this).stop().animate({backgroundColor:"#8a4622"})},function(){$(this).hasClass(".striped")?$(this).stop().animate({backgroundColor:"#444"},666):$(this).stop().animate({backgroundColor:$(this).parent().css("background-color")},
666)}).click(function(){$(this).find("a:first").each(function(){this.href.indexOf("#")<0?$(this).click():load2main(this.href.substr(this.href.indexOf("#")+1))});return false});$o.find("div.stripelinks>div.stripe").corner("round 8px").hover(function(){$(this).hasClass(".striped")||$(this).css("background-color",$(this).parent().css("background-color"));$(this).stop().animate({backgroundColor:"#8a4622"})},function(){$(this).hasClass(".striped")?$(this).stop().animate({backgroundColor:"#444"}):$(this).stop().animate({backgroundColor:"#000"})}).click(function(){$(this).find("a:first").click();
return false});$o.find('a[href*="/?page="]').each(function(){$(this).attr("href",$(this).attr("href").replace(/\?/,"#"));$(this).click(function(){return load2main(this.href.substr(this.href.indexOf("#")+1))})});$o.find('a[href*=".pdf"]').click(function(){window.open(this.href);return false});$o.find('a[href^="http://"]').click(function(){window.open(this.href);return false});$o.find("div.ROUNDtop").corner("round top 23px");$o.find("div.ROUNDbot").corner("round bottom 23px");$o.find("div.ROUNDED").corner("round 23px");
$o.find("div.makebutt").corner("round 13px").hover(function(){$(this).stop().animate({backgroundColor:"#efefbe"},321)},function(){$(this).stop().animate({backgroundColor:"#ddad80"},666)}).click(function(){$(this).stop();$(this).find("a:first").click();$(this).animate({backgroundColor:"#ffff9e"},321,function(){$(this).animate({backgroundColor:"#ddad80"},666)});return false})}
function justloadit(a){if($("div#mainpage").css("display")=="none"){$("div#othermainpage").animate({opacity:"hide",scale:"2",rotate:"-=3deg"},1234,function(){$(this).hide()});loadto="mainpage"}else{$("div#mainpage").animate({opacity:"hide",scale:"2",rotate:"-=3deg"},1234,function(){$(this).hide()});loadto="othermainpage"}if(a.charAt(0)=="#")a=a.substr(1);$(".nav li.sfHover").hideSuperfishUl();var c="";if(a.substring(0,15)=="page=fastpages/"){c=a.substring(5);c=c.replace(/\&/,"?")}else c="getnode.php?"+
a;$("div#"+loadto).css("display")=="none"&&$("div#"+loadto).css("transform","rotate(3deg) scale(0.5)");$("div#"+loadto).load(c,null,function(){updatePage(loadto);$("div#"+loadto).animate({opacity:"show",scale:"1",rotate:"0deg"},666);return false});return false}function load2main(a){$("div.comment-links").remove();showLoading();$.historyLoad(a);return false}
function onbodyload(){$(".nav").superfish();$.historyInit(justloadit);location.hash||updatePage("mainpage");updatelements("leftmenu");updatelements("topmenu")}setTimeout("onbodyload()",23);
(function(a){function c(f){f=f.replace(/left|top/g,"0px");f=f.replace(/right|bottom/g,"100%");f=f.replace(/([0-9\.]+)(\s|\)|$)/g,"$1px$2");f=f.match(/(-?[0-9\.]+)(px|\%|em|pt)\s(-?[0-9\.]+)(px|\%|em|pt)/);return[parseFloat(f[1],10),f[2],parseFloat(f[3],10),f[4]]}a.extend(a.fx.step,{backgroundPosition:function(f){if(!f.bgPosReady){var d=a.curCSS(f.elem,"backgroundPosition");d||(d=a.curCSS(f.elem,"backgroundPositionX")+" "+a.curCSS(f.elem,"backgroundPositionY"));if(!d)return;d=c(d);f.start=[d[0],d[2]];
d=c(f.end);f.end=[d[0],d[2]];f.unit=[d[1],d[3]];f.bgPosReady=true}d=[];d[0]=(f.end[0]-f.start[0])*f.pos+f.start[0]+f.unit[0];d[1]=(f.end[1]-f.start[1])*f.pos+f.start[1]+f.unit[1];f.elem.style.backgroundPosition=d[0]+" "+d[1]}})})(jQuery);
var Transformie={toRadian:function(a){return a.indexOf("deg")!=-1?parseInt(a,10)*(Math.PI*2/360):a.indexOf("grad")!=-1?parseInt(a,10)*(Math.PI/200):parseInt(a,10)},refreshMatrix:function(a,c){c=c.match(/[A-z]+\([^\)]+/g)||[];for(var f=[],d=0;d<c.length;d++){var e=c[d].split("(")[0],i=c[d].split("(")[1];switch(e){case "matrix":i=i.split(",");f.push($M([[i[0],i[2],0],[i[1],i[3],0],[0,0,1]]));break;case "rotate":e=Transformie.toRadian(i);f.push($M([[Math.cos(e),-Math.sin(e),0],[Math.sin(e),Math.cos(e),
0],[0,0,1]]));break;case "scale":f.push($M([[i,0,0],[0,i,0],[0,0,1]]));break;case "scaleX":f.push($M([[i,0,0],[0,1,0],[0,0,1]]));break;case "scaleY":f.push($M([[1,0,0],[0,i,0],[0,0,1]]));break;case "skew":e=Transformie.toRadian(i);f.push($M([[1,0,0],[Math.tan(e),1,0],[0,0,1]]));case "skewX":e=Transformie.toRadian(i);f.push($M([[1,Math.tan(e),0],[0,1,0],[0,0,1]]));break;case "skewY":e=Transformie.toRadian(i);f.push($M([[1,0,0],[Math.tan(e),1,0],[0,0,1]]));break}}if(f.length){var m=f[0];for(d=0;d<f.length;d++)if(f[d+
1])m=f[d].x(f[d+1]);jQuery(a).each(function(){if(!this.filters["DXImageTransform.Microsoft.Matrix"])this.style.filter=(this.style.filter?"":" ")+"progid:DXImageTransform.Microsoft.Matrix(sizingMethod='auto expand')";jQuery.extend(this.filters["DXImageTransform.Microsoft.Matrix"],{M11:m.elements[0][0],M12:m.elements[0][1],M21:m.elements[1][0],M22:m.elements[1][1]})})}}};
(function(a){var c="deg";a.fn.rotate=function(e){var i=a(this).css("transform");if(typeof i=="undefined")i="none";if(typeof e=="undefined"){if(i)if((e=i.match(/rotate\(([^)]+)\)/))&&e[1])return e[1];return 0}if(e=e.toString().match(/^(-?\d+(\.\d+)?)(.+)?$/)){if(e[3])c=e[3];a(this).css("transform",i.replace(/none|rotate\([^)]*\)/,"")+"rotate("+e[1]+c+")");jQuery.browser.msie&&Transformie.refreshMatrix(this,i)}};a.fn.scale=function(e){var i=a(this).css("transform");if(typeof i=="undefined")i="none";
if(typeof e=="undefined"){if(i)if((e=i.match(/scale\(([^)]+)\)/))&&e[1])return e[1];return 1}a(this).css("transform",i.replace(/none|scale\([^)]*\)/,"")+"scale("+e+")")};var f=a.fx.prototype.cur;a.fx.prototype.cur=function(){if(this.prop=="rotate")return parseFloat(a(this.elem).rotate());else if(this.prop=="scale")return parseFloat(a(this.elem).scale());return f.apply(this,arguments)};a.fx.step.rotate=function(e){a(e.elem).rotate(e.now+c)};a.fx.step.scale=function(e){a(e.elem).scale(e.now)};var d=
a.fn.animate;a.fn.animate=function(e){if(typeof e.rotate!="undefined"){var i=e.rotate.toString().match(/^(([+-]=)?(-?\d+(\.\d+)?))(.+)?$/);if(i&&i[5])c=i[5];e.rotate=i[1]}return d.apply(this,arguments)}})(jQuery);
(function(a){function c(d){for(var e=["transform","WebkitTransform","MozTransform"],i;i=e.shift();)if(typeof d.style[i]!="undefined")return i;return"transform"}var f=a.fn.css;a.fn.css=function(d){if(typeof a.props.transform=="undefined"&&(d=="transform"||typeof d=="object"&&typeof d.transform!="undefined"))a.props.transform=c(this.get(0));if(d=="transform")d=a.props.transform;return f.apply(this,arguments)}})(jQuery);