/* Neo Charts */

/* Generic */

.p-neo-charts.is-transparent { box-shadow:none; }
.is-transparent > .nc-chart { background-color:transparent; }
.nc-chart { --nc-bg:#1a1a2e; --nc-text:rgba(255,255,255,.85); --nc-text-muted:rgba(255,255,255,.7); --nc-text-dim:rgba(255,255,255,.6); --nc-text-faint:rgba(255,255,255,.5); --nc-border:rgba(255,255,255,.08); --nc-border-strong:rgba(255,255,255,.15); --nc-tooltip-bg:rgba(15,15,30,.95); --nc-tooltip-text:rgba(255,255,255,.9); background-color:transparent; overflow:visible; font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif; padding:20px 24px; display:flex; flex-direction:column; gap:16px; }
.nc-chart, .nc-chart * { box-sizing:border-box }
.nc-chart .nc-title { width:100%; padding:0; flex-shrink:0; text-align:right; font-weight:600; font-size:16px; color:var(--nc-text) }
.nc-chart .nc-subtitle { font-size:12px; font-weight:400; color:var(--nc-text-muted); margin-top:2px; }

/* Light theme */
.nc-chart.nc-light { --nc-bg:#ffffff; --nc-text:rgba(0,0,0,.85); --nc-text-muted:rgba(0,0,0,.65); --nc-text-dim:rgba(0,0,0,.58); --nc-text-faint:rgba(0,0,0,.55); --nc-border:rgba(0,0,0,.08); --nc-border-strong:rgba(0,0,0,.15); --nc-tooltip-bg:rgba(255,255,255,.95); --nc-tooltip-text:rgba(0,0,0,.85); }

.nc-chart-body { flex:1; min-height:0; display:flex; flex-direction:column; }
.nc-empty { width:100%; height:100%; display:flex; align-items:center; justify-content:center; font-size:14px; font-weight:400; color:var(--nc-text-faint); margin:0; }

.nc-item { background-color:#00aeef; cursor:pointer; }
.nc-item:hover { z-index:1000; }
.nc-item:hover .nc-tooltip { display:block; }
.nc-item .nc-main .nc-label { font-size:12px; color:var(--nc-text-muted); text-align:center }
.nc-item .nc-main .nc-value { font-size:12px; font-weight:600; color:var(--nc-text); }

.nc-tooltip { display:none; position:absolute; bottom:100%; left:50%; transform:translateX(-50%); white-space:nowrap; padding:8px 12px; font-size:12px; background-color:var(--nc-tooltip-bg); border:1px solid var(--nc-border-strong); border-radius:8px; box-shadow:0 4px 20px rgba(0,0,0,.15); backdrop-filter:blur(8px); transition:opacity .2s; color:var(--nc-tooltip-text); z-index:100; margin-bottom:6px; pointer-events:none; }
.nc-tooltip-header { font-size:11px; font-weight:600; color:var(--nc-text-dim); text-transform:uppercase; letter-spacing:1px; margin-bottom:4px; }
.nc-tooltip-row { display:flex; align-items:center; gap:8px; }
.nc-tooltip-dot { width:8px; height:8px; border-radius:50%; flex-shrink:0; }
.nc-tooltip-series { font-size:12px; color:var(--nc-text-muted); }
.nc-tooltip-value { font-size:12px; font-weight:700; color:var(--nc-text); margin-left:auto; }
.nc-tooltip-arrow { position:absolute; bottom:-4px; left:50%; transform:translateX(-50%) rotate(45deg); width:8px; height:8px; background-color:var(--nc-tooltip-bg); border-right:1px solid var(--nc-border-strong); border-bottom:1px solid var(--nc-border-strong); }

/* Highlight: dim siblings on hover */
.has-highlight .nc-canvas:hover .nc-item { opacity:.3; transition:opacity .25s; }
.has-highlight .nc-canvas:hover .nc-item:hover { opacity:1; }
.has-highlight .nc-canvas:hover .nc-stack { opacity:.3; transition:opacity .25s; }
.has-highlight .nc-canvas:hover .nc-stack:hover { opacity:1; }

.nc-threshold { position:absolute; left:0; right:0; bottom:0; border-top:1px dotted #f55; background-image:linear-gradient(rgba(255, 85, 85, .1), transparent) }

.nc-guidelines { position:absolute; top:0; right:0; bottom:0; left:0; overflow:visible; z-index:1; pointer-events:none; }
.nc-guidelines .nc-guideline { position:absolute; z-index:0; border:0 solid var(--nc-border); }
.nc-guidelines .nc-label { position:absolute; font-size:11px; color:var(--nc-text-dim); white-space:nowrap; }

/* Horizontal guidelines (column, line, area) */
.nc-guidelines .is-horizontal { border-top-width:1px; }
.nc-guidelines .is-horizontal .is-right-aligned { right:0; top:-8px; transform:translateX(100%); padding-left:8px; }
.nc-guidelines .is-horizontal .is-left-aligned { left:0; top:-8px; transform:translateX(-100%); padding-right:8px; }

/* Vertical guidelines (bar, progress, waterfall) */
.nc-guidelines .is-vertical { border-right-width:1px; }
.nc-guidelines .is-vertical .nc-label { bottom:-18px; left:50%; transform:translateX(-50%); text-align:center; }
.nc-guidelines .is-vertical.is-first .nc-label { left:0; transform:none; text-align:left; }
.nc-guidelines .is-vertical.is-last .nc-label { left:auto; right:0; transform:none; text-align:right; }


/* Column */
.nc-column .nc-chart-body { display:grid; grid-template-columns:1fr auto; grid-template-rows:1fr auto; gap:16px; }
.nc-column .nc-plot { grid-column:1; grid-row:1; position:relative; min-height:0; min-width:0; }
.nc-column .nc-group { display:flex; align-items:flex-end; position:absolute; bottom:0; }
.nc-column .nc-stack { position:absolute; bottom:0; display:flex; flex-direction:column-reverse; }
.nc-column .nc-item { text-align:center; border-radius:1px; transition:all .3s; position:relative; }
.nc-column .nc-main .nc-value { position:absolute; top:-18px; left:0; width:100%; }
.nc-column .nc-tooltip { bottom:calc(100% + 18px); }
.nc-baseline { position:absolute; left:0; right:0; border-top:1px solid var(--nc-border-strong); z-index:1; pointer-events:none; }

/* Bar */
.nc-bar .nc-chart-body { display:grid; grid-template-columns:auto 1fr; grid-template-rows:1fr auto; gap:16px; }
.nc-bar .nc-yaxis { grid-column:1; grid-row:1; display:flex; flex-direction:column; justify-content:stretch; min-width:0; max-width:150px; }
.nc-bar .nc-yaxis .nc-label-item { flex:1; display:block; font-size:12px; color:var(--nc-text-muted); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; text-align:right; min-height:0; cursor:pointer; line-height:1; }
.nc-bar .nc-yaxis .nc-label-group { flex:1; display:flex; align-items:center; justify-content:flex-end; font-size:12px; font-weight:600; color:var(--nc-text-muted); min-height:0; cursor:pointer; min-width:0; }
.nc-bar .nc-plot { grid-column:2; grid-row:1; position:relative; min-height:0; min-width:0; overflow:visible; }
.nc-bar .nc-group { position:relative; }
.nc-bar .nc-stack { display:flex; flex:1; }
.nc-bar .nc-item { border-radius:15px; position:relative; min-height:0; }
.nc-bar .nc-main .nc-value { position:absolute; left:100%; top:50%; transform:translateY(-50%); padding-left:6px; white-space:nowrap; font-size:12px; }
.nc-bar .nc-tooltip { left:auto; right:0; transform:none; bottom:100%; margin-bottom:4px; }
.nc-bar .nc-tooltip .nc-tooltip-arrow { left:auto; right:16px; }
.nc-bar .nc-footer { grid-column:2 / -1; }
.nc-bar.is-stacked .nc-stack { position:relative; }
.nc-bar.is-stacked .nc-item { border-radius:0; flex:none; }
.nc-bar.is-stacked .nc-stack .nc-item:first-child { border-radius:15px 0 0 15px; }
.nc-bar.is-stacked .nc-stack .nc-item:last-child { border-radius:0 15px 15px 0; }

/* Progress */
.nc-progress .nc-chart-body { justify-content:center; }
.nc-progress .nc-plot { position:relative; width:100%; height:20px; margin:30px 0; flex-shrink:0; }
.nc-progress.is-fit .nc-plot { height:auto; flex:1; margin:30px 0; }
.nc-progress .nc-item { position:absolute; height:100%; border-right:none; border-top-color:var(--nc-border); overflow:visible; }
.nc-progress .nc-main { display:block; position:relative; width:100%; height:100%; }
.nc-progress .nc-item:first-child { border-radius:3px 0 0 3px }
.nc-progress .nc-item:last-child { border-radius:0 3px 3px 0 }
.nc-progress .nc-main .nc-label { position:absolute; bottom:-28px; left:0; width:100%; height:24px; font-size:11px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.nc-progress .nc-main .nc-value { position:absolute; top:-22px; left:0; width:100%; text-align:left; font-size:12px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.nc-progress .nc-tooltip { bottom:calc(100% + 22px); }

/* Waterfall */
.nc-waterfall .nc-chart-body { display:grid; grid-template-columns:auto 1fr; grid-template-rows:1fr auto; gap:16px; }
.nc-waterfall .nc-yaxis { grid-column:1; grid-row:1; display:flex; flex-direction:column; justify-content:stretch; min-width:0; max-width:150px; }
.nc-waterfall .nc-yaxis .nc-label-item { flex:1; display:block; font-size:12px; color:var(--nc-text-muted); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; text-align:right; min-height:0; cursor:pointer; line-height:1; }
.nc-waterfall .nc-plot { grid-column:2; grid-row:1; position:relative; min-height:0; min-width:0; overflow:visible; }
.nc-waterfall .nc-item { position:relative; min-height:0; border-radius:15px; }
.nc-waterfall .nc-main .nc-value { position:absolute; left:100%; top:50%; transform:translateY(-50%); padding-left:6px; white-space:nowrap; font-size:12px; }
.nc-waterfall .nc-tooltip { left:auto; right:0; transform:none; bottom:100%; margin-bottom:4px; }
.nc-waterfall .nc-tooltip .nc-tooltip-arrow { left:auto; right:16px; }
.nc-waterfall .nc-footer { grid-column:2 / -1; }

/* Line & Area */
.nc-linechart .nc-chart-body, .nc-area .nc-chart-body { display:grid; grid-template-columns:1fr auto; grid-template-rows:1fr auto; gap:16px; }
.nc-linechart .nc-plot, .nc-area .nc-plot { grid-column:1; grid-row:1; position:relative; min-height:0; min-width:0; overflow:visible; }
.nc-area-fill { position:absolute; top:0; left:0; width:100%; height:100%; opacity:.25; }
.nc-line-segment { position:absolute; height:2px; transform-origin:0 50%; border-radius:1px; transition:left .3s, top .3s, width .3s, transform .3s; }
.nc-dot { position:absolute; width:10px; height:10px; margin-left:-5px; margin-top:-5px; border-radius:50%; background-color:var(--nc-bg, #1a1a2e); border:2px solid; cursor:pointer; z-index:2; transition:transform .2s; }
.nc-dot:hover { transform:scale(1.6); z-index:1000; }
.nc-dot .nc-tooltip { left:50%; bottom:100%; top:auto; transform:translateX(-50%); margin-bottom:8px; }
.nc-dot:hover .nc-tooltip { display:block; margin-top:-6px; transform:translateX(-50%) scale(0.625); transform-origin:bottom center; }
.has-highlight .nc-canvas:hover .nc-dot { opacity:.3; transition:opacity .25s; }
.has-highlight .nc-canvas:hover .nc-dot:hover { opacity:1; }
.has-highlight .nc-canvas:hover .nc-line-segment { opacity:.3; transition:opacity .25s; }
.has-highlight .nc-canvas:hover .nc-area-fill { opacity:.05; transition:opacity .25s; }

/* Axis labels (grid layout) */
.nc-yaxis { grid-column:2; grid-row:1; display:flex; flex-direction:column; justify-content:space-between; min-width:0; }
.nc-xaxis { display:flex; justify-content:space-between; overflow:hidden; min-width:0; }
.nc-xaxis .nc-axis-label { min-width:0; }
.nc-axis-label { font-size:11px; color:var(--nc-text-dim); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }

/* Heatmap */
.nc-heatmap .nc-plot { position:relative; width:100%; flex:1; min-height:0; padding:0 0 0 80px; display:grid; grid-template-rows:auto 1fr; gap:0; }
.nc-heatmap-col-labels { display:grid; gap:2px; padding-bottom:8px; min-width:0; }
.nc-heatmap-col-label { font-size:11px; font-weight:600; color:var(--nc-text-muted); text-align:center; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; min-width:0; }
.nc-heatmap-grid { display:grid; gap:2px; position:relative; min-width:0; min-height:0; }
.nc-heatmap-cell { position:relative; display:flex; align-items:center; justify-content:center; border-radius:3px; cursor:pointer; transition:filter .2s, transform .15s; min-height:0; min-width:0; overflow:hidden; }
.nc-heatmap-cell:hover { transform:scale(1.05); z-index:10; }
.nc-heatmap-cell:hover .nc-tooltip { display:block; margin-top:-6px; }
.nc-heatmap-cell .nc-tooltip { left:50%; bottom:100%; top:auto; transform:translateX(-50%); margin-bottom:8px; }
.nc-heatmap-value { font-size:11px; font-weight:600; color:#fff; text-shadow:0 1px 3px rgba(0,0,0,.5); overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.nc-light .nc-heatmap-value { color:#1c1c1e; text-shadow:none; }
.nc-heatmap-row-labels { position:absolute; left:0; top:0; bottom:0; width:70px; display:grid; padding-top:28px; gap:2px; }
.nc-heatmap-row-label { font-size:11px; font-weight:600; color:var(--nc-text-muted); display:flex; align-items:center; justify-content:flex-end; padding-right:10px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.has-highlight .nc-heatmap-grid:hover .nc-heatmap-cell { filter:brightness(.5) saturate(.3); transition:filter .25s, transform .15s; }
.has-highlight .nc-heatmap-grid:hover .nc-heatmap-cell:hover { filter:brightness(1.1) saturate(1.2); outline:2px solid var(--nc-text); outline-offset:-1px; }

/* Treemap */
.nc-treemap .nc-plot { position:relative; width:100%; flex:1; min-height:0; }
.nc-treemap-cell { position:absolute; display:flex; flex-direction:column; align-items:center; justify-content:center; cursor:pointer; overflow:hidden; transition:opacity .2s, filter .2s; }
.nc-treemap-cell:hover { z-index:10; filter:brightness(1.2); }
.nc-treemap-cell:hover .nc-tooltip { display:block; margin-top:-6px; }
.nc-treemap-cell .nc-tooltip { left:50%; bottom:100%; top:auto; transform:translateX(-50%); margin-bottom:8px; }
.nc-treemap-label { font-size:12px; font-weight:600; color:#fff; text-shadow:0 1px 3px rgba(0,0,0,.5); text-align:center; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; max-width:90%; }
.nc-light .nc-treemap-label { color:#1c1c1e; text-shadow:none; }
.nc-treemap-value { font-size:11px; color:rgba(255,255,255,.85); text-shadow:0 1px 3px rgba(0,0,0,.5); }
.nc-light .nc-treemap-value { color:rgba(0,0,0,.7); text-shadow:none; }
.has-highlight .nc-canvas:hover .nc-treemap-cell { opacity:.3; transition:opacity .25s, filter .2s; }
.has-highlight .nc-canvas:hover .nc-treemap-cell:hover { opacity:1; }

/* Footer (x-axis + legend) — always rendered for consistent height across sibling charts */
.nc-footer { grid-column:1 / -1; min-height:24px; display:flex; flex-direction:column; gap:8px; }

/* Legend */
.nc-legend { width:100%; display:flex; flex-wrap:wrap; gap:16px; justify-content:center; flex-shrink:0; }
.nc-legend-item { display:flex; align-items:center; gap:6px; }
.nc-legend-dot { width:8px; height:8px; border-radius:50%; flex-shrink:0; }
.nc-legend-label { font-size:12px; color:var(--nc-text-muted); }

/* Animation */
@keyframes nc-grow-up { from { transform:scaleY(0); } to { transform:scaleY(1); } }
@keyframes nc-grow-right { from { transform:scaleX(0); } to { transform:scaleX(1); } }
@keyframes nc-fade-in { from { opacity:0; } to { opacity:1; } }
.nc-animate.nc-column .nc-item { animation:nc-grow-up .6s ease-out both; transform-origin:bottom; }
.nc-animate.nc-bar .nc-item { animation:nc-grow-right .6s ease-out both; transform-origin:left; }
.nc-animate.nc-progress .nc-item { animation:nc-grow-right .6s ease-out both; transform-origin:left; }
.nc-animate.nc-waterfall .nc-item { animation:nc-grow-right .6s ease-out both; transform-origin:left; }
.nc-animate.nc-linechart .nc-dot,
.nc-animate.nc-area .nc-dot { animation:nc-fade-in .4s ease-out both; }
.nc-animate.nc-linechart .nc-line-segment,
.nc-animate.nc-area .nc-line-segment { animation:nc-fade-in .4s ease-out both; }
.nc-animate.nc-area .nc-area-fill { animation:nc-fade-in .6s ease-out both; }
.nc-animate.nc-heatmap .nc-heatmap-cell { animation:nc-fade-in .4s ease-out both; }
.nc-animate.nc-treemap .nc-treemap-cell { animation:nc-fade-in .4s ease-out both; }

/* Gauge */
.nc-gauge.nc-chart { position:relative; background-color:transparent; border-radius:16px; overflow:visible; }
.nc-gauge .nc-title { padding:0 0 10px; color:var(--nc-text); }
.nc-gauge .nc-plot { position:relative; flex:1; min-height:0; display:flex; align-items:center; justify-content:center; }
.nc-gauge .nc-ring { position:relative; border-radius:50%; aspect-ratio:1; height:100%; max-width:100%; -webkit-mask:radial-gradient(circle closest-side, transparent calc(100% - var(--gauge-thickness, 14px)), #000 calc(100% - var(--gauge-thickness, 14px) + 1px)); mask:radial-gradient(circle closest-side, transparent calc(100% - var(--gauge-thickness, 14px)), #000 calc(100% - var(--gauge-thickness, 14px) + 1px)); }
.nc-gauge .nc-ring-content { position:absolute; inset:0; display:flex; flex-direction:column; align-items:center; justify-content:center; z-index:1; }
.nc-gauge .nc-ring-content .nc-label { font-size:11px; font-weight:600; text-transform:uppercase; letter-spacing:2px; color:var(--nc-text-muted); margin-bottom:4px; }
.nc-gauge .nc-ring-content .nc-value { font-size:var(--gauge-value-size, 48px); font-weight:700; color:var(--nc-text); line-height:1; }