!/**
 * Highcharts JS v12.6.0 (2026-04-13)
 * @module highcharts/modules/series-label
 * @requires highcharts
 *
 * (c) 2009-2026 Highsoft AS
 * Author: Torstein Hønsi
 *
 * A commercial license may be required depending on use.
 * See www.highcharts.com/license
 */function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e(t._Highcharts,t._Highcharts.Templating):"function"==typeof define&&define.amd?define("highcharts/modules/series-label",["highcharts/highcharts"],function(t){return e(t,t.Templating)}):"object"==typeof exports?exports["highcharts/modules/series-label"]=e(t._Highcharts,t._Highcharts.Templating):t.Highcharts=e(t.Highcharts,t.Highcharts.Templating)}("u"<typeof window?this:window,function(t,e){return function(){"use strict";var r={944:function(e){e.exports=t},984:function(t){t.exports=e}},o={};function n(t){var e=o[t];if(void 0!==e)return e.exports;var a=o[t]={exports:{}};return r[t](a,a.exports,n),a.exports}n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,{a:e}),e},n.d=function(t,e){for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)};var a={};n.d(a,{default:function(){return P}});var i=n(944),h=n.n(i),s=n(984),c=n.n(s),l={enabled:!0,connectorAllowed:!1,connectorNeighbourDistance:24,format:void 0,formatter:void 0,minFontSize:null,maxFontSize:null,onArea:null,style:{fontSize:"0.8em",fontWeight:"bold"},useHTML:!1,boxesToAvoid:[]};function p(t,e,r,o,n,a){var i=(a-e)*(r-t)-(o-e)*(n-t);return i>0||!(i<0)}function f(t,e,r,o,n,a,i,h){return p(t,e,n,a,i,h)!==p(r,o,n,a,i,h)&&p(t,e,r,o,n,a)!==p(t,e,r,o,i,h)}var u=h().doc;function d(t,e,r,o){void 0===o&&(o={});var n="function"==typeof t&&t.prototype||t;Object.hasOwnProperty.call(n,"hcEvents")||(n.hcEvents={});var a=n.hcEvents;h().Point&&t instanceof h().Point&&t.series&&t.series.chart&&(t.series.chart.runTrackerClick=!0);var i=t.addEventListener;i&&i.call(t,e,r,!!h().supportsPassiveEvents&&{passive:void 0===o.passive?-1!==e.indexOf("touch"):o.passive,capture:!1}),a[e]||(a[e]=[]);var s={fn:r,order:"number"==typeof o.order?o.order:1/0};return a[e].push(s),a[e].sort(function(t,e){return t.order-e.order}),function(){!function(t,e,r){function o(e,r){var o=t.removeEventListener;o&&o.call(t,e,r,!1)}function n(r){var n,a;if(t.nodeName){e?(n={})[e]=!0:n=r;var i=n,h=function(t,e){if(r[e])for(a=r[e].length;a--;)o(e,r[e][a].fn)};for(var s in i)Object.hasOwnProperty.call(i,s)&&h.call(i[s],i[s],s,i)}}var a="function"==typeof t&&t.prototype||t;if(Object.hasOwnProperty.call(a,"hcEvents")){var i=a.hcEvents;if(e){var h=i[e]||[];r?(i[e]=h.filter(function(t){return r!==t.fn}),o(e,r)):(n(i),i[e]=[])}else n(i),delete a.hcEvents}}(t,e,r)}}function v(t,e){var r;for(r in t||(t={}),e)t[r]=e[r];return t}function x(t){return"number"==typeof t&&!isNaN(t)&&t<1/0&&t>-1/0}function g(){for(var t=arguments,e=t.length,r=0;r<e;r++){var o=t[r];if(null!=o)return o}}h().win,Array.prototype.find;var b=function(t,e,r){if(r||2==arguments.length)for(var o,n=0,a=e.length;n<a;n++)!o&&n in e||(o||(o=Array.prototype.slice.call(e,0,n)),o[n]=e[n]);return t.concat(o||Array.prototype.slice.call(e))},y=h().animObject,m=c().format,w=h().setOptions,X=h().composed,Y=function(t,e,r,o,n,a,i,h){return f(t,e,t+r,e,n,a,i,h)||f(t+r,e,t+r,e+o,n,a,i,h)||f(t,e+o,t+r,e+o,n,a,i,h)||f(t,e,t,e+o,n,a,i,h)};function M(t,e,r,o,n){var a,i,h,s,c,l,p,f,u,d=t.chart,v=t.options.label||{},x=g(v.onArea,!!t.area),y=x||v.connectorAllowed,m=d.boxesToAvoid,w=Number.MAX_VALUE,X=Number.MAX_VALUE;for(f=0;m&&f<m.length;f+=1){if(a=m[f],!((i={left:e,right:e+o.width,top:r,bottom:r+o.height}).left>a.right||i.right<a.left||i.top>a.bottom||i.bottom<a.top))return!1}for(f=0;f<d.series.length;f+=1){var M=d.series[f],A=M.interpolatedPoints&&b([],M.interpolatedPoints,!0);if(M.visible&&A){for(var E=d.plotHeight/10,S=d.plotTop;S<=d.plotTop+d.plotHeight;S+=E)A.unshift({chartX:d.plotLeft,chartY:S}),A.push({chartX:d.plotLeft+d.plotWidth,chartY:S});for(u=1;u<A.length;u+=1){if(A[u].chartX>=e-16&&A[u-1].chartX<=e+o.width+16){if(Y(e,r,o.width,o.height,A[u-1].chartX,A[u-1].chartY,A[u].chartX,A[u].chartY))return!1;t===M&&!c&&n&&(c=Y(e-16,r-16,o.width+32,o.height+32,A[u-1].chartX,A[u-1].chartY,A[u].chartX,A[u].chartY))}(y||c)&&(t!==M||x)&&(w=Math.min(w,(l=e+o.width/2-A[u].chartX)*l+(p=r+o.height/2-A[u].chartY)*p))}if(!x&&y&&t===M&&(n&&!c||w<Math.pow(v.connectorNeighbourDistance||1,2))){for(u=1;u<A.length;u+=1)(h=Math.min(Math.pow(e+o.width/2-A[u].chartX,2)+Math.pow(r+o.height/2-A[u].chartY,2),Math.pow(e-A[u].chartX,2)+Math.pow(r-A[u].chartY,2),Math.pow(e+o.width-A[u].chartX,2)+Math.pow(r-A[u].chartY,2),Math.pow(e+o.width-A[u].chartX,2)+Math.pow(r+o.height-A[u].chartY,2),Math.pow(e-A[u].chartX,2)+Math.pow(r+o.height-A[u].chartY,2)))<X&&(X=h,s=A[u]);c=!0}}}return(!n||!!c)&&{x:e,y:r,weight:w-(s?X:0),connectorPoint:s}}function A(t){if(this.renderer){var e,r,o,n=this,a=y(n.renderer.globalAnimation).duration;n.labelSeries=[],n.labelSeriesMaxSum=0,n.seriesLabelTimer&&null!=(e=n.seriesLabelTimer)&&clearTimeout(e),n.series.forEach(function(e){var r=e.options.label||{},o=e.labelBySeries,i=o&&o.closest,h=e.getColumn("y");r.enabled&&e.visible&&(e.graph||e.area)&&!e.boosted&&n.labelSeries&&(n.labelSeries.push(e),r.minFontSize&&r.maxFontSize&&h.length&&(e.sum=h.reduce(function(t,e){return(t||0)+(e||0)},0),n.labelSeriesMaxSum=Math.max(n.labelSeriesMaxSum||0,e.sum||0)),"load"===t.type&&(a=Math.max(a,y(e.options.animation).duration)),i&&(void 0!==i[0].plotX?o.animate({x:i[0].plotX+i[1],y:i[0].plotY+i[2]}):o.attr({opacity:0})))}),r=function(){var t,e;n.series&&n.labelSeries&&(n.boxesToAvoid=[],t=n.labelSeries||[],e=n.boxesToAvoid,n.series.forEach(function(t){return(t.points||[]).forEach(function(r){return(r.dataLabels||[]).forEach(function(r){var o=r.getBBox(),n=o.width,a=o.height,i=(r.translateX||0)+(t.xAxis?t.xAxis.pos:t.chart.plotLeft),h=(r.translateY||0)+(t.yAxis?t.yAxis.pos:t.chart.plotTop);e.push({left:i,top:h,right:i+n,bottom:h+a})})})}),t.forEach(function(t){var r=t.options.label||{};t.interpolatedPoints=function(t){if(t.xAxis||t.yAxis){var e,r,o,n,a,i,h=t.points,s=[],c=t.graph||t.area,l=c&&c.element,p=t.chart.inverted,f=t.xAxis,u=t.yAxis,d=p?u.pos:f.pos,v=p?f.pos:u.pos,b=p?f.len:u.len,y=p?u.len:f.len,m=g((t.options.label||{}).onArea,!!t.area),w=u.getThreshold(t.options.threshold),X={},Y=p?"chartCenterX":"chartCenterY";if(t.getPointSpline&&l&&l.getPointAtLength&&!m&&h.length<(t.chart.plotSizeX||0)/16){var M=c.toD&&c.attr("d");for(c.toD&&c.attr({d:c.toD}),n=l.getTotalLength(),r=0;r<n;r+=16){var A=l.getPointAtLength(r),E=p?y-A.y:A.x,S=p?b-A.x:A.y;H({chartX:d+E,chartY:v+S,plotX:E,plotY:S})}M&&c.attr({d:M});var P=h[h.length-1],T=P.pos();H({chartX:d+((null==T?void 0:T[0])||0),chartY:v+((null==T?void 0:T[1])||0)})}else{n=h.length;var L=void 0;for(r=0;r<n;r+=1){var P=h[r],O=P.pos()||[],E=O[0],S=O[1],B=P.plotHigh;if(x(E)&&x(S)){var C={plotX:E,plotY:S,chartX:d+E,chartY:v+S};if(m&&(B&&(C.plotY=B,C.chartY=v+B),p?C.chartCenterX=d+y-((B||P.plotY||0)+g(P.yBottom,w))/2:C.chartCenterY=v+((B||S)+g(P.yBottom,w))/2),L&&(o=Math.max(Math.abs(C.chartX-L.chartX),Math.abs(C.chartY-L.chartY)))>16&&o<999)for(i=1,a=Math.ceil(o/16);i<a;i+=1)H(((e={chartX:L.chartX+(C.chartX-L.chartX)*(i/a),chartY:L.chartY+(C.chartY-L.chartY)*(i/a)})[Y]=(L[Y]||0)+((C[Y]||0)-(L[Y]||0))*(i/a),e.plotX=(L.plotX||0)+(E-(L.plotX||0))*(i/a),e.plotY=(L.plotY||0)+(S-(L.plotY||0))*(i/a),e));H(C),L=C}}}return s}function H(t){var e=Math.round((t.plotX||0)/8)+","+Math.round((t.plotY||0)/8);X[e]||(X[e]=1,s.push(t))}}(t),e.push.apply(e,r.boxesToAvoid||[])}),n.series.forEach(function(t){var e=t.options.label;if(e&&(t.xAxis||t.yAxis)){var r,o,a,i,h,s,c,l,p,f,u,d="highcharts-color-"+g(t.colorIndex,"none"),x=!t.labelBySeries,b=e.minFontSize,w=e.maxFontSize,X=n.inverted,Y=X?t.yAxis.pos:t.xAxis.pos,A=X?t.xAxis.pos:t.yAxis.pos,E=n.inverted?t.yAxis.len:t.xAxis.len,S=n.inverted?t.xAxis.len:t.yAxis.len,P=t.interpolatedPoints,T=g(e.onArea,!!t.area),L=[],O=t.getColumn("x"),B=t.labelBySeries;if(T&&!X&&(p=[t.xAxis.toPixels(O[0]),t.xAxis.toPixels(O[O.length-1])],f=Math.min.apply(Math,p),u=Math.max.apply(Math,p)),t.visible&&!t.boosted&&P){if(!B){var C,H,j,z=t.name;if("string"==typeof e.format?z=m(e.format,t,n):e.formatter&&(z=e.formatter.call(t,t)),t.labelBySeries=B=n.renderer.label(z,0,0,"connector",0,0,e.useHTML).addClass("highcharts-series-label highcharts-series-label-"+t.index+" "+(t.options.className||"")+" "+d),!n.renderer.styledMode){var D="string"==typeof t.color?t.color:"#666666";B.css(v({color:T?n.renderer.getContrast(D):D},e.style||{})),B.attr({opacity:+!!n.renderer.forExport,stroke:t.color,"stroke-width":1})}b&&w&&B.css({fontSize:(C=t,H=b,j=w,H+(C.sum||0)/(C.chart.labelSeriesMaxSum||0)*(j-H)+"px")}),B.attr({padding:0,zIndex:3}).add()}for((a=B.getBBox()).width=Math.round(a.width),c=P.length-1;c>0;c-=1)T?I(i=(null!=(r=P[c].chartCenterX)?r:P[c].chartX)-a.width/2,h=(null!=(o=P[c].chartCenterY)?o:P[c].chartY)-a.height/2,a)&&(l=M(t,i,h,a)):(I(i=P[c].chartX+3,h=P[c].chartY-a.height-3,a)&&(l=M(t,i,h,a,!0)),l&&L.push(l),I(i=P[c].chartX+3,h=P[c].chartY+3,a)&&(l=M(t,i,h,a,!0)),l&&L.push(l),I(i=P[c].chartX-a.width-3,h=P[c].chartY+3,a)&&(l=M(t,i,h,a,!0)),l&&L.push(l),I(i=P[c].chartX-a.width-3,h=P[c].chartY-a.height-3,a)&&(l=M(t,i,h,a,!0))),l&&L.push(l);if(e.connectorAllowed&&!L.length&&!T)for(i=Y+E-a.width;i>=Y;i-=16)for(h=A;h<A+S-a.height;h+=16)(s=M(t,i,h,a,!0))&&L.push(s);if(L.length){L.sort(function(t,e){return e.weight-t.weight}),l=L[0],(n.boxesToAvoid||[]).push({left:l.x,right:l.x+a.width,top:l.y,bottom:l.y+a.height});var N=Math.sqrt(Math.pow(Math.abs(l.x-(B.x||0)),2)+Math.pow(Math.abs(l.y-(B.y||0)),2));if(N&&t.labelBySeries){var _={opacity:+!!n.renderer.forExport,x:l.x,y:l.y},F={opacity:1};N<=10&&(F={x:_.x,y:_.y},_={});var k=void 0;x&&(k=y(t.options.animation),k.duration*=.2),t.labelBySeries.attr(v(_,{anchorX:l.connectorPoint&&(l.connectorPoint.plotX||0)+Y,anchorY:l.connectorPoint&&(l.connectorPoint.plotY||0)+A})).animate(F,k),t.options.kdNow=!0,t.buildKDTree();var V=t.searchPoint({chartX:l.x,chartY:l.y},!0);V&&(B.closest=[V,l.x-(V.plotX||0),l.y-(V.plotY||0)])}}else U()}else U()}function I(t,e,r){var o=Math.max(Y,g(f,-1/0)),n=Math.min(Y+E,g(u,1/0));return t>o&&t<=n-r.width&&e>=A&&e<=A+S-r.height}function U(){B&&(t.labelBySeries=B.destroy())}}),function(t,e,r,o){if(r=r||{},(null==u?void 0:u.createEvent)&&(t.dispatchEvent||t.fireEvent&&t!==h())){var n=u.createEvent("Events");n.initEvent(e,!0,!0),r=v(n,r),t.dispatchEvent?t.dispatchEvent(r):t.fireEvent(e,r)}else if(t.hcEvents){r.target||v(r,{preventDefault:function(){r.defaultPrevented=!0},target:t,type:e});for(var a=[],i=t,s=!1;i.hcEvents;)Object.hasOwnProperty.call(i,"hcEvents")&&i.hcEvents[e]&&(a.length&&(s=!0),a.unshift.apply(a,i.hcEvents[e])),i=Object.getPrototypeOf(i);s&&a.sort(function(t,e){return t.order-e.order}),a.forEach(function(e){!1===e.fn.call(t,r,t)&&r.preventDefault()})}}(n,"afterDrawSeriesLabels"))},n.seriesLabelTimer=(o=n.renderer.forExport||!a?0:a)>0?setTimeout(r,o,void 0):(r.call(0,void 0),-1)}}function E(t,e,r,o,n){var a,i,h=n&&n.anchorX,s=n&&n.anchorY,c=r/2;return x(h)&&x(s)&&(a=[["M",h,s]],(i=e-s)<0&&(i=-o-i),i<r&&(c=h<t+r/2?i:r-i),s>e+o?a.push(["L",t+c,e+o]):s<e?a.push(["L",t+c,e]):h<t?a.push(["L",t,e+o/2]):h>t+r&&a.push(["L",t+r,e+o/2])),a||[]}var S=h();({compose:function(t,e){var r;r="SeriesLabel",0>X.indexOf(r)&&X.push(r)&&(d(t,"load",A),d(t,"redraw",A),e.prototype.symbols.connector=E,w({plotOptions:{series:{label:l}}}))}}).compose(S.Chart,S.SVGRenderer);var P=h();return a.default}()});