/* Highcharts JS v5.0.9 (2017-03-08) 3D features for Highcharts JS @license: www.highcharts.com/license */ (function(t){"object"===typeof module&&module.exports?module.exports=t:t(Highcharts)})(function(t){(function(b){var r=b.deg2rad,d=b.pick;b.perspective=function(p,q,y){var h=q.options.chart.options3d,m=y?q.inverted:!1,l=q.plotWidth/2,e=q.plotHeight/2,f=h.depth/2,n=d(h.depth,1)*d(h.viewDistance,0),c=q.scale3d||1,a=r*h.beta*(m?-1:1),h=r*h.alpha*(m?-1:1),k=Math.cos(h),u=Math.cos(-a),z=Math.sin(h),A=Math.sin(-a);y||(l+=q.plotLeft,e+=q.plotTop);return b.map(p,function(a){var b,h;h=(m?a.y:a.x)-l;var d=(m? a.x:a.y)-e,p=(a.z||0)-f;b=u*h-A*p;a=-z*A*h+k*d-u*z*p;h=k*A*h+z*d+k*u*p;d=0b&&E-b>Math.PI/2+.0001?(e=e.concat(p(a,c,g,D,b,b+Math.PI/2,k,f)),e=e.concat(p(a,c,g,D,b+Math.PI/2,E,k,f))):EMath.PI/2+.0001?(e=e.concat(p(a,c,g,D,b,b-Math.PI/2,k,f)),e=e.concat(p(a,c,g,D,b-Math.PI/2,E,k,f))):["C",a+g*Math.cos(b)-g*v*G*Math.sin(b)+k,c+D*Math.sin(b)+D*v*G*Math.cos(b)+f,a+g*Math.cos(E)+g*v*G*Math.sin(E)+k,c+D*Math.sin(E)- D*v*G*Math.cos(E)+f,a+g*Math.cos(E)+k,c+D*Math.sin(E)+f]}var q=Math.cos,y=Math.PI,h=Math.sin,m=b.animObject,l=b.charts,e=b.color,f=b.defined,n=b.deg2rad,c=b.each,a=b.extend,k=b.inArray,u=b.map,z=b.merge,A=b.perspective,t=b.pick,H=b.SVGElement,C=b.SVGRenderer,w=b.wrap,v=4*(Math.sqrt(2)-1)/3/(y/2);w(C.prototype,"init",function(a){a.apply(this,[].slice.call(arguments,1));c([{name:"darker",slope:.6},{name:"brighter",slope:1.4}],function(a){this.definition({tagName:"filter",id:"highcharts-"+a.name,children:[{tagName:"feComponentTransfer", children:[{tagName:"feFuncR",type:"linear",slope:a.slope},{tagName:"feFuncG",type:"linear",slope:a.slope},{tagName:"feFuncB",type:"linear",slope:a.slope}]}]})},this)});C.prototype.toLinePath=function(a,b){var g=[];c(a,function(a){g.push("L",a.x,a.y)});a.length&&(g[0]="M",b&&g.push("Z"));return g};C.prototype.cuboid=function(a){var c=this.g(),g=c.destroy;a=this.cuboidPath(a);c.front=this.path(a[0]).attr({"class":"highcharts-3d-front",zIndex:a[3]}).add(c);c.top=this.path(a[1]).attr({"class":"highcharts-3d-top", zIndex:a[4]}).add(c);c.side=this.path(a[2]).attr({"class":"highcharts-3d-side",zIndex:a[5]}).add(c);c.fillSetter=function(a){this.front.attr({fill:a});this.top.attr({fill:e(a).brighten(.1).get()});this.side.attr({fill:e(a).brighten(-.1).get()});this.color=a;return this};c.opacitySetter=function(a){this.front.attr({opacity:a});this.top.attr({opacity:a});this.side.attr({opacity:a});return this};c.attr=function(a,c){if("string"===typeof a&&"undefined"!==typeof c){var g=a;a={};a[g]=c}if(a.shapeArgs|| f(a.x))a=this.renderer.cuboidPath(a.shapeArgs||a),this.front.attr({d:a[0],zIndex:a[3]}),this.top.attr({d:a[1],zIndex:a[4]}),this.side.attr({d:a[2],zIndex:a[5]});else return b.SVGElement.prototype.attr.call(this,a);return this};c.animate=function(a,c,g){f(a.x)&&f(a.y)?(a=this.renderer.cuboidPath(a),this.front.attr({zIndex:a[3]}).animate({d:a[0]},c,g),this.top.attr({zIndex:a[4]}).animate({d:a[1]},c,g),this.side.attr({zIndex:a[5]}).animate({d:a[2]},c,g),this.attr({zIndex:-a[6]})):a.opacity?(this.front.animate(a, c,g),this.top.animate(a,c,g),this.side.animate(a,c,g)):H.prototype.animate.call(this,a,c,g);return this};c.destroy=function(){this.front.destroy();this.top.destroy();this.side.destroy();return g.call(this)};c.attr({zIndex:-a[6]});return c};C.prototype.cuboidPath=function(a){function c(a){return n[a]}var g=a.x,b=a.y,k=a.z,f=a.height,e=a.width,h=a.depth,n=[{x:g,y:b,z:k},{x:g+e,y:b,z:k},{x:g+e,y:b+f,z:k},{x:g,y:b+f,z:k},{x:g,y:b+f,z:k+h},{x:g+e,y:b+f,z:k+h},{x:g+e,y:b,z:k+h},{x:g,y:b,z:k+h}],n=A(n,l[this.chartIndex], a.insidePlotArea),k=function(a,b){var g=[];a=u(a,c);b=u(b,c);0>r(a)?g=a:0>r(b)&&(g=b);return g};a=k([3,2,1,0],[7,6,5,4]);g=[4,5,2,3];b=k([1,6,7,0],g);k=k([1,2,5,6],[0,7,4,3]);return[this.toLinePath(a,!0),this.toLinePath(b,!0),this.toLinePath(k,!0),d(a),d(b),d(k),9E9*d(u(g,c))]};b.SVGRenderer.prototype.arc3d=function(b){function f(a){var c=!1,b={},g;for(g in a)-1!==k(g,l)&&(b[g]=a[g],delete a[g],c=!0);return c?b:!1}var g=this.g(),h=g.renderer,l="x y r innerR start end".split(" ");b=z(b);b.alpha*=n; b.beta*=n;g.top=h.path();g.side1=h.path();g.side2=h.path();g.inn=h.path();g.out=h.path();g.onAdd=function(){var a=g.parentGroup,b=g.attr("class");g.top.add(g);c(["out","inn","side1","side2"],function(c){g[c].addClass(b+" highcharts-3d-side").add(a)})};g.setPaths=function(a){var c=g.renderer.arc3dPath(a),b=100*c.zTop;g.attribs=a;g.top.attr({d:c.top,zIndex:c.zTop});g.inn.attr({d:c.inn,zIndex:c.zInn});g.out.attr({d:c.out,zIndex:c.zOut});g.side1.attr({d:c.side1,zIndex:c.zSide1});g.side2.attr({d:c.side2, zIndex:c.zSide2});g.zIndex=b;g.attr({zIndex:b});a.center&&(g.top.setRadialReference(a.center),delete a.center)};g.setPaths(b);g.fillSetter=function(a){var c=e(a).brighten(-.1).get();this.fill=a;this.side1.attr({fill:c});this.side2.attr({fill:c});this.inn.attr({fill:c});this.out.attr({fill:c});this.top.attr({fill:a});return this};c(["opacity","translateX","translateY","visibility"],function(a){g[a+"Setter"]=function(a,b){g[b]=a;c(["out","inn","side1","side2","top"],function(c){g[c].attr(b,a)})}}); w(g,"attr",function(c,b){var k;"object"===typeof b&&(k=f(b))&&(a(g.attribs,k),g.setPaths(g.attribs));return c.apply(this,[].slice.call(arguments,1))});w(g,"animate",function(a,c,b,g){var k,e=this.attribs,h;delete c.center;delete c.z;delete c.depth;delete c.alpha;delete c.beta;h=m(t(b,this.renderer.globalAnimation));h.duration&&(c=z(c),k=f(c),c.dummy=1,k&&(h.step=function(a,c){function b(a){return e[a]+(t(k[a],e[a])-e[a])*c.pos}"dummy"===c.prop&&c.elem.setPaths(z(e,{x:b("x"),y:b("y"),r:b("r"),innerR:b("innerR"), start:b("start"),end:b("end")}))}),b=h);return a.call(this,c,b,g)});g.destroy=function(){this.top.destroy();this.out.destroy();this.inn.destroy();this.side1.destroy();this.side2.destroy();H.prototype.destroy.call(this)};g.hide=function(){this.top.hide();this.out.hide();this.inn.hide();this.side1.hide();this.side2.hide()};g.show=function(){this.top.show();this.out.show();this.inn.show();this.side1.show();this.side2.show()};return g};C.prototype.arc3dPath=function(a){function c(a){a%=2*Math.PI;a>Math.PI&& (a=2*Math.PI-a);return a}var b=a.x,k=a.y,f=a.start,e=a.end-.00001,n=a.r,l=a.innerR,m=a.depth,d=a.alpha,u=a.beta,z=Math.cos(f),r=Math.sin(f);a=Math.cos(e);var A=Math.sin(e),x=n*Math.cos(u),n=n*Math.cos(d),v=l*Math.cos(u),w=l*Math.cos(d),l=m*Math.sin(u),B=m*Math.sin(d),m=["M",b+x*z,k+n*r],m=m.concat(p(b,k,x,n,f,e,0,0)),m=m.concat(["L",b+v*a,k+w*A]),m=m.concat(p(b,k,v,w,e,f,0,0)),m=m.concat(["Z"]),C=0-C?f:e>-C?-C:f,F=et&&fy-u&&fl&&(v=Math.min(v,1-Math.abs((e+d)/(l+d))%1));cq&&(v=0>q?Math.min(v,(a+h)/(-q+a+h)):Math.min(v,1-(a+h)/(q+h)%1));k=l.min&&n<=l.max:!1,e.push({x:f.plotX,y:f.plotY,z:f.plotZ});h=r(e,h,!0);for(c=0;c