/* Ekalix Radar - the chart kit's material (CONTRACT-V30, Amendment 1; the start of P4, used first by the overview).

   ONE LIGHT, FROM THE TOP LEFT, for every instrument and chart on a page. A thing that stands proud of the page
   (a bezel, a lit arc, a bead) is lighter toward the light and darker away from it; a thing let into the page (a
   track, an instrument's face, a groove) is the other way round - shadowed under its top-left wall, catching the
   light on its bottom-right one. Something that is ON (a lit line, a healthy arc, a live bead) carries a soft glow of
   its own colour.

   Everything here is a still picture, and it is CHEAP TO DRAW THE FIRST TIME: no filter and no blurred shadow
   anywhere (a trace of a first visit in a new browser profile, 12 Nov 2026: the look's live blurs and blurred shadows
   made the graphics process compile 26 more shader programs - about two seconds before the first smooth frame; a glow
   is three wider, fainter copies of the line, a shadow is a hard line). Nothing in
   this file animates, so it looks the same in a Remote Desktop session, without a graphics card and with
   Animation: Off. Movement belongs to the page that uses the kit, and stays transform and opacity.

   Tokens --ck-*; classes ck-*; colours come from the theme's own tokens and the .t-<tone> classes (--tone), so every
   theme follows, and only Daylight - the one light theme - restates the light and the shade. chartkit.js holds the
   matching SVG pieces (the gradients that follow currentColor, the one glow filter, the path helpers). */
:root {
  --ck-hi:       rgba(255, 255, 255, .32);                             /* the light on an edge that faces it */
  --ck-hi-soft:  rgba(255, 255, 255, .09);
  --ck-lo:       rgba(0, 0, 0, .62);                                   /* the shade on an edge that faces away */
  --ck-lo-soft:  rgba(0, 0, 0, .30);
  --ck-drop:     rgba(0, 0, 0, .50);                                   /* the shadow a raised thing leaves on the page */
  --ck-groove:   color-mix(in srgb, var(--bg) 72%, #000);              /* the floor of a track or a channel */
  --ck-face-a:   color-mix(in srgb, var(--surface-1) 72%, #000);       /* an instrument's recessed face, under its top-left rim */
  --ck-face-b:   color-mix(in srgb, var(--surface-3) 88%, var(--text));/* ...and where the light reaches it */
  --ck-metal-a:  color-mix(in srgb, var(--text) 42%, var(--surface-3));/* a bezel: toward the light, its body, away from the light */
  --ck-metal-b:  color-mix(in srgb, var(--text) 13%, var(--surface-2));
  --ck-metal-c:  color-mix(in srgb, #000 58%, var(--surface-1));
  --ck-glass:    .13;                                                  /* the highlight on an instrument's glass */
  --ck-glow:     .62;                                                  /* how strongly a lit thing glows */
  --ck-sheen-a:  .46;                                                  /* a lit surface: the light on it, the shade on it */
  --ck-sheen-b:  .34;
}
:root[data-theme="daylight"] {
  --ck-hi:       rgba(255, 255, 255, .96);
  --ck-hi-soft:  rgba(255, 255, 255, .72);
  --ck-lo:       rgba(24, 44, 76, .36);
  --ck-lo-soft:  rgba(24, 44, 76, .17);
  --ck-drop:     rgba(24, 44, 76, .26);
  --ck-groove:   #cfd8e3;
  --ck-face-a:   #dde4ed;
  --ck-face-b:   #fbfcfe;
  --ck-metal-a:  #ffffff;
  --ck-metal-b:  #dfe6ee;
  --ck-metal-c:  #a3b0c1;
  --ck-glass:    .55;
  --ck-glow:     .30;
  --ck-sheen-a:  .28;
  --ck-sheen-b:  .15;
}

/* ---- a track let into the page, and the lit fill that runs in it ---- */
/* (its two edge lines and the fill's two bands are plain colours laid as one-colour images: an inset shadow, even an
   unblurred one, is a kind of drawing of its own) */
.ck-track { position: relative; overflow: hidden; border-radius: 6px; background-color: var(--ck-groove);
  background-image: linear-gradient(var(--ck-lo), var(--ck-lo)), linear-gradient(var(--ck-hi-soft), var(--ck-hi-soft));
  background-size: 100% 1px, 100% 1px; background-position: 0 0, 0 100%; background-repeat: no-repeat; }
.ck-fill { position: absolute; inset: 0; border-radius: inherit; background-color: var(--tone);   /* a band of light, a band of shade */
  background-image: linear-gradient(rgba(255, 255, 255, calc(var(--ck-sheen-a) * .62)), rgba(255, 255, 255, calc(var(--ck-sheen-a) * .62))), linear-gradient(rgba(0, 0, 0, calc(var(--ck-sheen-b) * .8)), rgba(0, 0, 0, calc(var(--ck-sheen-b) * .8)));
  background-size: 100% 3px, 100% 3px; background-position: 0 0, 0 100%; background-repeat: no-repeat; }
.ck-fill::after { content: ''; position: absolute; top: 1px; bottom: 1px; right: 0; width: 3px; border-radius: 2px; background: rgba(255, 255, 255, .78); }
/* a limit, engraved across the track: a cut that is dark on its lit side's far edge and light on the near one */
.ck-tick { position: absolute; width: 0; border-left: 1px solid var(--ck-lo); border-right: 1px solid var(--ck-hi); }
/* a bead: small, round, lit - a live value's mark, the end of a trace */
.ck-bead { display: inline-block; position: relative; width: 9px; height: 9px; border-radius: 50%; flex: none; background: var(--tone, var(--ok)); box-shadow: none; }
.ck-bead::after { content: ''; position: absolute; left: 18%; top: 14%; width: 38%; height: 38%; border-radius: 50%; background: rgba(255, 255, 255, .86); }   /* its point of light */
/* Daylight's tones are dark (they are text colours on white): a bead of them read as a black marble, so it is lit */
:root[data-theme="daylight"] .ck-bead { background: color-mix(in srgb, var(--tone, var(--ok)) 70%, #fff); }
/* the same bead inside a drawing (chartkit.js bead) */
.ck-beadg .d { fill: currentColor; }
.ck-beadg .p { fill: #fff; opacity: .86; }

/* ---- a lit chart (SVG): a glowing line over a soft filled area, a readable axis, markers on stems ---- */
.ck-chart { display: block; width: 100%; height: auto; overflow: visible; color: var(--tone, var(--accent)); }
.ck-grid { stroke: var(--hairline); stroke-width: 1; }
.ck-base { stroke: var(--border-2); stroke-width: 1; }
.ck-axis { font: 500 10.5px/1 var(--mono); fill: var(--text-3); }
.ck-line { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linejoin: round; stroke-linecap: round; }
/* the glow of a lit line: three wider, fainter copies of it under it (chartkit.js glow) - never a filter. --gk scales it. */
.ck-lineglow { --gk: 1; }
.ck-lineglow path { fill: none; stroke: currentColor; stroke-linejoin: round; stroke-linecap: round; }
.ck-lineglow .g1 { stroke-width: 4.2; opacity: calc(var(--ck-glow) * var(--gk) * .34); }
.ck-lineglow .g2 { stroke-width: 7; opacity: calc(var(--ck-glow) * var(--gk) * .17); }
.ck-lineglow .g3 { stroke-width: 10.5; opacity: calc(var(--ck-glow) * var(--gk) * .08); }
.ck-band { fill: var(--accent); opacity: .22; }
.ck-stem { stroke: var(--border-2); stroke-width: 1; }
.ck-mark { stroke: var(--surface-1); stroke-width: .8; }
.ck-cursor line { stroke: var(--text-2); stroke-width: 1; }
.ck-cursor circle { fill: var(--surface-1); stroke: var(--text); stroke-width: 1.5; }

/* ==== CONTRACT-V30 P4 - charts that say what they show: the kit's pieces for every time chart ====================
   (perfcharts.js DetailChart - the Performance page of every platform, Query Store, database sizes - and the Learning
   view's charts). Still pictures, except the arrival, which moves by transform only. */

/* (the arrival - a chart drawing itself once - is movement, so it lives with the page: styles.css .ck-wipe) */

/* THE LIT LINE: the chart's first line glows (three wider, fainter copies of it) over its area, which fades down in
   its own colour (the kit's one two-stop gradient); the last reading is a bead. */
.dc-glow { --gk: .8; }
.dc-area.ck-area { opacity: 1; }
.dc-bead .d { stroke: var(--surface-2); stroke-width: 1; }

/* THE LEARNING BASELINE: a band of depth behind the line - the usual range for the hour, drawn only where it was
   learned - with a lit upper edge; its middle is the dashed "usual" line. */
.ck-usual { fill: var(--accent); opacity: .1; stroke: none; }
.ck-usualedge { fill: none; stroke: var(--accent); stroke-width: 1; opacity: .38; }
.ck-usualmid .dc-line.dash { opacity: .55; }
:root[data-theme="daylight"] .ck-usual { opacity: .13; }

/* COMPARE: the same window yesterday or last week - a quiet dashed line in the series' own colour, named in the legend */
.dc-line.cmp { stroke-width: 1.3; stroke-dasharray: 2 3; opacity: .62; }

/* UNUSUAL PERIODS: a bracket over the plot, a faint column under it; the reason is in its title and the read-out */
.ck-oddcol { fill: var(--warning); opacity: .055; }
.ck-odd path { fill: none; stroke: var(--warning); stroke-width: 1.4; }
.ck-odd text { fill: var(--warning); font: 700 9px/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; }
.dc-tipo { display: grid; gap: 3px; margin-top: 7px; padding-top: 6px; border-top: 1px solid var(--hairline); color: var(--text-2); }
.dc-tipo > div { display: flex; align-items: baseline; gap: 7px; }
.dc-tipo i { flex: 0 0 auto; width: 9px; height: 3px; border-radius: 1px; background: var(--warning); transform: translateY(-3px); }
.dc-tipo b { margin-right: 3px; color: var(--warning); }

/* THE EVENTS LANE: under the time axis, one glyph per event - its shape its kind (alert ▲, configuration change ◆,
   plan change ●, job run ▮, deployment ⚑), its colour its severity where it has one */
.ck-lanetrack { stroke: var(--hairline); stroke-width: 1; }
.ck-lanel { fill: var(--text-3); font: 600 9px/1 var(--mono); letter-spacing: .04em; }
.ck-lg { stroke: var(--surface-2); stroke-width: .8; }
.ck-lg.job { stroke: none; opacity: .8; }
.dc-tipe i.k-alert { border-radius: 1px 1px 0 0; transform: none; }
.dc-tipe i.k-plan { border-radius: 50%; transform: none; }
.dc-tipe i.k-job { width: 3px; border-radius: 0; transform: none; }
/* the lane's key, once for a page of charts */
.ck-lanekey { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 12px; font-size: var(--fs-small); color: var(--text-3); }
.ck-lanekey svg { vertical-align: -2px; margin-right: 4px; }
.ck-lanekey b { font-weight: 650; color: var(--text-2); }

/* THE FORECAST CONE: from the last reading out through the forecast's band (Learning) */
.ck-cone { fill: var(--info); opacity: .16; stroke: none; }
.ck-coneedge { fill: none; stroke: var(--info); stroke-width: 1; opacity: .45; stroke-dasharray: 3 3; }
.ck-lanekey .ck-oddk { fill: none; stroke: var(--warning); stroke-width: 1.4; }
.ck-lanekey .ck-cmpk { fill: none; stroke: var(--text-2); stroke-width: 1.3; stroke-dasharray: 2 3; }
.pxlanekey { margin: -2px 0 8px; }
.pxcmp button:disabled { opacity: .45; cursor: default; }
